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

Move report endpoints to new module #1135

Merged
merged 1 commit into from
Mar 6, 2025
Merged

Conversation

praseodym
Copy link
Contributor

This resolves cyclic dependencies between the election and pdf_gen, eml modules.

Relates to #988.

@praseodym praseodym added the backend Issues or pull requests that relate to the backend label Mar 5, 2025
@praseodym praseodym self-assigned this Mar 5, 2025
@praseodym praseodym requested a review from a team as a code owner March 5, 2025 14:57
@praseodym praseodym requested review from rnijveld, marlonbaeten, Lionqueen94 and oliver3 and removed request for a team March 5, 2025 14:57
Copy link

github-actions bot commented Mar 5, 2025

Sigrid maintainability feedback

✅ You wrote maintainable code and achieved your objective of 3.5 stars

Show details

Sigrid compared your code against the baseline of 2025-03-05.

👍 What went well?

You fixed or improved 0 refactoring candidates.

👎 What could be better?

Unfortunately, 9 refactoring candidates were introduced or got worse.

Risk System property Location
🔴 Duplication
(Introduced)
backend/src/report/api.rs line 128-137
backend/src/report/api.rs line 195-204
🔴 Duplication
(Introduced)
backend/src/report/api.rs line 195-202
backend/src/report/api.rs line 128-135
backend/src/report/api.rs line 238-245
🔴 Duplication
(Introduced)
backend/src/report/api.rs line 120-125
backend/src/report/api.rs line 189-194
🟠 Unit Size
(Introduced)
backend/src/report/api.rs
election_download_zip_results(Coordinator,State<Elections>,State<PollingStations>,State<PollingStationResultsEntries>,Path<u32>)
🟠 Unit Interfacing
(Introduced)
backend/src/report/api.rs
election_download_xml_results(Coordinator,State<Elections>,State<PollingStations>,State<PollingStationResultsEntries>,Path<u32>)
🟠 Unit Interfacing
(Introduced)
backend/src/report/api.rs
election_download_zip_results(Coordinator,State<Elections>,State<PollingStations>,State<PollingStationResultsEntries>,Path<u32>)
🟠 Unit Interfacing
(Introduced)
backend/src/report/api.rs
election_download_pdf_results(Coordinator,State<Elections>,State<PollingStations>,State<PollingStationResultsEntries>,Path<u32>)
🟡 Unit Size
(Introduced)
backend/src/report/api.rs
election_download_pdf_results(Coordinator,State<Elections>,State<PollingStations>,State<PollingStationResultsEntries>,Path<u32>)
⚫️ + 1 more

📚 Remaining technical debt

4 refactoring candidates didn't get better or worse, but are still present in the code you touched.

View this system in Sigrid to explore your technical debt

⭐️ Sigrid ratings

System property System on 2025-03-05 Before changes New/changed code
Volume 5.1 N/A N/A
Duplication 4.3 3.6 3.6
Unit Size 2.4 1.7 1.8
Unit Complexity 3.4 5.5 5.5
Unit Interfacing 3.2 0.9 1.1
Module Coupling 3.6 5.5 5.5
Component Independence 2.6 N/A N/A
Component Entanglement 3.0 N/A N/A
Maintainability 3.5 3.9 4.0

💬 Did you find this feedback helpful?

We would like to know your thoughts to make Sigrid better.
Your username will remain confidential throughout the process.


View this system in Sigrid

Copy link

codecov bot commented Mar 5, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.99%. Comparing base (624daf3) to head (261162f).
Report is 2 commits behind head on main.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1135   +/-   ##
=======================================
  Coverage   91.99%   91.99%           
=======================================
  Files         281      282    +1     
  Lines       17102    17102           
  Branches     1495     1495           
=======================================
  Hits        15733    15733           
  Misses       1266     1266           
  Partials      103      103           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@praseodym praseodym added this pull request to the merge queue Mar 6, 2025
Merged via the queue into main with commit 188dc7d Mar 6, 2025
21 checks passed
@praseodym praseodym deleted the 988-backend-report-module branch March 6, 2025 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Issues or pull requests that relate to the backend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants