Skip to content
New issue

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

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

Already on GitHub? # to your account

Fix small error in pp calculation #2074

Merged
merged 1 commit into from
Dec 26, 2022
Merged

Fix small error in pp calculation #2074

merged 1 commit into from
Dec 26, 2022

Conversation

int-y1
Copy link
Contributor

@int-y1 int-y1 commented Dec 21, 2022

According to the blog post, the bonus should only consider full ACs.

List of changes:

  • Previously, Profile.problem_count was the number of problems with a positive score. Now, it's the number of problems with a full AC.
  • Previously, the pp bonus includes partial ACs. Now, it excludes partial ACs.

Also, everything looked ok when I ran for x in Profile.objects.all(): x.calculate_points() in the shell.

@codecov-commenter
Copy link

codecov-commenter commented Dec 21, 2022

Codecov Report

Base: 46.66% // Head: 46.66% // Decreases project coverage by -0.00% ⚠️

Coverage data is based on head (f19a957) compared to base (7f62071).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2074      +/-   ##
==========================================
- Coverage   46.66%   46.66%   -0.01%     
==========================================
  Files         238      238              
  Lines       13247    13246       -1     
==========================================
- Hits         6182     6181       -1     
  Misses       7065     7065              
Impacted Files Coverage Δ
judge/models/profile.py 81.97% <100.00%> (-0.08%) ⬇️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Member

@kiritofeng kiritofeng left a comment

Choose a reason for hiding this comment

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

LGTM

@quantum5 quantum5 merged commit f2dfa60 into DMOJ:master Dec 26, 2022
@int-y1 int-y1 deleted the fix-pp-calc branch December 26, 2022 07:44
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants