From 7f3192c64f244d0b932b60ceeee224ea845dabcf Mon Sep 17 00:00:00 2001 From: Amir Mofakhar Date: Mon, 14 Oct 2024 10:21:03 +0100 Subject: [PATCH] [AP-1873] bump to Python 3.10 (#1185) * bump to Python 3.10 * using numpy==1.26.4 * python requirement in tap-postgres * fix some python3.10 links * fix some python3.10 links * fix docker file * bump pytz * bump pipelinewise-singer-python * bump tzlocal * downgrade tzlocal to 4.0.2 * downgrade pipelinewise-singer-python to 1.* * bump tzlocal in tap-mongodb * bump pipelinewise-singer-python in target-snowflake * fix numpy for target-snowflake * release 0.66.0 --- .github/workflows/connectors.yml | 4 ++-- .github/workflows/lint_unit_tests.yml | 4 ++-- .github/workflows/publish_doc.yml | 2 +- CHANGELOG.md | 10 ++++++++++ Dockerfile | 3 ++- dev-project/entrypoint.sh | 13 ++++++++++++- setup.py | 9 +++++---- singer-connectors/tap-mongodb/setup.py | 3 ++- singer-connectors/tap-mysql/setup.py | 2 +- singer-connectors/tap-postgres/setup.py | 2 +- singer-connectors/target-postgres/setup.py | 4 ++-- singer-connectors/target-snowflake/setup.py | 4 +++- 12 files changed, 43 insertions(+), 17 deletions(-) diff --git a/.github/workflows/connectors.yml b/.github/workflows/connectors.yml index 5e8eb3132..a160ae6dc 100644 --- a/.github/workflows/connectors.yml +++ b/.github/workflows/connectors.yml @@ -27,10 +27,10 @@ jobs: continue-on-error: true run: ./scripts/ci_check_no_file_changes.sh python - - name: Set up Python 3.8 + - name: Set up Python 3.10 uses: actions/setup-python@v5.1.0 with: - python-version: '3.8' + python-version: '3.10' - name: Check PipelineWise and all connectors are installable run: | diff --git a/.github/workflows/lint_unit_tests.yml b/.github/workflows/lint_unit_tests.yml index 36bf525c7..5bc3e2ed7 100644 --- a/.github/workflows/lint_unit_tests.yml +++ b/.github/workflows/lint_unit_tests.yml @@ -26,11 +26,11 @@ jobs: continue-on-error: true run: ./scripts/ci_check_no_file_changes.sh python - - name: Set up Python 3.8 + - name: Set up Python 3.10 if: steps.check.outcome == 'failure' uses: actions/setup-python@v5.1.0 with: - python-version: '3.8' + python-version: '3.10' - name: Install dependencies if: steps.check.outcome == 'failure' diff --git a/.github/workflows/publish_doc.yml b/.github/workflows/publish_doc.yml index 4c10a6667..738fe4e3e 100644 --- a/.github/workflows/publish_doc.yml +++ b/.github/workflows/publish_doc.yml @@ -23,7 +23,7 @@ jobs: - uses: actions/setup-python@v5.1.0 with: - python-version: '3.8' + python-version: '3.10' - name: check structure run: ls -l gh_doc_automation diff --git a/CHANGELOG.md b/CHANGELOG.md index 92b241736..9e5fd0a9b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,13 @@ +0.66.0 (2024-10-11) +------------------- +- Bump programming language to Python 3.10 +- Bump `ansible-core` from `2.11.8` to `2.17.5` +- Bump `tzlocal` from `2.1.*` to `4.0.2` in `tap-mongodb` +- Bump `tzlocal` from `2.1` to `4.0.2` in `tap-mysql` +- Bump `pipelinewise-singer-python` from `1.*` to `2.*` in `target-postgres` +- Bump `pipelinewise-singer-python` from `1.*` to `2.*` in `target-snowflake` + + 0.65.3 (2024-09-13) ------------------- - Bump `zenpy` in `tap-zendesk` from `2.0.0` to `2.0.52` diff --git a/Dockerfile b/Dockerfile index 6b595b1a8..126a3a71f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3.8-slim-buster +FROM python:3.10-slim-buster ARG connectors=all @@ -10,6 +10,7 @@ RUN apt-get -qq update \ libaio1 \ mbuffer \ wget \ + tzdata \ && rm -rf /var/lib/apt/lists/* \ && pip install -U --no-cache-dir pip diff --git a/dev-project/entrypoint.sh b/dev-project/entrypoint.sh index bfe40fd05..7ea1b69f3 100755 --- a/dev-project/entrypoint.sh +++ b/dev-project/entrypoint.sh @@ -4,6 +4,14 @@ set -e apt update +rm -f /usr/bin/python3 +ln -s /usr/bin/python3.8 /usr/bin/python3 + +apt install -y software-properties-common python3-apt +add-apt-repository ppa:deadsnakes/ppa +apt update + + DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get -y install tzdata apt install -y --no-install-recommends \ @@ -16,7 +24,10 @@ apt install -y --no-install-recommends \ mariadb-client \ mbuffer \ postgresql-client \ - python3.8 python3-pip python3-venv python3-dev + python3.10 python3-pip python3.10-venv python3.10-dev + +rm /usr/bin/python3 +ln -s /usr/bin/python3.10 /usr/bin/python3 apt upgrade -y # rm -rf /var/lib/apt/lists/* \ diff --git a/setup.py b/setup.py index 4be474134..e22b8cb4a 100644 --- a/setup.py +++ b/setup.py @@ -6,8 +6,8 @@ LONG_DESCRIPTION = f.read() setup(name='pipelinewise', - python_requires='==3.8.*', - version='0.65.3', + python_requires='==3.10.*', + version='0.66.0', description='PipelineWise', long_description=LONG_DESCRIPTION, long_description_content_type='text/markdown', @@ -16,17 +16,18 @@ classifiers=[ 'License :: OSI Approved :: Apache Software License', 'Programming Language :: Python :: 3 :: Only', - 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.10', ], install_requires=[ 'argparse==1.4.0', 'tabulate==0.8.9', 'PyYAML==6.0', - 'ansible-core==2.11.8', + 'ansible-core==2.17.5', 'Jinja2==3.1.2', 'joblib==1.3.2', 'PyMySQL==0.7.11', 'psycopg2-binary==2.9.5', + 'numpy==1.26.4', # numpy 2.X is not compatible with our used pandas 'snowflake-connector-python[pandas]==3.0.4', 'pipelinewise-singer-python==1.*', 'python-pidfile==3.0.0', diff --git a/singer-connectors/tap-mongodb/setup.py b/singer-connectors/tap-mongodb/setup.py index b737cfeab..02bf476d5 100644 --- a/singer-connectors/tap-mongodb/setup.py +++ b/singer-connectors/tap-mongodb/setup.py @@ -16,12 +16,13 @@ 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.10' ], py_modules=['tap_mongodb'], install_requires=[ 'pipelinewise-singer-python==1.*', 'pymongo==4.7.*', - 'tzlocal==2.1.*', + 'tzlocal==4.0.2', 'terminaltables==3.1.*', 'dnspython==2.1.*', ], diff --git a/singer-connectors/tap-mysql/setup.py b/singer-connectors/tap-mysql/setup.py index 58ec16198..0cb6a2582 100644 --- a/singer-connectors/tap-mysql/setup.py +++ b/singer-connectors/tap-mysql/setup.py @@ -23,7 +23,7 @@ 'mysql-replication==0.43', 'PyMySQL==1.1.*', 'plpygis==0.2.1', - 'tzlocal==2.1', + 'tzlocal==4.0.2', ], extras_require={ 'test': [ diff --git a/singer-connectors/tap-postgres/setup.py b/singer-connectors/tap-postgres/setup.py index b920dc1be..eaec12c2b 100644 --- a/singer-connectors/tap-postgres/setup.py +++ b/singer-connectors/tap-postgres/setup.py @@ -16,7 +16,7 @@ 'License :: OSI Approved :: GNU Affero General Public License v3', 'Programming Language :: Python :: 3 :: Only' ], - python_requires=">=3.7,<3.10", + python_requires=">=3.10", install_requires=[ 'pipelinewise-singer-python==1.*', 'psycopg2-binary==2.9.5', diff --git a/singer-connectors/target-postgres/setup.py b/singer-connectors/target-postgres/setup.py index 59e5fce9d..d5948b88c 100644 --- a/singer-connectors/target-postgres/setup.py +++ b/singer-connectors/target-postgres/setup.py @@ -18,10 +18,10 @@ ], py_modules=["target_postgres"], install_requires=[ - 'pipelinewise-singer-python==1.*', + 'pipelinewise-singer-python==2.*', 'psycopg2-binary==2.9.5', 'inflection==0.3.1', - 'joblib==1.2.0' + 'joblib==1.2.0', ], extras_require={ "test": [ diff --git a/singer-connectors/target-snowflake/setup.py b/singer-connectors/target-snowflake/setup.py index 001bdf303..c7fa1c894 100644 --- a/singer-connectors/target-snowflake/setup.py +++ b/singer-connectors/target-snowflake/setup.py @@ -18,11 +18,13 @@ 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.9', + 'Programming Language :: Python :: 3.10', ], py_modules=["target_snowflake"], python_requires='>=3.7', install_requires=[ - 'pipelinewise-singer-python==1.*', + 'pipelinewise-singer-python==2.*', + 'numpy==1.26.4', # numpy 2.X is not compatible with our used pandas 'snowflake-connector-python[pandas]==3.0.4', 'inflection==0.5.1', 'joblib==1.2.0',