Skip to content

Commit

Permalink
Upgrade astLib for Python>=3.12. (#48)
Browse files Browse the repository at this point in the history
* Upgrade astlib for Python>-3.12.

* Move test matrix to newer python versions.

* Restrict numpy version on older Python versions

* Work around upstream breakage due to pypa/setuptools#4483

---------

Co-authored-by: Benjamin Hugo <[email protected]>
  • Loading branch information
JSKenyon and bennahugo authored Nov 29, 2024
1 parent 6d65b43 commit b946e1d
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 9 deletions.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion .travis/py3.docker → .ci/py3.docker
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ RUN docker-apt-install python3-casacore casacore-dev casacore-data makems casare
libfftw3-dev wcslib-dev libcfitsio-dev \
'libcasa-*' liblapack-dev libatlas-base-dev 2to3

RUN pip install -U pip setuptools wheel
RUN pip install -U pip 'setuptools[core]' wheel
#######################################
# Install python 3 meqtrees
#######################################
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_installation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ ubuntu-20.04, ubuntu-22.04 ]
python-version: ["3.8", "3.9", "3.10"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion Jenkinsfile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ cd $PROJECTS_DIR/meqtrees-tigger-lsm
IMAGENAME="mttiglsmpr"

# build and test
docker build -f .travis/py3.docker -t "${IMAGENAME}36:$BUILD_NUMBER" --no-cache=true .
docker build -f .ci/py3.docker -t "${IMAGENAME}36:$BUILD_NUMBER" --no-cache=true .
2 changes: 1 addition & 1 deletion Tigger/bin/tigger_tag.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ def lookupObject(src, tagname):
for arg in rem_args[1:]:
# Match either the SELTAG<>SELVAL, or the TAG=[TYPE:]VALUE, or the [+!/]TAG forms
# If none match, assume the NAME form
mselcomp = re.match("^(?i)([^=<>!.]+)(%s)([^dms]+)([dms])?" % "|".join(
mselcomp = re.match("(?i)^([^=<>!.]+)(%s)([^dms]+)([dms])?" % "|".join(
[key.replace('.', '\.') for key in list(select_predicates.keys())]), arg)
mseltag = re.match("=(.+)$", arg)
mset = re.match("^(.+)=((bool|int|str|float|complex):)?(.+)$", arg)
Expand Down
20 changes: 15 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,23 @@ packages = [
[tool.poetry.dependencies]
python = "^3.8"
astro-kittens = "^1.4.6"
numpy = "*"
scipy = "*"
numpy = [
{ version = ">=2.0.0", python = ">=3.12"},
{ version = "<2.0.0", python = ">=3.8, <3.12"}
]
scipy = [
{ version = ">=1.13.0", python = ">=3.12"},
{ version = "<1.13.0", python = ">=3.8, <3.12"}
]
astlib = [
{ version = "<=0.11.10", python = ">=3.8"},
{ version = "<=0.11.8", python = "<=3.8"}
{ version = ">=0.12.0", python = ">=3.12"},
{ version = "<=0.11.10", python = ">=3.8, <3.12"},
{ version = "<=0.11.8", python = "<3.8"}
]
astropy = [
{ version = ">=6.1.0", python = ">=3.12"},
{ version = "<6.1.0", python = ">=3.8, <3.12"}
]
astropy = "*"
future = "*"
python-casacore = "*"
meqtrees-cattery = "^1.7.9"
Expand Down

0 comments on commit b946e1d

Please sign in to comment.