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 grades fetch to not just include first semester's grades #25

Merged
merged 1 commit into from
Dec 24, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion drawbot/utils/pronote.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def fetch_homeworks(pronote_client: pronotepy.Client) -> Optional[Generator]:


def fetch_grades(pronote_client: pronotepy.Client) -> Optional[Generator]:
fetched_grades = pronote_client.periods[0].grades
fetched_grades = pronote_client.current_period.grades
Copy link
Owner

Choose a reason for hiding this comment

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

Nice! It works fine (wasn't aware of that, and I think I just did [0] for testing purpose and forget to search the real production method). Anyway, thanks for your help :D


grades: DefaultDict[str, list] = defaultdict(list)
for g in fetched_grades:
Expand Down