-
Notifications
You must be signed in to change notification settings - Fork 3
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
Kk-792 Fixes to the dev environment #237
Conversation
nikomakela
commented
Oct 4, 2021
•
edited
Loading
edited
- Updated psycopg2 to psycopg2-binary. About the matter: https://stackoverflow.com/questions/33866695/error-installing-psycopg2-on-macos-10-9-5 and database connection isn't set to UTC psycopg/psycopg2#1293. Could not upgrade to latest, because it had issues with timezone. This one is also a patch upgrade to last one, so it should not need much testing either.
- Fix the CORS issues in Docker-compose env example configuration.
- Ignore vscode setup files.
About the matter: https://stackoverflow.com/questions/33866695/error-installing-psycopg2-on-macos-10-9-5. Could not upgrade to latest, because it had issues with timezone. This one is also a patch upgrade to last one, so it should not need much testing either. KK-792
Codecov Report
@@ Coverage Diff @@
## master #237 +/- ##
=======================================
Coverage 93.82% 93.82%
=======================================
Files 120 120
Lines 5506 5506
Branches 305 305
=======================================
Hits 5166 5166
Misses 285 285
Partials 55 55 Continue to review full report at Codecov.
|
@@ -131,14 +131,14 @@ protobuf==3.11.3 | |||
# via | |||
# google-api-core | |||
# googleapis-common-protos | |||
psycopg2==2.8.4 | |||
psycopg2-binary==2.8.6 |
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.
Using the binary package removes the requirement to have postgres libraries installed for building the psycopg2
package, which is convenient. However psycopg2 documentation states that especially production environments should only use the non-binary version.
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.
Okay, nice catch! I'll try to address the problems in some other ways. Using psycopg2-binary was adviced by stack overflow.
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.
Django 2.2 needs psycopg2 2.8. Mac needs the binary. The psycopg2-binary should be replacesd with psycopg2 when possible: https://www.psycopg.org/docs/install.html#psycopg-vs-psycopg-binary.
- Depend on psycopg2 rather than psycopg2-binary biocommons/hgvs#623
- psycopg2-binary: Why? psycopg/psycopg2#674
- https://stackoverflow.com/questions/33866695/error-installing-psycopg2-on-macos-10-9-5
- database connection isn't set to UTC psycopg/psycopg2#1293
So, still using the binary version, but commented in requirements.in that it should be replaced with psycopg2 when possible.
Django 2.2 needs psycopg2 2.8. Mac needs the binary. The psycopg2-binary should be replacesd with psycopg2 when possible: https://www.psycopg.org/docs/install.html#psycopg-vs-psycopg-binary. KK-792l
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.
LGTM! 👍