From 5e543ec700503563f5ae6a68f3130d0d00df6deb Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Thu, 9 May 2024 15:04:12 -0700 Subject: [PATCH 01/15] fix: Adding modifications to codecov.yml --- codecov.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/codecov.yml b/codecov.yml index fd88927cf..eb91a7567 100644 --- a/codecov.yml +++ b/codecov.yml @@ -17,6 +17,7 @@ codecov: require_ci_to_pass: true ignore: - "src/scenic/simulators/**" + - "tests/**" - "!src/scenic/simulators/newtonian/**" - "!src/scenic/simulators/utils/**" cli: From f7771270f29e5e8f2de61c543cb0870a3a116bd1 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Thu, 9 May 2024 15:24:57 -0700 Subject: [PATCH 02/15] feat: Adding new M1 runners to run-test.yml workflow --- .github/workflows/run-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 2a5bb55d1..e73d5bed5 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -34,7 +34,7 @@ jobs: fail-fast: true matrix: python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] - os: [ubuntu-latest, windows-latest] + os: [ubuntu-latest, windows-latest, macos-latest] extras: ["test", "test-full"] runs-on: ${{ matrix.os }} From 0d7f7030d8983c086d695aca0343b9507c47e45c Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 11:24:35 -0700 Subject: [PATCH 03/15] feat: adding intel based mac and fast mode --- .github/workflows/run-tests.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index e73d5bed5..c744c9475 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -13,7 +13,7 @@ on: required: true options: description: Options to pass to pytest. - default: --no-graphics + default: --fast --no-graphics type: string workflow_call: inputs: @@ -22,7 +22,7 @@ on: type: string options: description: Options to pass to pytest. - default: --no-graphics + default: --fast --no-graphics type: string jobs: @@ -34,7 +34,7 @@ jobs: fail-fast: true matrix: python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] - os: [ubuntu-latest, windows-latest, macos-latest] + os: [ubuntu-latest, windows-latest, macos-13, macos-latest] extras: ["test", "test-full"] runs-on: ${{ matrix.os }} @@ -65,6 +65,10 @@ jobs: run: | python -m pip install -e ".[${{ matrix.extras }}]" - - name: Run pytest + - name: Run fast version pytest run: | pytest ${{ inputs.options || '--no-graphics' }} + + - name: Run full tests + if: ${{ matrix.extras == 'test-full' && matrix.python-version == '3.12' }} + run: pytest --no-graphics From 241ae53de6c46dd4a3025edec3958eedce4baa2b Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 11:29:32 -0700 Subject: [PATCH 04/15] fix: Adding default fast mode to workflow --- .github/workflows/run-tests.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index c744c9475..162a92efd 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -65,10 +65,10 @@ jobs: run: | python -m pip install -e ".[${{ matrix.extras }}]" - - name: Run fast version pytest + - name: Run pytest in fast mode run: | - pytest ${{ inputs.options || '--no-graphics' }} + pytest ${{ inputs.options || '--fast --no-graphics' }} - - name: Run full tests + - name: Run pytest in full mode if: ${{ matrix.extras == 'test-full' && matrix.python-version == '3.12' }} run: pytest --no-graphics From f3a791e7a2f3186f62f1a37ae5ea4bba758b53b1 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 11:35:11 -0700 Subject: [PATCH 05/15] fix: adding just test-full dependency installer --- .github/workflows/run-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 162a92efd..29fee5e3e 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -35,7 +35,7 @@ jobs: matrix: python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] os: [ubuntu-latest, windows-latest, macos-13, macos-latest] - extras: ["test", "test-full"] + extras: ["test-full"] runs-on: ${{ matrix.os }} steps: @@ -70,5 +70,5 @@ jobs: pytest ${{ inputs.options || '--fast --no-graphics' }} - name: Run pytest in full mode - if: ${{ matrix.extras == 'test-full' && matrix.python-version == '3.12' }} + if: ${{ matrix.python-version == '3.12' }} run: pytest --no-graphics From 81185560126174e85a394081e1e7227dc0204c31 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 12:17:29 -0700 Subject: [PATCH 06/15] fix: no need to double count ubunut-latest tests as being covered as part of coverage --- .github/workflows/run-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 29fee5e3e..24d722909 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -70,5 +70,5 @@ jobs: pytest ${{ inputs.options || '--fast --no-graphics' }} - name: Run pytest in full mode - if: ${{ matrix.python-version == '3.12' }} + if: ${{ (matrix.os == 'windows-latest' || matrix.os == 'macos-13' || matrix.os == 'macos-latest') && matrix.python-version == '3.12' }} run: pytest --no-graphics From 601ccd25aa4be6973355909e0538cf6144b9c698 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 12:56:41 -0700 Subject: [PATCH 07/15] fix: updating coverage to run on 3.12 --- .github/workflows/run-coverage.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run-coverage.yml b/.github/workflows/run-coverage.yml index 7ec93f84f..34344184c 100644 --- a/.github/workflows/run-coverage.yml +++ b/.github/workflows/run-coverage.yml @@ -22,7 +22,7 @@ jobs: strategy: fail-fast: true matrix: - python-version: ["3.11"] + python-version: ["3.12"] os: [ubuntu-latest] extras: ["test-full"] runs-on: ${{ matrix.os }} From 1bfa904d035dd1615ccf79f30191d3fa4c4dc279 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 13:18:22 -0700 Subject: [PATCH 08/15] fix: adding Pillow reinstallation for run_tests.yml --- .github/workflows/run-tests.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 24d722909..68adfcda1 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -71,4 +71,10 @@ jobs: - name: Run pytest in full mode if: ${{ (matrix.os == 'windows-latest' || matrix.os == 'macos-13' || matrix.os == 'macos-latest') && matrix.python-version == '3.12' }} - run: pytest --no-graphics + + run: | + if [ "${{ matrix.os }}" == "macos-13" ] || [ "${{ matrix.os }}" == "macos-latest" ]; then + python -m pip uninstall Pillow + python3 -m pip install Pillow + fi + pytest --no-graphics From 57144281f58daf932c75b26de7f564327524f696 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 13:33:59 -0700 Subject: [PATCH 09/15] fix: updating step --- .github/workflows/run-tests.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 68adfcda1..d50b40e40 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -70,11 +70,10 @@ jobs: pytest ${{ inputs.options || '--fast --no-graphics' }} - name: Run pytest in full mode - if: ${{ (matrix.os == 'windows-latest' || matrix.os == 'macos-13' || matrix.os == 'macos-latest') && matrix.python-version == '3.12' }} - + if: ${{ matrix.python-version == '3.12' }} run: | - if [ "${{ matrix.os }}" == "macos-13" ] || [ "${{ matrix.os }}" == "macos-latest" ]; then + if [ "${{ runner.os }}" == "macOS" ]; then python -m pip uninstall Pillow - python3 -m pip install Pillow + python -m pip install Pillow fi pytest --no-graphics From 4601e0ae3f8f75847f5d2ff6130edc725baf44ee Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 13:50:04 -0700 Subject: [PATCH 10/15] fix: adding yes options --- .github/workflows/run-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index d50b40e40..3e959896b 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -73,7 +73,7 @@ jobs: if: ${{ matrix.python-version == '3.12' }} run: | if [ "${{ runner.os }}" == "macOS" ]; then - python -m pip uninstall Pillow - python -m pip install Pillow + python -m pip uninstall Pillow -y + python -m pip install Pillow -y fi pytest --no-graphics From 84a6ff017c9405ef71daaa8f1ca8e153871c4e6c Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 14:29:33 -0700 Subject: [PATCH 11/15] fix: updating dependenices for 3.12 Pillow --- .github/workflows/run-tests.yml | 7 +------ pyproject.toml | 3 ++- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 3e959896b..29fee5e3e 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -71,9 +71,4 @@ jobs: - name: Run pytest in full mode if: ${{ matrix.python-version == '3.12' }} - run: | - if [ "${{ runner.os }}" == "macOS" ]; then - python -m pip uninstall Pillow -y - python -m pip install Pillow -y - fi - pytest --no-graphics + run: pytest --no-graphics diff --git a/pyproject.toml b/pyproject.toml index e69b47d05..3d2135bd3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -37,7 +37,8 @@ dependencies = [ "numpy ~= 1.24", "opencv-python ~= 4.5", "pegen >= 0.3.0", - "pillow ~= 9.1", + 'pillow ~= 9.1; python_version <= "3.11"', + 'pillow ~= 10.3; python_version > "3.11"', 'pygame >= 2.1.3.dev8, <3; python_version >= "3.11"', 'pygame ~= 2.0; python_version < "3.11"', "pyglet ~= 1.5", From 9ff8803eade8e0176d2d810865146baeb14d6371 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Mon, 13 May 2024 15:31:31 -0700 Subject: [PATCH 12/15] fix: avoiding ubuntu as its being covered as part of the coverage run --- .github/workflows/run-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 29fee5e3e..24d722909 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -70,5 +70,5 @@ jobs: pytest ${{ inputs.options || '--fast --no-graphics' }} - name: Run pytest in full mode - if: ${{ matrix.python-version == '3.12' }} + if: ${{ (matrix.os == 'windows-latest' || matrix.os == 'macos-13' || matrix.os == 'macos-latest') && matrix.python-version == '3.12' }} run: pytest --no-graphics From 4ee43bd3cd257e06490153743fd68d84c7aedb59 Mon Sep 17 00:00:00 2001 From: Armando Banuelos Date: Thu, 16 May 2024 13:04:23 -0700 Subject: [PATCH 13/15] fix: Adding lower bound for pillow dependency --- pyproject.toml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 3d2135bd3..e9340c8a9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -37,8 +37,7 @@ dependencies = [ "numpy ~= 1.24", "opencv-python ~= 4.5", "pegen >= 0.3.0", - 'pillow ~= 9.1; python_version <= "3.11"', - 'pillow ~= 10.3; python_version > "3.11"', + "pillow >= 9.5", 'pygame >= 2.1.3.dev8, <3; python_version >= "3.11"', 'pygame ~= 2.0; python_version < "3.11"', "pyglet ~= 1.5", From eedaf8da61da081135507523bf75a8cb16acb55e Mon Sep 17 00:00:00 2001 From: Daniel Fremont Date: Fri, 13 Dec 2024 14:56:37 -0800 Subject: [PATCH 14/15] fix fast/slow test selection logic --- .github/workflows/run-tests.yml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 24d722909..03cb0f24e 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -35,7 +35,10 @@ jobs: matrix: python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] os: [ubuntu-latest, windows-latest, macos-13, macos-latest] - extras: ["test-full"] + include: + # Only run slow tests on the latest version of Python + - python-version: "3.12" + slow: true runs-on: ${{ matrix.os }} steps: @@ -63,12 +66,8 @@ jobs: - name: Install Scenic and dependencies run: | - python -m pip install -e ".[${{ matrix.extras }}]" + python -m pip install -e ".[test-full]" - - name: Run pytest in fast mode + - name: Run pytest run: | - pytest ${{ inputs.options || '--fast --no-graphics' }} - - - name: Run pytest in full mode - if: ${{ (matrix.os == 'windows-latest' || matrix.os == 'macos-13' || matrix.os == 'macos-latest') && matrix.python-version == '3.12' }} - run: pytest --no-graphics + pytest ${{ inputs.options || (matrix.slow && '--no-graphics' || '--fast --no-graphics') }} From 409209b77a5d84ca7bc8a2ce942e79b475862705 Mon Sep 17 00:00:00 2001 From: Daniel Fremont Date: Fri, 13 Dec 2024 15:55:42 -0800 Subject: [PATCH 15/15] workflow calls to run-tests should do all tests by default --- .github/workflows/run-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 03cb0f24e..f24b21dd8 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -13,7 +13,7 @@ on: required: true options: description: Options to pass to pytest. - default: --fast --no-graphics + default: --no-graphics type: string workflow_call: inputs: @@ -22,7 +22,7 @@ on: type: string options: description: Options to pass to pytest. - default: --fast --no-graphics + default: --no-graphics type: string jobs: