Restore python 3.6 and update CI to import module after installing - #178
Restore python 3.6 and update CI to import module after installing#178tynanford wants to merge 1 commit into
Conversation
6d7fba5 to
50e818a
Compare
anderslindho
left a comment
There was a problem hiding this comment.
Unfortunately this doesn’t work as-is - note Successfully installed UNKNOWN-0.0.0 in the 3.6 build log.
We’ll have to reintroduce setup.cfg, move the [project] / package metadata out of pyproject.toml, pin setuptools to something that still runs on 3.6, and fix the smoke test: right now PYTHONPATH=. imports from the checkout even when install failed, so it can’t catch this. After a real pip install ., run the import from /tmp (or any dir outside server/) so it has to use the installed package. We should probably also set ruff to py37 (it doesn’t support 36).
| minor=$(python3 --version | cut -d. -f2) | ||
| if [ "$minor" -ge 7 ]; then | ||
| python -m pip install --upgrade "pip==24.0" --only-binary=:all: | ||
| python -m pip install . |
d4e143f to
e237c69
Compare
|
|
Ah, good catch. Instead of reverting back to setup.cfg I propose we just have the CI test the import without installing it as a package. Confirmed in a test commit here that the CI will fail for py3.6 - py3.8 with Sonarqube is complaining i think because we don't have pinned exact versions in the pyproject.toml file. To me it seems like something that could be dismissed? |




#177
This updates processors.py and recast.py to work with python3.6 and above - updated type hints and remove removeprefix which is >=3.9
Had claude help with updating the CI. It now actually imports the package as @anderslindho mentioned and manually installs the pip packages for 3.6 since setuptools on 3.6 doesn't work with the pyproject.toml setup. Claude also found an issue with the pyproject.toml file: The <3.8 and <3.7 lines for requests and twisted overlap for python 3.6.