diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b57d6a1ce..4f3bc32d4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -87,19 +87,21 @@ jobs: run: pip install maturin poetry toml - name: Create an isolated example directory run: cp -r examples/simple-extension/ ../simple-extension-msrv - - name: Edit Cargo.toml + - name: Edit Cargo.toml and change the path of rust-numpy run: | import toml cargo_toml = toml.load("Cargo.toml") + cargo_toml["dependencies"]["numpy"]["path"] = "../rust-numpy" cargo_toml["dependencies"]["ndarray"] = "0.13.1" cargo_toml["dependencies"]["num-complex"] = "0.2.4" - cargo_toml["dependencies"]["numpy"]["path"] = "../rust-numpy" with open("Cargo.toml", "w") as f: toml.dump(cargo_toml, f) working-directory: ../simple-extension-msrv shell: python - - name: Remove ndarray 0.14.0 - run: cargo update -p ndarray:0.14.0 --precise 0.13.1 + - name: Use ndarray 0.13.1 + run: | + cargo generate-lockfile + cargo update -p $(cargo pkgid -p ndarray 2>&1 >/dev/null | grep 0.15 | sed -e 's/^[ \t]*//') --precise 0.13.1 working-directory: ../simple-extension-msrv - name: Test Example run: | diff --git a/Cargo.toml b/Cargo.toml index 514d34e18..79c114f1a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,7 +18,7 @@ cfg-if = "0.1" libc = "0.2" num-complex = ">= 0.2, <= 0.4" num-traits = "0.2" -ndarray = ">= 0.13, < 0.15" +ndarray = ">= 0.13, < 0.16" pyo3 = { version = "0.13", default-features = false } [dev-dependencies] @@ -29,6 +29,5 @@ pyo3 = "0.13" default = [] rayon = ["ndarray/rayon"] - [workspace] -members = ["examples/*"] +members = ["examples/*"] \ No newline at end of file diff --git a/examples/linalg/Cargo.toml b/examples/linalg/Cargo.toml index 848ecec3a..7d15ab44e 100644 --- a/examples/linalg/Cargo.toml +++ b/examples/linalg/Cargo.toml @@ -10,8 +10,9 @@ crate-type = ["cdylib"] [dependencies] numpy = { path = "../.." } -ndarray = "0.14" -ndarray-linalg = { version = "0.13", features = ["openblas-static"] } +ndarray = "0.15" +# ndarray-linalg = { version = "0.13", features = ["openblas-static"] } +ndarray-linalg = { git = "https://github.com/rust-ndarray/ndarray-linalg", features = ["openblas-static"] } [dependencies.pyo3] version = "0.13" diff --git a/examples/simple-extension/Cargo.toml b/examples/simple-extension/Cargo.toml index a7304a4a5..6136b7952 100644 --- a/examples/simple-extension/Cargo.toml +++ b/examples/simple-extension/Cargo.toml @@ -10,8 +10,8 @@ crate-type = ["cdylib"] [dependencies] numpy = { path = "../.." } -ndarray = "0.14" -num-complex = "0.3" +ndarray = "0.15.2" +num-complex = "0.4.0" [dependencies.pyo3] version = "0.13"