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 /vMAJOR/info in index server #414

Merged
merged 1 commit into from Jul 17, 2020
Merged

Fix /vMAJOR/info in index server #414

merged 1 commit into from Jul 17, 2020

Conversation

CasperWA
Copy link
Member

@CasperWA CasperWA commented Jul 17, 2020

It seems the /info endpoint was not initiated for /vMAJOR.

Test all versioned base URLs' routers return status code 200.

Locally, I still can't reach /v1/info for the index meta-database implementation in the test. I am unsure what the exact issue is now. With a small break and a reinstall it seems fine... weird.

Finally, I tried to originally add the landing router as well, but there seems to be some issues with Jinja2 templates and middleware for the Starlette TestClient.
See the issues encode/starlette#472 and tiangolo/fastapi#806.
I will leave this for a later point, perhaps an issue of our own to decide on what approach to take, since there are a few work-arounds.

Test all versioned base URLs' routers return status code 200.
@CasperWA CasperWA added the bug Something isn't working label Jul 17, 2020
@CasperWA CasperWA requested review from ml-evs and shyamd July 17, 2020 12:07
@codecov
Copy link

codecov bot commented Jul 17, 2020

Codecov Report

Merging #414 into master will increase coverage by 0.03%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #414      +/-   ##
==========================================
+ Coverage   90.95%   90.99%   +0.03%     
==========================================
  Files          55       55              
  Lines        2522     2522              
==========================================
+ Hits         2294     2295       +1     
+ Misses        228      227       -1     
Flag Coverage Δ
#unittests 90.99% <100.00%> (+0.03%) ⬆️

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

Impacted Files Coverage Δ
optimade/server/main_index.py 95.74% <100.00%> (ø)
optimade/server/routers/utils.py 91.03% <0.00%> (+0.68%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 93e50b1...782868d. Read the comment docs.

ml-evs
ml-evs previously approved these changes Jul 17, 2020
Copy link
Member

@ml-evs ml-evs left a comment

Choose a reason for hiding this comment

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

Some fine bug hunting, lgtm

@CasperWA
Copy link
Member Author

From this CI run: https://github.com/Materials-Consortia/optimade-python-tools/runs/881814874?check_suite_focus=true
It seems the fix works.
I have removed the temporary commit that resulted in that CI run.

@CasperWA CasperWA merged commit 38d822c into master Jul 17, 2020
@CasperWA CasperWA deleted the fix_index_server branch July 17, 2020 12:54
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.

None yet

2 participants