Skip to content

fix(utils): fix routes v1/utils/version#393

Merged
jnioche merged 1 commit intoBoavizta:mainfrom
jonperron:fix/utils_version_broken
Jul 15, 2025
Merged

fix(utils): fix routes v1/utils/version#393
jnioche merged 1 commit intoBoavizta:mainfrom
jonperron:fix/utils_version_broken

Conversation

@jonperron
Copy link
Copy Markdown
Collaborator

Changelog

  • Move function to get version from pyproject file to utils package
  • Refactor main and utils_router to use this function

Fix #392

Tests

  • Docker build ✔️
  • Servers starts successfully ✔️
docker run -p 5000:5000/tcp boavizta/boaviztapi:`poetry version -s`                                                                                      
INFO:     Started server process [1]                                                                                                                                                          
INFO:     Waiting for application startup.
INFO:     Application startup complete.
INFO:     Uvicorn running on http://0.0.0.0:5000 (Press CTRL+C to quit)
  • Endpoint answers 200
INFO:     172.17.0.1:45490 - "GET /v1/utils/version HTTP/1.1" 200 OK

@jonperron jonperron marked this pull request as draft April 22, 2025 08:59
@jonperron jonperron force-pushed the fix/utils_version_broken branch from 9b0d180 to 5ed9e91 Compare April 22, 2025 09:02
@jonperron jonperron marked this pull request as ready for review April 22, 2025 09:04
@da-ekchajzer
Copy link
Copy Markdown
Collaborator

Thank you very much for this fix. Is it worth it to test this route to avoid this kind of bug ?

@jonperron
Copy link
Copy Markdown
Collaborator Author

jonperron commented May 3, 2025

I would say yes @da-ekchajzer, I'm adding a test on this route. At the moment, the test only check the status code, I don't think checking the version value is worth it.

Changelog
* Move function to get version from pyproject file to utils package
* Refactor main and utils_router to use this function
* Add test
@jonperron jonperron force-pushed the fix/utils_version_broken branch from 5ed9e91 to fb43f79 Compare May 3, 2025 07:42
@jnioche jnioche added this to the 1.3.11 milestone Jul 15, 2025
Copy link
Copy Markdown
Collaborator

@jnioche jnioche left a comment

Choose a reason for hiding this comment

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

Tested, works fine!
Thanks @jonperron

@jnioche jnioche added the bug Something isn't working label Jul 15, 2025
@jnioche jnioche merged commit 417497e into Boavizta:main Jul 15, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

endpoint /v1/utils/version broken in docker image since version 1.3.8

3 participants