Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure there are UserStat records before running #2426

Merged
merged 2 commits into from
Jan 23, 2025

Conversation

ShanaLMoore
Copy link
Collaborator

@ShanaLMoore ShanaLMoore commented Jan 22, 2025

Sidekiq is flooded with UserStatCollectionJob even when UserStats.any? => false.

Let's not run the job if there are no user stats

@ShanaLMoore ShanaLMoore added the minor-ver for release notes label Jan 22, 2025
kirkkwang
kirkkwang previously approved these changes Jan 22, 2025
Copy link

github-actions bot commented Jan 22, 2025

Test Results

    3 files  +  1      3 suites  +1   17m 30s ⏱️ + 5m 27s
2 056 tests +512  2 000 ✅ +486  56 💤 +26  0 ❌ ±0 
2 083 runs  +516  2 025 ✅ +488  58 💤 +28  0 ❌ ±0 

Results for commit 11c2741. ± Comparison against base commit 8b319ca.

This pull request removes 42 and adds 554 tests. Note that renamed tests count towards both.
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to destroy c10779eb-84dd-4733-ab1f-34758acf760b
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to edit cd4c1c0e-f73b-4432-9146-b9a395d42df6
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to read a8684ed9-9994-444d-9408-d880dcc4082f
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to update cd1bcbfd-dfb5-4d28-acec-7390f27b4195
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to destroy 5f9cd45a-7a1c-4120-9f1b-84c4a468a478
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to edit 7a7c7210-51a0-4191-a919-977e79f9f06d
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to read 0b2e0584-b074-458a-a154-b8e795080aef
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to update 199be414-0592-4711-8b93-21cc273bfd88
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor GenericWork permissions is expected not to be able to destroy 3257b62b-3484-4745-b581-97526b57596c
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor GenericWork permissions is expected not to be able to edit c54e7786-aca3-4e7a-920a-4bfc0f8a7460
…
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to destroy bf033fe1-9da8-4d1b-92cd-5a9ab499b506
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to edit b2e34f75-bf86-4822-934f-60198ffe48ef
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to read 1814125c-2933-4f73-ad1d-602af8271794
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor Etd permissions is expected not to be able to update 464d7ac0-f796-4cab-8003-6eed2f71b9db
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to destroy e69077a4-7157-4bd4-a21e-229a422d687d
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to edit f42d9aef-3a2d-49a6-b583-d1d7ca8f49fc
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to read 9e4ba010-fd9c-49b8-9f6b-bce92562071c
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor FileSet permissions is expected not to be able to update a71bf7aa-3ec2-446d-92eb-7b703a1daa5a
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor GenericWork permissions is expected not to be able to destroy 3f3c66f7-dbc4-4ac1-99d9-8d00964e573d
spec.abilities.work_ability_spec ‑ Hyrax::Ability::WorkAbility when work depositor GenericWork permissions is expected not to be able to edit d6d1ebad-e704-4c85-8521-112f97bfb62e
…

♻️ This comment has been updated with latest results.

@ShanaLMoore ShanaLMoore force-pushed the fix-user-stat-job-execution-condition branch from 07c1ac8 to 72c5ab1 Compare January 22, 2025 23:07
- Added spec contexts to test behavior when UserStat records are present and absent.
- Defined a FactoryBot factory for UserStat to support spec setup.
@ShanaLMoore ShanaLMoore force-pushed the fix-user-stat-job-execution-condition branch from 488a362 to 11c2741 Compare January 22, 2025 23:15
@ShanaLMoore ShanaLMoore requested a review from kirkkwang January 23, 2025 00:14
@ShanaLMoore ShanaLMoore merged commit c507eab into main Jan 23, 2025
8 checks passed
@ShanaLMoore ShanaLMoore deleted the fix-user-stat-job-execution-condition branch January 23, 2025 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
minor-ver for release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants