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

chore(scripts): add some python scripts #2438

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

bas-info-nl
Copy link
Member

@bas-info-nl bas-info-nl commented Jan 19, 2025

chore: add python scripts for version retrieval

To make it easier to find versions for individual components and for those used in a podiumd.

Solves: PZ-5197

@bas-info-nl bas-info-nl requested review from hsiliev and a team as code owners January 19, 2025 20:27
@bas-info-nl bas-info-nl marked this pull request as draft January 19, 2025 20:27
@bas-info-nl bas-info-nl marked this pull request as ready for review January 19, 2025 20:34
Copy link
Contributor

github-actions bot commented Jan 19, 2025

unit-test-results

 79 files  ±0  109 suites  ±0   2m 4s ⏱️ -6s
378 tests +3  377 ✅ +3  1 💤 ±0  0 ❌ ±0 
472 runs  +5  470 ✅ +5  2 💤 ±0  0 ❌ ±0 

Results for commit 3497bba. ± Comparison against base commit 3b6e350.

This pull request removes 12 and adds 15 tests. Note that renamed tests count towards both.
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the BAG server error code and no exception message
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the BRC server error code and no exception message
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the DRC server error code
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the Klanten server error code and no exception message
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the Objecten server error code and no exception message
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the ZRC server error code
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the ZTC server error code
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the ZTC server error code and no exception message
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the ZTC server error code and the exception message
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the general server error error code with an exception message
…
net.atos.zac.admin.ZaakafhandelParameterBeheerServiceTest ‑ Then: The new zaak type is stored
net.atos.zac.app.klant.KlantRestServiceTest ‑ Then: the vestigingsprofiel is returned correctly
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the BAG server error code and no exception message and log the exception
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the BRC server error code and no exception message and log the exception
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the DRC server error code and log the exception
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the Klanten server error code and no exception message and log the exception
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the Objecten server error code and no exception message and log the exception
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the ZRC server error code and log the exception
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the ZTC server error code and log the exception
net.atos.zac.app.util.exception.RestExceptionMapperTest ‑ Then: it should return the ZTC server error code and no exception message and log the exception
…

♻️ This comment has been updated with latest results.

Copy link
Contributor

github-actions bot commented Jan 19, 2025

integration-test-results

 28 files  +1   28 suites  +1   36s ⏱️ ±0s
107 tests +1  107 ✅ +1  0 💤 ±0  0 ❌ ±0 
120 runs  +1  120 ✅ +1  0 💤 ±0  0 ❌ ±0 

Results for commit 3497bba. ± Comparison against base commit 3b6e350.

♻️ This comment has been updated with latest results.

Copy link

codecov bot commented Jan 19, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 54.62%. Comparing base (a9f5849) to head (3497bba).
Report is 83 commits behind head on main.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #2438      +/-   ##
============================================
+ Coverage     52.95%   54.62%   +1.66%     
- Complexity     3274     3360      +86     
============================================
  Files           991     1000       +9     
  Lines         22519    22746     +227     
  Branches       1750     1777      +27     
============================================
+ Hits          11926    12426     +500     
+ Misses         9694     9406     -288     
- Partials        899      914      +15     
Flag Coverage Δ
integrationtests 50.00% <ø> (+0.79%) ⬆️
unittests 34.69% <ø> (+1.41%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

Added a python scripts location, and dependency version checking scripts.
Add scripts to retrieve information about the podiumd version, used component versions and compare them to another podiumd version.
@bas-info-nl bas-info-nl changed the title Chore: add some python scripts chore(scripts): add some python scripts Jan 21, 2025
Copy link
Member

@edgarvonk edgarvonk left a comment

Choose a reason for hiding this comment

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

Should we maybe add a simple readme to tell developers which script to run for what?

scripts/python/podiumd/podiumd_versions.py Outdated Show resolved Hide resolved
Copy link
Member

@edgarvonk edgarvonk left a comment

Choose a reason for hiding this comment

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

I think it is probably good to add a readme.md in this folder explaining what these scripts do and how to use them (high level)?

Additionally we could also link to this folder from our existing updatingDependencies.md doc?

Copy link
Member

@edgarvonk edgarvonk Jan 27, 2025

Choose a reason for hiding this comment

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

Minor thing but I would probably rename this folder from python to something more meaningful like check-dependencies? it is quite irrelevant that these scripts are written in Python no? It's more what they do I think. :-)

Copy link
Member Author

Choose a reason for hiding this comment

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

there can be other python scripts... so this could setup a common python environment, and from there run the scripts you need

Copy link
Member Author

Choose a reason for hiding this comment

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

@edgarvonk can you please check the init-pyenv script again, it should work a bit better for you now.

Copy link
Contributor

@infonl-marcel infonl-marcel left a comment

Choose a reason for hiding this comment

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

Seems the git-ignore needs to be updated. After running the script there are some .pyc files that popup to be committed

image

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.

3 participants