Skip to content

Commit 8583135

Browse files
committed
update
1 parent e15e704 commit 8583135

File tree

13 files changed

+57
-31
lines changed

13 files changed

+57
-31
lines changed

.github/workflows/ci.yml

Lines changed: 35 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,20 @@ jobs:
1717
ci:
1818
if: "!contains(github.event.head_commit.message, '[skip ci]')"
1919
env:
20-
GKS_ENCODING: "utf8"
21-
GKSwstype: "nul"
22-
JULIA_CONDAPKG_BACKEND: "MicroMamba"
23-
PLOTS_PLOTLYJS_UNSAFE_ELECTRON: "true"
24-
MPLBACKEND: "agg"
20+
JULIA_PROJECT_CMD: julia --project=@. --check-bounds=yes --color=yes
21+
GKS_ENCODING: utf8
22+
GKS_WSTYPE: nul
23+
JULIA_CONDAPKG_BACKEND: MicroMamba
24+
PLOTS_PLOTLYJS_UNSAFE_ELECTRON: true
25+
MPLBACKEND: agg
2526
name: Julia ${{ matrix.version }} - ${{ matrix.os }}
2627
continue-on-error: ${{ matrix.experimental }}
2728
runs-on: ${{ matrix.os }}
2829
strategy:
2930
fail-fast: false
3031
matrix:
3132
version:
32-
- 'lts' # LTS, also minimum declared julia compat in `Project.toml`
33+
- 'lts' # LTS, also minimum declared julia compat in `Project.toml`
3334
- '1' # latest stable
3435
experimental:
3536
- false
@@ -42,10 +43,8 @@ jobs:
4243
version: '1'
4344
- os: ubuntu-latest
4445
experimental: false
45-
prefix: xvfb-run # add `xvfb-run` prefix julia-actions/julia-runtest/blob/master/README.md
4646
- os: ubuntu-latest
4747
experimental: true
48-
prefix: xvfb-run
4948
version: 'pre' # upcoming julia version, next `rc`
5049

5150
steps:
@@ -68,14 +67,6 @@ jobs:
6867
- uses: julia-actions/cache@v2
6968
- uses: julia-actions/julia-buildpkg@latest
7069

71-
- name: Run upstream RecipesBase & RecipesPipeline tests
72-
shell: julia --project=@. --color=yes {0}
73-
run: |
74-
using Pkg
75-
foreach(("RecipesBase", "RecipesPipeline")) do name
76-
Pkg.develop(path=name); Pkg.test(name; coverage=true)
77-
end
78-
7970
- name: Install conda based matplotlib
8071
shell: julia --project=@. --color=yes {0}
8172
run: |
@@ -100,10 +91,33 @@ jobs:
10091
CondaPkg.PkgREPL.add([libgcc..., "matplotlib"])
10192
CondaPkg.status()
10293
103-
- uses: julia-actions/julia-runtest@latest
104-
timeout-minutes: 60
105-
with:
106-
prefix: ${{ matrix.prefix }} # for `xvfb-run`
94+
- name: develop packages
95+
run: |
96+
${{ env.JULIA_PROJECT_CMD }} -e '
97+
using Pkg
98+
Pkg.develop([
99+
(; path="./RecipesBase"), # compat for LTS [sources], remove later
100+
(; path="./RecipesPipeline"), # compat for LTS [sources], remove later
101+
(; path="./Plots"), # compat for LTS [sources], remove later
102+
])
103+
Pkg.precompile() # // precompilation
104+
'
105+
106+
- name: test Plots stack
107+
timeout-minutes: 90
108+
run: |
109+
cmd=(${{ env.JULIA_PROJECT_CMD }} --depwarn=yes)
110+
if [ "$RUNNER_OS" == "Linux" ]; then
111+
cmd=(xvfb-run ${cmd[@]})
112+
fi
113+
echo ${cmd[@]}
114+
${cmd[@]} -e '
115+
using Pkg; Pkg.test([
116+
"RecipesBase",
117+
"RecipesPipeline",
118+
"Plots",
119+
]; coverage=true)
120+
'
107121
108122
- name: Run downstream tests
109123
if: startsWith(matrix.os, 'ubuntu')
@@ -119,7 +133,7 @@ jobs:
119133
- uses: julia-actions/julia-processcoverage@latest
120134
if: startsWith(matrix.os, 'ubuntu')
121135
with:
122-
directories: RecipesBase/src,RecipesPipeline/src,src
136+
directories: RecipesBase/src,RecipesPipeline/src,Plots/src
123137
- uses: codecov/codecov-action@v4
124138
if: startsWith(matrix.os, 'ubuntu')
125139
with:

.github/workflows/compathelper.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,7 @@ jobs:
1414
env:
1515
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1616
COMPATHELPER_PRIV: ${{ secrets.COMPATHELPER_PRIV }} # optional
17-
run: julia -e 'using CompatHelper; CompatHelper.main()'
17+
run: |
18+
julia -e 'using CompatHelper; CompatHelper.main(
19+
subdirs=["RecipesBase", "RecipesPipeline", "Plots"]
20+
)'

.github/workflows/tagbot.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,4 @@ jobs:
3030
token: ${{ secrets.GITHUB_TOKEN }}
3131
ssh: ${{ secrets.TAGBOT_KEY }}
3232
branch: master
33+
subdir: Plots

Plots/Project.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,10 +60,14 @@ UnitfulExt = "Unitful"
6060

6161
[compat]
6262
Contour = "0.5 - 0.6"
63+
Dates = "1"
6364
Downloads = "1"
6465
FFMPEG = "0.4.1"
66+
FileIO = "1"
6567
FixedPointNumbers = "0.6 - 0.8"
68+
GeometryBasics = "0.5"
6669
GR = "0.73"
70+
ImageInTerminal = "0.5"
6771
JLFzf = "0.1"
6872
JSON = "0.21, 1"
6973
LaTeXStrings = "1"
File renamed without changes.
File renamed without changes.

Plots/src/backends.jl

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,19 @@ struct NoBackend <: AbstractBackend end
22

33
lazyloadPkg() = Base.require(@__MODULE__, :Pkg)
44

5-
const _current_plots_version = VersionNumber(TOML.parsefile(normpath(@__DIR__, "..", "Project.toml"))["version"])
6-
const _plots_compats = TOML.parsefile(normpath(@__DIR__, "..", "Project.toml"))["compat"]
5+
const _toml_proj = TOML.parsefile(normpath(@__DIR__, "..", "Project.toml"))
6+
const _toml_test = TOML.parsefile(normpath(@__DIR__, "..", "test", "Project.toml"))
7+
8+
const _current_plots_version = VersionNumber(_toml_proj["version"])
9+
const _plots_compats = merge(_toml_proj["compat"], _toml_test["compat"])
10+
const _plots_deps = merge(_toml_proj["deps"], _toml_test["deps"])
711

812
const _backendSymbol = Dict{DataType, Symbol}(NoBackend => :none)
913
const _backendType = Dict{Symbol, DataType}(:none => NoBackend)
1014
const _backend_packages = Dict{Symbol, Symbol}()
1115
const _initialized_backends = Set{Symbol}()
1216
const _backends = Symbol[]
1317

14-
const _plots_deps = let toml_proj = TOML.parsefile(normpath(@__DIR__, "..", "Project.toml")),
15-
toml_test = TOML.parsefile(normpath(@__DIR__, "..", "test", "Project.toml"))
16-
merge(toml_proj["deps"], toml_test["deps"])
17-
end
18-
1918
function _check_installed(backend::Union{Module, AbstractString, Symbol}; warn = true)
2019
sym = Symbol(lowercase(string(backend)))
2120
if warn && !haskey(_backend_packages, sym)

0 commit comments

Comments
 (0)