Skip to content

Commit

Permalink
Merge pull request #234 from MridulS/scipp_pypi
Browse files Browse the repository at this point in the history
Use scipp from pypi index instead of github url for nightlies
  • Loading branch information
MridulS authored Dec 3, 2024
2 parents 2ed79d9 + d61c047 commit 49d29ec
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
15 changes: 9 additions & 6 deletions template/requirements/make_base.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import sys
from argparse import ArgumentParser
from pathlib import Path

Expand Down Expand Up @@ -58,11 +57,15 @@ def as_nightly(repo: str) -> str:
else:
org = "scipp"
if repo == "scipp":
version = f"cp{sys.version_info.major}{sys.version_info.minor}"
base = "https://github.com/scipp/scipp/releases/download/nightly/scipp-nightly"
suffix = "manylinux_2_17_x86_64.manylinux2014_x86_64.whl"
prefix = "scipp @ "
return prefix + "-".join([base, version, version, suffix])
# With the standard pip resolver index-url takes precedence over
# extra-index-url but with uv it's reversed, so if we move to tox-uv
# this needs to be reversed.
return (
"scipp\n"
"--index-url=https://pypi.anaconda.org/scipp-nightly-wheels/simple/\n"
"--extra-index-url=https://pypi.org/simple\n"
"--pre"
)
return f"{repo} @ git+https://github.com/{org}/{repo}@main"


Expand Down
3 changes: 3 additions & 0 deletions template/tox.ini.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ commands = pytest {posargs}

[testenv:nightly]
deps = -r requirements/nightly.txt
setenv =
PIP_INDEX_URL = https://pypi.anaconda.org/scipp-nightly-wheels/simple
PIP_EXTRA_INDEX_URL = https://pypi.org/simple
commands = pytest {posargs}

[testenv:unpinned]
Expand Down

0 comments on commit 49d29ec

Please sign in to comment.