From c7b898dfdacaa18aa5d8f25364707fac6a3ebc23 Mon Sep 17 00:00:00 2001 From: Alexander Clegg Date: Tue, 22 Apr 2025 16:08:10 -0700 Subject: [PATCH] test updating python version to 3.10 --- .github/actions/install_ubuntu_deps/action.yml | 2 +- .github/workflows/install_and_test.yml | 6 +++--- README.md | 2 +- conda-build/Dockerfile | 4 ++-- conda-build/README.md | 2 +- conda-build/matrix_builder.py | 4 ++-- mypy.ini | 2 +- setup.py | 4 ++-- src/cmake/dependencies.cmake | 2 +- 9 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/actions/install_ubuntu_deps/action.yml b/.github/actions/install_ubuntu_deps/action.yml index f9e5271cf7..815d7cd405 100644 --- a/.github/actions/install_ubuntu_deps/action.yml +++ b/.github/actions/install_ubuntu_deps/action.yml @@ -44,7 +44,7 @@ runs: uses: conda-incubator/setup-miniconda@v3.0.1 with: miniconda-version: "latest" - python-version: "3.9" + python-version: "3.10" activate-environment: "habitat" - name: Install conda and dependencies run: |- diff --git a/.github/workflows/install_and_test.yml b/.github/workflows/install_and_test.yml index 44479901a4..5eff378c43 100644 --- a/.github/workflows/install_and_test.yml +++ b/.github/workflows/install_and_test.yml @@ -17,7 +17,7 @@ jobs: - name: Setup python uses: actions/setup-python@v5.0.0 with: - python-version: '3.9.16' + python-version: '3.10.17' - name: install dependencies run: |- pip install -U pip setuptools pre-commit @@ -34,7 +34,7 @@ jobs: - name: Setup python uses: actions/setup-python@v5.0.0 with: - python-version: '3.9.16' + python-version: '3.10.17' - name: setup run: |- pip install -U pip @@ -389,7 +389,7 @@ jobs: uses: conda-incubator/setup-miniconda@v3 with: miniconda-version: "latest" - python-version: "3.9" + python-version: '3.10.17' activate-environment: "habitat" - name: Set CI_TEST variable based on "main merge" vs. "pull_request" workflow run: |- diff --git a/README.md b/README.md index 6b07169b1c..21ef0e2fe4 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ [![Conda Platforms support Badge](https://img.shields.io/conda/pn/aihabitat/habitat-sim?color=orange&label=platforms)](https://anaconda.org/aihabitat/habitat-sim) [![Documentation](https://img.shields.io/badge/docs-automated-green.svg)](https://aihabitat.org/docs/habitat-sim/) [![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit) -[![Python 3.9](https://img.shields.io/badge/python-3.9.svg)](https://www.python.org/downloads/release/) +[![Python 3.10](https://img.shields.io/badge/python-3.10.svg)](https://www.python.org/downloads/release/) [![Supports Bullet](https://img.shields.io/static/v1?label=supports&message=Bullet%20Physics&color=informational&link=https://opensource.google/projects/bullet3)](https://opensource.google/projects/bullet3) [![Twitter Follow](https://img.shields.io/twitter/follow/ai_habitat?style=social)](https://twitter.com/ai_habitat) diff --git a/conda-build/Dockerfile b/conda-build/Dockerfile index 37b48e96a0..dac1c7baf9 100644 --- a/conda-build/Dockerfile +++ b/conda-build/Dockerfile @@ -32,6 +32,6 @@ ENV PATH /opt/conda/bin:$PATH ADD ./common/install_conda.sh install_conda.sh RUN bash ./install_conda.sh && rm install_conda.sh -RUN conda init bash && conda create --name py39 python=3.9 -y -RUN source ~/.bashrc && conda activate py39 && conda install -y anaconda-client git gitpython ninja conda-build +RUN conda init bash && conda create --name py310 python=3.10 -y +RUN source ~/.bashrc && conda activate py310 && conda install -y anaconda-client git gitpython ninja conda-build RUN conda config --set anaconda_upload yes diff --git a/conda-build/README.md b/conda-build/README.md index b859660fa8..13b9e3944d 100644 --- a/conda-build/README.md +++ b/conda-build/README.md @@ -1,7 +1,7 @@ ### Building for macOS Install conda packages as described here ```conda-build/common/install_conda.sh``` and run ```conda create --name py39 python=3.9 -y;conda activate py39```. -Running ```python matrix_builder.py``` with python >= 3.9 will start the build process by setting all the environment variables and making a call to conda build. Make sure the meta.yaml file in conda-build/habitat-sim/ is configured correctly according to https://docs.conda.io/projects/conda-build/en/latest/resources/define-metadata.html +Running ```python matrix_builder.py``` with python >= 3.10 will start the build process by setting all the environment variables and making a call to conda build. Make sure the meta.yaml file in conda-build/habitat-sim/ is configured correctly according to https://docs.conda.io/projects/conda-build/en/latest/resources/define-metadata.html Once the package is built, make sure you're logged in to anaconda cloud and then run ```anaconda upload ```. For example ```anaconda upload hsim-macos/osx-64/habitat-sim-1.3.2-py3.9_osx.tar.bz2```. This will upload the package to anaconda cloud for everyone to download. diff --git a/conda-build/matrix_builder.py b/conda-build/matrix_builder.py index 11df0e021a..838fd409da 100644 --- a/conda-build/matrix_builder.py +++ b/conda-build/matrix_builder.py @@ -37,7 +37,7 @@ def call(cmd, env=None): def get_default_modes_and_vers(): - py_vers = ["3.9"] + py_vers = ["3.10"] bullet_modes = [False, True] if platform.system() == "Darwin": return py_vers, bullet_modes, [False], [None] @@ -92,7 +92,7 @@ def main(): if args.ci_test: bullet_modes = [True] headless_modes = [get_headless_mode_for_test()] - py_vers = ["3.9"] + py_vers = ["3.10"] for py_ver, use_bullet, headless, cuda_ver in itertools.product( py_vers, bullet_modes, headless_modes, cuda_vers diff --git a/mypy.ini b/mypy.ini index aefffc34da..c7e06e5165 100644 --- a/mypy.ini +++ b/mypy.ini @@ -22,7 +22,7 @@ check_untyped_defs = True files= src_python/habitat_sim, tests -python_version = 3.9 +python_version = 3.10 [mypy-habitat_sim.bindings] ignore_errors = True diff --git a/setup.py b/setup.py index a4deb8e876..590335ddb5 100644 --- a/setup.py +++ b/setup.py @@ -431,7 +431,7 @@ def load(filename): if __name__ == "__main__": assert StrictVersion( "{}.{}".format(sys.version_info[0], sys.version_info[1]) - ) >= StrictVersion("3.9"), "Must use python 3.9 or newer" + ) >= StrictVersion("3.10"), "Must use python 3.10 or newer" with open("./requirements.txt", "r") as f: requirements = [l.strip() for l in f.readlines() if len(l.strip()) > 0] @@ -448,7 +448,7 @@ def load(filename): package_dir={"": "src_python"}, install_requires=requirements, tests_require=["hypothesis", "pytest-benchmark", "pytest"], - python_requires=">=3.9", + python_requires=">=3.10", # add extension module ext_modules=[CMakeExtension("habitat_sim._ext.habitat_sim_bindings", "src")], # add custom build_ext command diff --git a/src/cmake/dependencies.cmake b/src/cmake/dependencies.cmake index 378fb3c952..eac1bd8feb 100644 --- a/src/cmake/dependencies.cmake +++ b/src/cmake/dependencies.cmake @@ -120,7 +120,7 @@ if(BUILD_PYTHON_BINDINGS) # Let the Find module do proper version checks on what we found (it uses the # same PYTHON_EXECUTABLE variable, will pick it up from the cache) - find_package(PythonInterp 3.9 REQUIRED) + find_package(PythonInterp 3.10 REQUIRED) message(STATUS "Bindings being generated for python at ${PYTHON_EXECUTABLE}")