From 3474ff821f033bd740009c13e3c14bf92ffda918 Mon Sep 17 00:00:00 2001 From: Stuart Mumford Date: Mon, 12 Feb 2024 15:02:14 +0000 Subject: [PATCH] Attempt to fix CI - 1 --- .circleci/config.yml | 33 +++++++------------ ...ure_hashes_mpl_381_ft_261_astropy_534.json | 30 ++++++++--------- tox.ini | 11 ++++--- 3 files changed, 33 insertions(+), 41 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 715be41..2b8b23f 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -20,37 +20,28 @@ merge-check: &merge-check git checkout -qf pr/$CIRCLE_PR_NUMBER/merge fi -apt-run: &pyenv-install - name: Install other python versions - command: | - pyenv global 3.11.6 - if [[ $TOXENV = *39* ]] - then - pyenv install 3.9.18 - pyenv global 3.9.18 3.11.6 - fi - jobs: figure: parameters: jobname: type: string + image: + type: string docker: - - image: cimg/python:3.11.6 + - image: << parameters.image >> environment: TOXENV=<< parameters.jobname >> steps: - run: *no-backports - checkout - run: *skip-check - run: *merge-check - - run: *pyenv-install - run: pip install --user -U tox tox-pypi-filter - run: tox -v - run: name: Running codecov command: bash -e .circleci/codecov_upload.sh -f ".tmp/${TOXENV}/coverage.xml" - store_artifacts: - path: .tmp/<< parameters.jobname >>/figure_test_images + path: .tmp/<< parameters.name >>/figure_test_images - run: name: "Image comparison page is available at: " command: echo "${CIRCLE_BUILD_URL}/artifacts/${CIRCLE_NODE_INDEX}/.tmp/${TOXENV}/figure_test_images/fig_comparison.html" @@ -68,7 +59,6 @@ jobs: - checkout - run: *skip-check - run: *merge-check - - run: *pyenv-install # Clear out all the ssh keys so that it always uses the write deploy key - run: ssh-add -D # Add private key for deploying to the figure tests repo @@ -98,13 +88,14 @@ workflows: figure-tests: jobs: - figure: - name: << matrix.jobname >> - matrix: - parameters: - jobname: - - "py311-figure" - - "py311-figure-devdeps" - - "py39-figure-oldestdeps" + jobname: "py311-figure" + image: "cimg/python:3.11" + - figure: + jobname: "py311-figure-devdeps" + image: "cimg/python:3.11" + - figure: + jobname: "py39-figure-oldestdeps" + image: "cimg/python:3.9" - deploy-reference-images: name: baseline-<< matrix.jobname >> diff --git a/mpl_animators/tests/figure_hashes_mpl_381_ft_261_astropy_534.json b/mpl_animators/tests/figure_hashes_mpl_381_ft_261_astropy_534.json index eb32bc9..aff87e9 100644 --- a/mpl_animators/tests/figure_hashes_mpl_381_ft_261_astropy_534.json +++ b/mpl_animators/tests/figure_hashes_mpl_381_ft_261_astropy_534.json @@ -1,16 +1,16 @@ { - "mpl_animators.tests.test_basefuncanimator.test_lineanimator_figure": "6865a446680cb7088d71becd653e3c9e9e8e982d71956c95f690d52365bfe106", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_simple_plot": "1d0b9c13e72d288e09d1ab85fe3b4df38d6b349eae661c54cf32c18f0af451c6", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_clip_interval": "a78d4ca84423abcde116efeef4631cdf36d98033c71ad038363a033857743776", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_celestial_sliders": "14fc82e6778a7725092a691f210f05420e5669099fe8cb21260fd44336e57f8e", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_update_plot": "0c4a39742b55c4c9eb1336de59891c1e1459e656992505528f245783e4c7cf12", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_transpose_update_plot": "fca79fbb72e9650df3e64beb383b68a7816cfdfd95fa632386f65b5e6d32b5e4", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_colorbar_buttons": "dc5d08188e888fb6b93843b38a1604b8847aec38dc1ba53fa8ef108da6e790d6", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_colorbar_buttons_default_labels": "3026f941a8cf87347e6793b6002dda370eae6036e13961ae7323c3a4fe60d1d1", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_extra_sliders": "fd94e25c0b6a813818c8ab1b42c6d8828e546acf30ea9bc73164e50b22f456ba", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_1d_update_plot": "0618fba2b4285904d3594b4b3d76ebd56337cf2ad4c00aa568ac111f6d3e52aa", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_1d_update_plot_masked": "ae635463aaa2da4d494e9e90f040d39adf452eda92ad5f1c988b5be0bf437185", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_coord_params": "6535c5d4c7cfb9699bf99c4ad1919e9854626c5633eaa4d9aa97d5003408634a", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_coord_params_no_ticks": "536034d8e761ef5d2fdfbf8911c4ab9bbc96308328594befb44d0837eccd671e", - "mpl_animators.tests.test_wcs.test_array_animator_wcs_coord_params_grid": "5b81acf2215c9b8c1a700e2e7371f43be3177363abfe9729b6746eedd7d16686" -} + "mpl_animators.tests.test_basefuncanimator.test_lineanimator_figure": "54c06fd1880b1dced26a04a9eef085cee85c6ca5f49e7592a37e2a5718e1ddde", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_simple_plot": "5acc92c2e80958b917c62eec450c1d9079ab11dd8c15847150b220d47a0a6c23", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_clip_interval": "268f6c856a1418a03c04208c30de338f0996f13d12a6f5d86a0a456e1b9727b9", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_celestial_sliders": "5b8f06c39ccee8d9f87e217371a75ae1200e0278bd7b30397108c989b0da3340", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_update_plot": "4684a2badfb21b93b119c03e51dce7c9b9a8230b240f08a629aaa877ee2d919d", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_transpose_update_plot": "7d81a44f4bee052aa63f6b3bfb4ada33e472a5cc85cd6d15f0c611573c4b81b4", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_colorbar_buttons": "c48e906d7c948cda50fcbee3f29699677ca8a1a1e4cf490899fc9c0c50c021d5", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_colorbar_buttons_default_labels": "d2edfbafada8ddda6b20cec1df44704530396210a4f9c1ea1fbb95a3a5b09dda", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_2d_extra_sliders": "32edfb4680678724f5571b9e529cc5902c27fd6551c736514e0fd7d999935118", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_1d_update_plot": "51133ebf0b8f894bc1287caae95ae0a3366094adc814ea17fa38db6b36b03ed9", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_1d_update_plot_masked": "bbba7914b36133c7c56897dbdf0edda456f21fa420575908c1f8349d4ce8ca3a", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_coord_params": "dd93c738681661428c494cc60685c32ce2a4df005ff13eb4fc8030e20bdf34a5", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_coord_params_no_ticks": "02c0afbce56aa065b2efae71f5045244b56eca9eecbbff33d287d72108705e6e", + "mpl_animators.tests.test_wcs.test_array_animator_wcs_coord_params_grid": "4020da1a819466292082eb9d31ebaa5b7dd5832573c145bad092185a522f835f" +} \ No newline at end of file diff --git a/tox.ini b/tox.ini index f3c441d..3f32e58 100644 --- a/tox.ini +++ b/tox.ini @@ -25,15 +25,16 @@ extras = all tests setenv = - PYTEST_COMMAND = pytest -vvv -s -raR --pyargs mpl_animators --cov-report=xml --cov=mpl_animators {toxinidir}/docs + PYTEST_COMMAND = pytest -v -raR --pyargs mpl_animators --cov-report=xml --cov=mpl_animators {toxinidir}/docs MPL_BACKEND = agg -allowlist_externals = /bin/bash +allowlist_externals = /bin/sh commands = pip freeze !figure: {env:PYTEST_COMMAND} {posargs} - figure: /bin/bash -c "mkdir -p ./figure_test_images; python -c 'import matplotlib as mpl; print(mpl.ft2font.__file__, mpl.ft2font.__freetype_version__, mpl.ft2font.__freetype_build_type__)' > ./figure_test_images/figure_version_info.txt" - figure: /bin/bash -c "pip freeze >> ./figure_test_images/figure_version_info.txt" - figure: /bin/bash -c "cat ./figure_test_images/figure_version_info.txt" + figure: /bin/sh -c "mkdir -p ./figure_test_images" + figure: /bin/sh -c "python -c 'import matplotlib as mpl; print(mpl.ft2font.__file__, mpl.ft2font.__freetype_version__, mpl.ft2font.__freetype_build_type__)' > ./figure_test_images/figure_version_info.txt" + figure: /bin/sh -c "pip freeze >> ./figure_test_images/figure_version_info.txt" + figure: /bin/sh -c "cat ./figure_test_images/figure_version_info.txt" figure: python -c "import mpl_animators.tests.helpers as h; print(h.get_hash_library_name())" figure: {env:PYTEST_COMMAND} -m "mpl_image_compare" --mpl --mpl-generate-summary=html --mpl-baseline-path=https://raw.githubusercontent.com/sunpy/sunpy-figure-tests/mpl-animators-main/figures/{envname}/ {posargs}