Skip to content

Commit 05853c6

Browse files
authored
Fix nightly notebook test (#6964)
### What * change to buildjet runner to avoid out of disk memory issue * handle platform independent wheel in pixi_install_wheel.py ### Checklist * [x] yes - [PR Build Summary](https://build.rerun.io/pr/6964) - [Recent benchmark results](https://build.rerun.io/graphs/crates.html) - [Wasm size tracking](https://build.rerun.io/graphs/sizes.html) To run all checks from `main`, comment on the PR with `@rerun-bot full-check`.
1 parent f7d9e1c commit 05853c6

File tree

2 files changed

+23
-8
lines changed

2 files changed

+23
-8
lines changed

.github/workflows/reusable_run_notebook.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ permissions:
2626
jobs:
2727
run-notebook:
2828
name: Run notebook
29-
runs-on: ubuntu-latest
29+
runs-on: ubuntu-latest-16-cores # Note that as of writing we need the additional storage page (14 gb of the ubunut-latest runner is not enough).
3030
container:
3131
image: rerunio/ci_docker:0.14.0 # Required to run the wheel or we get "No matching distribution found for attrs>=23.1.0" during `pip install rerun-sdk`
3232
steps:
@@ -59,7 +59,7 @@ jobs:
5959
- name: Install built wheel
6060
run: |
6161
pixi run python scripts/ci/pixi_install_wheel.py --feature python-pypi --package rerun-sdk --dir wheel
62-
pixi run python scripts/ci/pixi_install_wheel.py --feature python-pypi --package rerun-notebook --dir wheel
62+
pixi run python scripts/ci/pixi_install_wheel.py --feature python-pypi --package rerun-notebook --dir wheel --platform-independent
6363
6464
- name: Install Deps
6565
run: pixi run -e wheel-test pip install -r examples/python/notebook/requirements.txt

scripts/ci/pixi_install_wheel.py

+21-6
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
from pathlib import Path
2222

2323

24-
def run_pixi_install(feature: str, dir: str, pkg: str) -> None:
24+
def run_pixi_install(feature: str, dir: str, pkg: str, platform_independent: bool = False) -> None:
2525
# Find our current platform: linux, macosx, or win
2626
plat = platform.system()
2727
if plat == "Linux":
@@ -46,17 +46,27 @@ def run_pixi_install(feature: str, dir: str, pkg: str) -> None:
4646
wheels = [whl for whl in wheels if whl.startswith(pkg.replace("-", "_"))]
4747

4848
# Filter the wheels based on platform
49-
wheels = [whl for whl in wheels if plat in whl]
49+
if not platform_independent:
50+
wheels = [whl for whl in wheels if plat in whl]
5051

5152
# Filter the wheels based on architecture
52-
wheels = [whl for whl in wheels if arch in whl]
53+
if not platform_independent:
54+
wheels = [whl for whl in wheels if arch in whl]
5355

5456
if len(wheels) == 0:
55-
print(f"No wheels found for package {pkg} on platform {plat} and architecture {arch}")
57+
if platform_independent:
58+
print(f"No wheels found for package {pkg} (the package was expected to be platform independent)")
59+
else:
60+
print(f"No wheels found for package {pkg} on platform {plat} and architecture {arch}")
5661
sys.exit(1)
5762

5863
if len(wheels) > 1:
59-
print(f"Multiple wheels found for package {pkg} on platform {plat} and architecture {arch}: {wheels}")
64+
if platform_independent:
65+
print(
66+
f"Multiple wheels found for package {pkg} (the package was expected to be platform independent): {wheels}"
67+
)
68+
else:
69+
print(f"Multiple wheels found for package {pkg} on platform {plat} and architecture {arch}: {wheels}")
6070
sys.exit(1)
6171

6272
wheel = Path(dir) / wheels[0]
@@ -77,9 +87,14 @@ def main() -> None:
7787
parser.add_argument("--feature", required=True, help="The pixi feature to update")
7888
parser.add_argument("--dir", required=True, help="Directory to search")
7989
parser.add_argument("--package", required=True, help="The package to install")
90+
parser.add_argument(
91+
"--platform-independent",
92+
action="store_true",
93+
help="Specify if the wheel is platform independent and there should be no filtering for architecture & platform",
94+
)
8095
args = parser.parse_args()
8196

82-
run_pixi_install(args.feature, args.dir, args.package)
97+
run_pixi_install(args.feature, args.dir, args.package, args.platform_independent)
8398

8499

85100
if __name__ == "__main__":

0 commit comments

Comments
 (0)