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

Fix broken dashboard metrics #1700

Merged

Conversation

bmispelon
Copy link
Member

@bmispelon bmispelon commented Oct 26, 2024

This should fix #1690

Once merged, the missing data can be fixed by running the new management command on the server:

python manage.py fix_trac_metrics --yes --from-date=2024-04-16 new-tickets-today new-tickets-week

@bmispelon bmispelon changed the title Fix broken dashboard metrics (#1690) Fix broken dashboard metrics Oct 26, 2024
@bmispelon bmispelon force-pushed the issue/1690-dashboard-trac-metric-time branch from 2b94d19 to 4bbea63 Compare October 26, 2024 22:56
return queryset


def _daterange(queryset):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like reading functions like this. Neat & tidy 👏🏼

Copy link
Contributor

@sarahboyce sarahboyce left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great - thank you for working on this ⭐

- The mixin is now compatible with TestCase.setUpTestData
- The mixin now has teardown logic and can be used more than
  once in the testsuite
@bmispelon bmispelon force-pushed the issue/1690-dashboard-trac-metric-time branch from 4bbea63 to 69043e2 Compare November 7, 2024 13:58
This also introduces the fix_trac_metrics management
command to help fix collected data.
@bmispelon bmispelon force-pushed the issue/1690-dashboard-trac-metric-time branch from 69043e2 to 2c82ca8 Compare November 7, 2024 14:17
@bmispelon bmispelon merged commit 95f2767 into django:main Nov 7, 2024
4 checks passed
@bmispelon
Copy link
Member Author

Everybody put on your safety glasses and your seat belt, I'm going to attempt running this on production 🧑‍🔬

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Dashboard: New ticket today/this week no longer calculated
3 participants