-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Regression] [backport 1.8.latest] Fix psycopg2 version install (#113) (
#117)
- Loading branch information
1 parent
5a5a753
commit 39c1a9f
Showing
39 changed files
with
80 additions
and
5,609 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
kind: Fixes | ||
body: Default to psycopg2-binary and allow overriding to psycopg2 via DBT_PSYCOPG2_NAME | ||
(restores previous behavior) | ||
time: 2024-06-05T20:26:14.801254-04:00 | ||
custom: | ||
Author: mikealfare | ||
Issue: "96" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
python -m venv venv | ||
source venv/bin/activate | ||
python -m pip install . | ||
|
||
if [[ "$PSYCOPG2_WORKAROUND" == true ]]; then | ||
if [[ $(pip show psycopg2-binary) ]]; then | ||
PSYCOPG2_VERSION=$(pip show psycopg2-binary | grep Version | cut -d " " -f 2) | ||
pip uninstall -y psycopg2-binary | ||
pip install psycopg2==$PSYCOPG2_VERSION | ||
fi | ||
fi | ||
|
||
PSYCOPG2_NAME=$((pip show psycopg2 || pip show psycopg2-binary) | grep Name | cut -d " " -f 2) | ||
if [[ "$PSYCOPG2_NAME" != "$PSYCOPG2_EXPECTED_NAME" ]]; then | ||
echo -e 'Expected: "$PSYCOPG2_EXPECTED_NAME" but found: "$PSYCOPG2_NAME"' | ||
exit 1 | ||
fi | ||
deactivate | ||
rm -r ./venv |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -161,3 +161,9 @@ cython_debug/ | |
|
||
# testing artifacts | ||
/logs | ||
|
||
# MacOS | ||
.DS_Store | ||
|
||
# vscode | ||
.vscode/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.