Skip to content

Commit bd04220

Browse files
authored
Merge pull request #1847 from davejames/overrides_propcache
overrides: update build system for propcache
2 parents f7f9446 + 9ebc598 commit bd04220

5 files changed

Lines changed: 142 additions & 0 deletions

File tree

overrides/default.nix

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2253,6 +2253,11 @@ lib.composeManyExtensions [
22532253
propagatedBuildInputs = old.propagatedBuildInputs or [ ] ++ [ final.setuptools ];
22542254
});
22552255

2256+
propcache = prev.propcache.overridePythonAttrs (old: {
2257+
nativeBuildInputs = old.nativeBuildInputs or [ ]
2258+
++ lib.optionals (final.pythonOlder "3.11") [ final.tomli ];
2259+
});
2260+
22562261
prophet = prev.prophet.overridePythonAttrs (old: {
22572262
propagatedBuildInputs = old.propagatedBuildInputs or [ ] ++ [ pkgs.cmdstan final.cmdstanpy ];
22582263
PROPHET_REPACKAGE_CMDSTAN = "false";

tests/default.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,7 @@ in
179179
dask-dataframe = callTest ./dask-dataframe { };
180180
argon2-cffi-bindings-python-3-12 = callTest ./argon2-cffi-bindings-python-3-12 { };
181181
cyclonedx-and-sarif-tools = callTest ./cyclonedx-and-sarif-tools { };
182+
propcache = callTest ./propcache { };
182183
} // lib.optionalAttrs (!stdenv.isDarwin) {
183184
# Editable tests fails on Darwin because of sandbox paths
184185
pep600 = callTest ./pep600 { };

tests/propcache/default.nix

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{ poetry2nix, python310, runCommand }:
2+
let
3+
env = poetry2nix.mkPoetryEnv {
4+
python = python310;
5+
projectDir = ./.;
6+
};
7+
in
8+
runCommand "propcache-test" { } ''
9+
${env}/bin/python -c 'import propcache; print(propcache.__version__)' > $out
10+
''

tests/propcache/poetry.lock

Lines changed: 113 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/propcache/pyproject.toml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
[tool.poetry]
2+
name = "propcache-test"
3+
version = "0.1.0"
4+
description = "Test of propcache"
5+
authors = ["Your Name <you@example.com>"]
6+
7+
[tool.poetry.dependencies]
8+
python = "^3.9"
9+
propcache = "*"
10+
11+
[build-system]
12+
requires = ["poetry-core>=1"]
13+
build-backend = "poetry.core.masonry.api"

0 commit comments

Comments
 (0)