Skip to content

Sources #5090

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 15 commits into from
May 11, 2025
Merged

Sources #5090

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 16 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
- os: ubuntu-latest
experimental: true
version: 'pre' # upcoming julia version (`alpha`, `beta` or `rc`)
- os: macOS-latest
- os: macos-latest
arch: aarch64
version: '1'
experimental: false
Expand All @@ -64,36 +64,36 @@ jobs:

- uses: julia-actions/cache@v2

- name: Develop all Plots packages
- name: Install conda based matplotlib
env:
JULIA_PKG_PRECOMPILE_AUTO: 0
run: julia --color=yes ci/matplotlib.jl

- name: Develop downstream packages
env:
JULIA_PKG_PRECOMPILE_AUTO: 0
shell: julia --color=yes {0}
shell: julia --project=@. --color=yes {0}
run: |
using Pkg
Pkg.develop([
(; path="./RecipesBase"),
(; path="./RecipesPipeline"),
(; path="./PlotThemes"),
(; path="./PlotsBase"),
(; path="./RecipesBase"), # compat for LTS [sources], remove later
(; path="./RecipesPipeline"), # compat for LTS [sources], remove later
(; path="./PlotThemes"), # compat for LTS [sources], remove later
(; path="./PlotsBase"), # compat for LTS [sources], remove later
(; path="./GraphRecipes"),
(; path="./StatsPlots"),
(; path="."),
])

- name: Install conda based matplotlib
env:
JULIA_PKG_PRECOMPILE_AUTO: 0
run: julia --color=yes ci/matplotlib.jl

- name: Test all Plots packages
- name: Test Plots stack
timeout-minutes: 60
run: |
cmd=(julia --color=yes)
cmd=(julia --project=@. --color=yes --depwarn=yes)
if [ "$RUNNER_OS" == "Linux" ]; then
cmd=(xvfb-run ${cmd[@]})
fi
echo ${cmd[@]}
${cmd[@]} -e 'using Pkg; Pkg.test([
${cmd[@]} -e 'using Pkg
Pkg.test([
"RecipesBase",
"RecipesPipeline",
"PlotThemes",
Expand All @@ -103,11 +103,9 @@ jobs:
"Plots",
]; coverage=true)'
- uses: julia-actions/julia-processcoverage@latest
if: startsWith(matrix.os, 'ubuntu')
with:
directories: RecipesBase/src,RecipesPipeline/src,PlotsBase/src,src,GraphRecipes/src,StatsPlots/src,PlotThemes/src
- uses: codecov/codecov-action@v5
if: startsWith(matrix.os, 'ubuntu')
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: false
Expand Down
21 changes: 5 additions & 16 deletions .github/workflows/reference_images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,39 +5,28 @@ on:

jobs:
build:
runs-on: ubuntu-22.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
repository: JuliaPlots/PlotDocs.jl
token: ${{ secrets.PLOTS_REFIMAGES_TOKEN }}
- uses: julia-actions/setup-julia@latest
with:
version: "1"
- name: Cache artifacts
uses: actions/cache@v4
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{runner.os}}-test-${{env.cache-name}}-${{hashFiles('**/Project.toml')}}
restore-keys: |
${{runner.os}}-test-${{env.cache-name}}-
${{runner.os}}-test-
${{runner.os}}-
version: 1
- uses: julia-actions/cache@v2
- name: Run Plots tests
env:
PLOTSBASE_TEST_PACKAGES: GR
VISUAL_REGRESSION_TESTS_AUTO: true
shell: julia --color=yes {0}
run: |
using Pkg
gh_ref = ${{ github.ref_name }}
gh_ref = "${{ github.ref_name }}"
@info "Adding Plots#$gh_ref"
Pkg.add(PackageSpec(name="Plots", rev="$gh_ref"))
Pkg.test("Plots")
- name: Create pull request
uses: peter-evans/create-pull-request@v7
uses: peter-evans/create-pull-request@latest
with:
title: "Update Plot reference images from branch ${{ github.ref_name}} by the action ${{ github.workflow_ref }}"
body: "Review changes thoroughly and only merge when no unwanted chages are present."
Expand Down
10 changes: 6 additions & 4 deletions PlotsBase/src/examples.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1155,22 +1155,22 @@ const _examples = PlotExample[

plot(
x,
sin.(x),
sin.(x);
xaxis = "common X label",
yaxis = "Y label 1",
color = :red,
title = "twinx";
title = "twinx",
kw...,
)
pl = plot!(twinx(), x, 2cos.(x), yaxis = "Y label 2"; kw...)

plot(
x,
cos.(x),
cos.(x);
xaxis = "X label 1",
yaxis = "common Y label",
color = :red,
title = "twiny";
title = "twiny",
kw...,
)
pr = plot!(twiny(), 2x, cos.(2x), xaxis = "X label 2"; kw...)
Expand Down Expand Up @@ -1199,6 +1199,7 @@ const _examples = PlotExample[
marker = :circle,
ticks = :none,
leg_title = leg,
label = :auto,
leg,
kw...,
),
Expand Down Expand Up @@ -1231,6 +1232,7 @@ const _examples = PlotExample[
marker = :circle,
ticks = :none,
leg_title = leg,
label = :auto,
leg = leg isa Symbol ? Symbol(:outer, leg) : :none,
kw...,
),
Expand Down
8 changes: 8 additions & 0 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,21 @@ version = "2.0.0"
[deps]
GR = "28b8d3ca-fb5f-59d9-8090-bfdbd6d07a71"
PlotsBase = "c52230a3-c5da-43a3-9e85-260fcdfdc737"
PlotThemes = "ccf2f8ad-2431-5c83-bf29-c5338b663b6a"
RecipesBase = "3cdcf5f2-1ef4-517c-9805-6587b60abb01"
RecipesPipeline = "01d81517-befc-4cb6-b9ec-a95719d0359c"
Reexport = "189a3867-3050-52da-a836-e630ba90ab69"

[sources]
PlotsBase = {path = "PlotsBase"}
PlotThemes = {path = "PlotThemes"}
RecipesBase = {path = "RecipesBase"}
RecipesPipeline = {path = "RecipesPipeline"}

[compat]
GR = "0.73"
PlotsBase = "0.1"
PlotThemes = "3"
RecipesBase = "1"
RecipesPipeline = "1"
Reexport = "1"
Expand Down
6 changes: 1 addition & 5 deletions docs/make.jl
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
using Pkg
Base.get_bool_env("PLOTS_DOCS_DEV", false) && Pkg.develop([
(; path="../RecipesBase"),
(; path="../RecipesPipeline"),
(; path="../PlotThemes"),
(; path="../PlotsBase"),
(; path=".."),
(; path="../GraphRecipes"),
(; path="../StatsPlots"),
(; path=".."),
])
# oneliner debug PLOTS_DOCS_DEV=1 PLOTDOCS_PACKAGES='GR' PLOTDOCS_EXAMPLES=1 julia --project -e 'include("make.jl")'

Expand Down
Loading