comparison contrib/heptapod-ci.yml @ 51713:74f1bf147a6d

heptapod-ci: use new v2.1 image This is finally catching up to ~3 years of tech debt.
author Raphaël Gomès <rgomes@octobus.net>
date Tue, 23 Jul 2024 12:12:22 +0200
parents e153995011b7
children 6cc18075f82a
comparison
equal deleted inserted replaced
51712:e153995011b7 51713:74f1bf147a6d
25 image: registry.heptapod.net/mercurial/ci-images/mercurial-core:$HG_CI_IMAGE_TAG 25 image: registry.heptapod.net/mercurial/ci-images/mercurial-core:$HG_CI_IMAGE_TAG
26 26
27 variables: 27 variables:
28 PYTHON: python 28 PYTHON: python
29 TEST_HGMODULEPOLICY: "allow" 29 TEST_HGMODULEPOLICY: "allow"
30 HG_CI_IMAGE_TAG: "v1.0" 30 HG_CI_IMAGE_TAG: "v2.1"
31 TEST_HGTESTS_ALLOW_NETIO: "0" 31 TEST_HGTESTS_ALLOW_NETIO: "0"
32 32
33 .all_template: &all 33 .all_template: &all
34 when: on_success 34 when: on_success
35 35
37 <<: *all 37 <<: *all
38 stage: tests 38 stage: tests
39 # The runner made a clone as root. 39 # The runner made a clone as root.
40 # We make a new clone owned by user used to run the step. 40 # We make a new clone owned by user used to run the step.
41 before_script: 41 before_script:
42 - export PATH="/home/ci-runner/vendor/pyenv/pyenv-2.4.7-adf3c2bccf09cdb81febcfd15b186711a33ac7a8/shims:/home/ci-runner/vendor/pyenv/pyenv-2.4.7-adf3c2bccf09cdb81febcfd15b186711a33ac7a8/bin:$PATH"
42 - echo "python used, $PYTHON" 43 - echo "python used, $PYTHON"
43 - $PYTHON --version 44 - $PYTHON --version
44 - black --version 45 - black --version
45 - clang-format --version 46 - clang-format --version
46 - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no 47 - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no
53 54
54 checks: 55 checks:
55 <<: *runtests 56 <<: *runtests
56 variables: 57 variables:
57 RUNTEST_ARGS: "--time --test-list /tmp/check-tests.txt" 58 RUNTEST_ARGS: "--time --test-list /tmp/check-tests.txt"
58 PYTHON: python3
59 CI_CLEVER_CLOUD_FLAVOR: S 59 CI_CLEVER_CLOUD_FLAVOR: S
60 60
61 rust-cargo-test: 61 rust-cargo-test:
62 <<: *all 62 <<: *all
63 stage: tests 63 stage: tests
64 script: 64 script:
65 - make rust-tests 65 - make rust-tests
66 - make cargo-clippy 66 - make cargo-clippy
67 variables: 67 variables:
68 PYTHON: python3
69 CI_CLEVER_CLOUD_FLAVOR: S 68 CI_CLEVER_CLOUD_FLAVOR: S
70 69
71 test-c: 70 test-c:
72 <<: *runtests 71 <<: *runtests
73 variables: 72 variables:
74 RUNTEST_ARGS: " --no-rust --blacklist /tmp/check-tests.txt" 73 RUNTEST_ARGS: " --no-rust --blacklist /tmp/check-tests.txt"
75 PYTHON: python3
76 TEST_HGMODULEPOLICY: "c" 74 TEST_HGMODULEPOLICY: "c"
77 TEST_HGTESTS_ALLOW_NETIO: "1" 75 TEST_HGTESTS_ALLOW_NETIO: "1"
78 76
79 test-pure: 77 test-pure:
80 <<: *runtests 78 <<: *runtests
81 variables: 79 variables:
82 RUNTEST_ARGS: "--pure --blacklist /tmp/check-tests.txt" 80 RUNTEST_ARGS: "--pure --blacklist /tmp/check-tests.txt"
83 PYTHON: python3
84 TEST_HGMODULEPOLICY: "py" 81 TEST_HGMODULEPOLICY: "py"
85 82
86 test-rust: 83 test-rust:
87 <<: *runtests 84 <<: *runtests
88 variables: 85 variables:
89 HGWITHRUSTEXT: cpython 86 HGWITHRUSTEXT: cpython
90 RUNTEST_ARGS: "--rust --blacklist /tmp/check-tests.txt" 87 RUNTEST_ARGS: "--rust --blacklist /tmp/check-tests.txt"
91 PYTHON: python3
92 TEST_HGMODULEPOLICY: "rust+c" 88 TEST_HGMODULEPOLICY: "rust+c"
93 89
94 test-rhg: 90 test-rhg:
95 <<: *runtests 91 <<: *runtests
96 variables: 92 variables:
97 HGWITHRUSTEXT: cpython 93 HGWITHRUSTEXT: cpython
98 RUNTEST_ARGS: "--rust --rhg --blacklist /tmp/check-tests.txt" 94 RUNTEST_ARGS: "--rust --rhg --blacklist /tmp/check-tests.txt"
99 PYTHON: python3
100 TEST_HGMODULEPOLICY: "rust+c" 95 TEST_HGMODULEPOLICY: "rust+c"
101 96
102 test-chg: 97 test-chg:
103 <<: *runtests 98 <<: *runtests
104 variables: 99 variables:
105 PYTHON: python3
106 RUNTEST_ARGS: "--blacklist /tmp/check-tests.txt --chg" 100 RUNTEST_ARGS: "--blacklist /tmp/check-tests.txt --chg"
107 TEST_HGMODULEPOLICY: "c" 101 TEST_HGMODULEPOLICY: "c"
108 102
109 check-pytype: 103 check-pytype:
110 extends: .runtests_template 104 extends: .runtests_template
111 before_script: 105 before_script:
106 - export PATH="/home/ci-runner/vendor/pyenv/pyenv-2.4.7-adf3c2bccf09cdb81febcfd15b186711a33ac7a8/shims:/home/ci-runner/vendor/pyenv/pyenv-2.4.7-adf3c2bccf09cdb81febcfd15b186711a33ac7a8/bin:$PATH"
107 - echo "PATH, $PATH"
112 - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no 108 - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no
113 - hg -R /tmp/mercurial-ci/ update `hg log --rev '.' --template '{node}'` 109 - hg -R /tmp/mercurial-ci/ update `hg log --rev '.' --template '{node}'`
114 - cd /tmp/mercurial-ci/ 110 - cd /tmp/mercurial-ci/
115 - make local PYTHON=$PYTHON 111 - make local PYTHON=$PYTHON
116 - $PYTHON -m pip install --user -U libcst==0.3.20 pytype==2022.11.18
117 - ./contrib/setup-pytype.sh 112 - ./contrib/setup-pytype.sh
118 script: 113 script:
119 - echo "Entering script section" 114 - echo "Entering script section"
120 - sh contrib/check-pytype.sh 115 - sh contrib/check-pytype.sh
121 variables:
122 PYTHON: python3
123 116
124 # `sh.exe --login` sets a couple of extra environment variables that are defined 117 # `sh.exe --login` sets a couple of extra environment variables that are defined
125 # in the MinGW shell, but switches CWD to /home/$username. The previous value 118 # in the MinGW shell, but switches CWD to /home/$username. The previous value
126 # is stored in OLDPWD. Of the added variables, MSYSTEM is crucial to running 119 # is stored in OLDPWD. Of the added variables, MSYSTEM is crucial to running
127 # run-tests.py- it is needed to make run-tests.py generate a `python3` script 120 # run-tests.py- it is needed to make run-tests.py generate a `python3` script