diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 88ef2cc..cac5be8 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -16,7 +16,8 @@ jobs: strategy: matrix: version: - - '1.9' + - 'lts' + - '1' os: - ubuntu-latest - macOS-latest @@ -26,7 +27,7 @@ jobs: experimental: [false] steps: - uses: actions/checkout@v2 - - uses: julia-actions/setup-julia@v1 + - uses: julia-actions/setup-julia@v2 with: version: ${{ matrix.version }} arch: ${{ matrix.arch }} @@ -35,7 +36,7 @@ jobs: env: GKSwstype: "100" # https://discourse.julialang.org/t/generation-of-documentation-fails-qt-qpa-xcb-could-not-connect-to-display/60988 - uses: julia-actions/julia-processcoverage@v1 - - uses: codecov/codecov-action@v1 + - uses: codecov/codecov-action@v5 with: file: ./lcov.info flags: unittests diff --git a/Project.toml b/Project.toml index f65df0a..3342a03 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "NeutralLandscapes" uuid = "71847384-8354-4223-ac08-659a5128069f" authors = ["Timothée Poisot ", "Michael Krabbe Borregaard ", "Michael David Catchen ", "Rafael Schouten ", "Virgile Baudrot "] -version = "0.1.5" +version = "0.1.6" [deps] DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8" diff --git a/src/NeutralLandscapes.jl b/src/NeutralLandscapes.jl index 7d890af..dd12814 100644 --- a/src/NeutralLandscapes.jl +++ b/src/NeutralLandscapes.jl @@ -5,7 +5,14 @@ using StatsBase: sample, ZScoreTransform, fit, transform using Random: rand! using Statistics: quantile, mean using Distributions: Normal, LogNormal, MvNormal, Categorical, pdf -using NearestNeighbors: KDTree, knn, nn, always_false, knn_point!, SVector +using NearestNeighbors: KDTree, knn, nn, knn_point!, SVector + +import NearestNeighbors +always_false = Returns(false) +if isdefined(NearestNeighbors, :always_false) + global always_false = NearestNeighbors.always_false +end + using DataStructures: IntDisjointSets, union!, find_root, push! using Base: @kwdef using HaltonSequences: haltonvalue