From a05a1e336ca8a1f54b64f9c8a01d8de3e6fb7c64 Mon Sep 17 00:00:00 2001 From: Paul Date: Sun, 30 Jan 2022 16:52:03 +0100 Subject: [PATCH 1/3] fix is_stdlib() for nightly and enable nightly tests --- .github/workflows/Test.yml | 2 +- src/packages/PkgCompat.jl | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/Test.yml b/.github/workflows/Test.yml index eaa6a1ff72..f6b38090b6 100644 --- a/.github/workflows/Test.yml +++ b/.github/workflows/Test.yml @@ -29,7 +29,7 @@ jobs: strategy: matrix: # We test quite a lot of versions because we do some OS and version specific things unfortunately - julia-version: ["1.5", "1.6", "1.7"] #, "nightly"] + julia-version: ["1.5", "1.6", "1.7", "nightly"] os: [ubuntu-latest, macOS-latest, windows-latest] steps: diff --git a/src/packages/PkgCompat.jl b/src/packages/PkgCompat.jl index 9d5d812385..4602ac9ccc 100644 --- a/src/packages/PkgCompat.jl +++ b/src/packages/PkgCompat.jl @@ -215,7 +215,14 @@ end # (⚠️ Internal API with fallback) _stdlibs() = try - values(Pkg.Types.stdlibs()) + stdlibs = values(Pkg.Types.stdlibs()) + stdlibs = if VERSION > v"1.8.0-" + first.(stdlibs) + else + stdlibs + end + @assert eltype(stdlibs) == String + stdlibs catch e @warn "Pkg compat: failed to load standard libraries." exception=(e,catch_backtrace()) From a9150c2e601aec324a3c52da684b778a2246bb7b Mon Sep 17 00:00:00 2001 From: Paul Berg Date: Sun, 30 Jan 2022 22:39:12 +0100 Subject: [PATCH 2/3] Update Test.yml --- .github/workflows/Test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/Test.yml b/.github/workflows/Test.yml index f6b38090b6..847fd32e94 100644 --- a/.github/workflows/Test.yml +++ b/.github/workflows/Test.yml @@ -29,7 +29,7 @@ jobs: strategy: matrix: # We test quite a lot of versions because we do some OS and version specific things unfortunately - julia-version: ["1.5", "1.6", "1.7", "nightly"] + julia-version: ["1.5", "1.6", "1.7"] # , "nightly"] os: [ubuntu-latest, macOS-latest, windows-latest] steps: From 3b8f8f6bf1abba804c591a16fb6421bb60462401 Mon Sep 17 00:00:00 2001 From: Paul Date: Sun, 30 Jan 2022 23:33:43 +0100 Subject: [PATCH 3/3] use feature check --- .github/workflows/Test.yml | 2 +- src/packages/PkgCompat.jl | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/Test.yml b/.github/workflows/Test.yml index 847fd32e94..eaa6a1ff72 100644 --- a/.github/workflows/Test.yml +++ b/.github/workflows/Test.yml @@ -29,7 +29,7 @@ jobs: strategy: matrix: # We test quite a lot of versions because we do some OS and version specific things unfortunately - julia-version: ["1.5", "1.6", "1.7"] # , "nightly"] + julia-version: ["1.5", "1.6", "1.7"] #, "nightly"] os: [ubuntu-latest, macOS-latest, windows-latest] steps: diff --git a/src/packages/PkgCompat.jl b/src/packages/PkgCompat.jl index 4602ac9ccc..ff79a30176 100644 --- a/src/packages/PkgCompat.jl +++ b/src/packages/PkgCompat.jl @@ -216,13 +216,14 @@ end # (⚠️ Internal API with fallback) _stdlibs() = try stdlibs = values(Pkg.Types.stdlibs()) - stdlibs = if VERSION > v"1.8.0-" + T = eltype(stdlibs) + if T == String + stdlibs + elseif T <: Tuple{String,Any} first.(stdlibs) else - stdlibs + error() end - @assert eltype(stdlibs) == String - stdlibs catch e @warn "Pkg compat: failed to load standard libraries." exception=(e,catch_backtrace())