-
Notifications
You must be signed in to change notification settings - Fork 78
Added header for driver version and other info #228
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
Added header for driver version and other info #228
Conversation
Codecov Report
@@ Coverage Diff @@
## main #228 +/- ##
==========================================
- Coverage 98.52% 98.45% -0.08%
==========================================
Files 26 26
Lines 3801 3809 +8
==========================================
+ Hits 3745 3750 +5
- Misses 56 59 +3
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
You can simply do:
I think it's safe to assume that when we are executing the python-arango code, the version file would've already been generated by |
@joowani , thanks for the tip. I tested it and it works! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like you missed a couple of spots but the rest looks good! Please feel free to merge after you address the nits. Thanks as always.
@joowani, please check the related issue for context information.
The aim here is to pass this header to every request. So, I've added it to normalize_headers() in request.py.
Please check request.py line 12. Is there a way to quickly retrieve the name and version of the current package in Python?
I am thinking of using the importlib-metadata package (https://pypi.org/project/importlib-metadata/). Do you think that this is a good approach or is there a better way?