xarray-plotly 0.0.9__tar.gz → 0.0.11__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. xarray_plotly-0.0.11/.github/workflows/docs.yml +44 -0
  2. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/.github/workflows/release.yml +0 -12
  3. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/PKG-INFO +4 -4
  4. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/pyproject.toml +3 -3
  5. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/tests/test_figures.py +28 -0
  6. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly/figures.py +2 -0
  7. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly.egg-info/PKG-INFO +4 -4
  8. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly.egg-info/requires.txt +3 -3
  9. xarray_plotly-0.0.9/.github/workflows/docs.yml +0 -21
  10. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/.github/dependabot.yml +0 -0
  11. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/.github/workflows/ci.yml +0 -0
  12. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/.github/workflows/dependabot-auto-merge.yml +0 -0
  13. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/.gitignore +0 -0
  14. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/.pre-commit-config.yaml +0 -0
  15. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/CONTRIBUTING.md +0 -0
  16. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/LICENSE +0 -0
  17. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/README.md +0 -0
  18. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/api.md +0 -0
  19. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/combining.ipynb +0 -0
  20. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/datasets.ipynb +0 -0
  21. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/dimensions.ipynb +0 -0
  22. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/fast_bar.ipynb +0 -0
  23. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/figure.ipynb +0 -0
  24. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/kwargs.ipynb +0 -0
  25. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/manipulation.ipynb +0 -0
  26. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/examples/plot-types.ipynb +0 -0
  27. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/getting-started.ipynb +0 -0
  28. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/docs/index.md +0 -0
  29. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/mkdocs.yml +0 -0
  30. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/setup.cfg +0 -0
  31. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/tests/__init__.py +0 -0
  32. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/tests/test_accessor.py +0 -0
  33. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/tests/test_common.py +0 -0
  34. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/tests/test_config.py +0 -0
  35. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly/__init__.py +0 -0
  36. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly/accessor.py +0 -0
  37. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly/common.py +0 -0
  38. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly/config.py +0 -0
  39. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly/plotting.py +0 -0
  40. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly/py.typed +0 -0
  41. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly.egg-info/SOURCES.txt +0 -0
  42. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly.egg-info/dependency_links.txt +0 -0
  43. {xarray_plotly-0.0.9 → xarray_plotly-0.0.11}/xarray_plotly.egg-info/top_level.txt +0 -0
@@ -0,0 +1,44 @@
1
+ name: Docs
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [main]
6
+ workflow_dispatch: # Manual trigger
7
+ workflow_run:
8
+ workflows: ["Release"]
9
+ types: [completed]
10
+
11
+ permissions:
12
+ contents: write
13
+
14
+ jobs:
15
+ docs:
16
+ runs-on: ubuntu-latest
17
+ # Run on PR, manual trigger, or successful Release
18
+ if: |
19
+ github.event_name == 'pull_request' ||
20
+ github.event_name == 'workflow_dispatch' ||
21
+ (github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success')
22
+
23
+ steps:
24
+ - uses: actions/checkout@v6
25
+ with:
26
+ # For workflow_run, checkout the commit that triggered Release
27
+ ref: ${{ github.event.workflow_run.head_sha || github.ref }}
28
+
29
+ - name: Install uv
30
+ uses: astral-sh/setup-uv@v7
31
+
32
+ - name: Install dependencies
33
+ run: uv sync --extra docs
34
+
35
+ - name: Build docs
36
+ run: uv run mkdocs build
37
+
38
+ - name: Deploy to GitHub Pages
39
+ # Deploy on manual trigger or after successful Release
40
+ if: github.event_name != 'pull_request'
41
+ uses: peaceiris/actions-gh-pages@v4
42
+ with:
43
+ github_token: ${{ secrets.GITHUB_TOKEN }}
44
+ publish_dir: ./site
@@ -29,15 +29,3 @@ jobs:
29
29
  with:
30
30
  generate_release_notes: true
31
31
  files: dist/*
32
-
33
- - name: Install docs dependencies
34
- run: uv sync --extra docs
35
-
36
- - name: Build docs
37
- run: uv run mkdocs build
38
-
39
- - name: Deploy to GitHub Pages
40
- uses: peaceiris/actions-gh-pages@v4
41
- with:
42
- github_token: ${{ secrets.GITHUB_TOKEN }}
43
- publish_dir: ./site
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: xarray_plotly
3
- Version: 0.0.9
3
+ Version: 0.0.11
4
4
  Summary: Interactive Plotly Express plotting accessor for xarray
5
5
  Author: Felix
6
6
  License: MIT
@@ -28,13 +28,13 @@ Provides-Extra: dev
28
28
  Requires-Dist: pytest==9.0.2; extra == "dev"
29
29
  Requires-Dist: pytest-cov==7.0.0; extra == "dev"
30
30
  Requires-Dist: mypy==1.19.1; extra == "dev"
31
- Requires-Dist: ruff==0.14.13; extra == "dev"
31
+ Requires-Dist: ruff==0.14.14; extra == "dev"
32
32
  Requires-Dist: pre-commit==4.5.1; extra == "dev"
33
- Requires-Dist: nbstripout==0.8.2; extra == "dev"
33
+ Requires-Dist: nbstripout==0.9.0; extra == "dev"
34
34
  Provides-Extra: docs
35
35
  Requires-Dist: mkdocs==1.6.1; extra == "docs"
36
36
  Requires-Dist: mkdocs-material==9.7.1; extra == "docs"
37
- Requires-Dist: mkdocstrings[python]==1.0.0; extra == "docs"
37
+ Requires-Dist: mkdocstrings[python]==1.0.1; extra == "docs"
38
38
  Requires-Dist: mkdocs-jupyter==0.25.1; extra == "docs"
39
39
  Requires-Dist: mkdocs-plotly-plugin==0.1.3; extra == "docs"
40
40
  Requires-Dist: jupyter==1.1.1; extra == "docs"
@@ -35,14 +35,14 @@ dev = [
35
35
  "pytest==9.0.2",
36
36
  "pytest-cov==7.0.0",
37
37
  "mypy==1.19.1",
38
- "ruff==0.14.13",
38
+ "ruff==0.14.14",
39
39
  "pre-commit==4.5.1",
40
- "nbstripout==0.8.2",
40
+ "nbstripout==0.9.0",
41
41
  ]
42
42
  docs = [
43
43
  "mkdocs==1.6.1",
44
44
  "mkdocs-material==9.7.1",
45
- "mkdocstrings[python]==1.0.0",
45
+ "mkdocstrings[python]==1.0.1",
46
46
  "mkdocs-jupyter==0.25.1",
47
47
  "mkdocs-plotly-plugin==0.1.3",
48
48
  "jupyter==1.1.1",
@@ -232,6 +232,20 @@ class TestOverlayAnimation:
232
232
  combined_names = {frame.name for frame in combined.frames}
233
233
  assert original_names == combined_names
234
234
 
235
+ def test_frame_layout_preserved(self) -> None:
236
+ """Test that frame layout (e.g., axis range) is preserved."""
237
+ fig = xpx(self.da_3d).line(animation_frame="time", range_y=[0, 10])
238
+ overlay_fig = xpx(self.da_3d).scatter(animation_frame="time")
239
+
240
+ # Verify base has frame layout
241
+ assert fig.frames[0].layout is not None
242
+
243
+ combined = overlay(fig, overlay_fig)
244
+
245
+ # Frame layout should be preserved
246
+ for i, frame in enumerate(combined.frames):
247
+ assert frame.layout == fig.frames[i].layout
248
+
235
249
 
236
250
  class TestOverlayFacetsAndAnimation:
237
251
  """Tests for overlay with both facets and animation."""
@@ -560,6 +574,20 @@ class TestAddSecondaryYAnimation:
560
574
  with pytest.raises(ValueError, match="frame names don't match"):
561
575
  add_secondary_y(fig1, fig2)
562
576
 
577
+ def test_frame_layout_preserved(self) -> None:
578
+ """Test that frame layout (e.g., axis range) is preserved."""
579
+ base = xpx(self.da_2d).line(animation_frame="time", range_y=[0, 10])
580
+ secondary = xpx(self.da_2d).bar(animation_frame="time")
581
+
582
+ # Verify base has frame layout
583
+ assert base.frames[0].layout is not None
584
+
585
+ combined = add_secondary_y(base, secondary)
586
+
587
+ # Frame layout should be preserved
588
+ for i, frame in enumerate(combined.frames):
589
+ assert frame.layout == base.frames[i].layout
590
+
563
591
 
564
592
  class TestAddSecondaryYDeepCopy:
565
593
  """Tests to ensure add_secondary_y creates deep copies."""
@@ -142,6 +142,7 @@ def _merge_frames(
142
142
  data=merged_data,
143
143
  name=frame_name,
144
144
  traces=list(range(base_trace_count + sum(overlay_trace_counts))),
145
+ layout=base_frame.layout,
145
146
  )
146
147
  )
147
148
 
@@ -403,6 +404,7 @@ def _merge_secondary_y_frames(
403
404
  data=merged_data,
404
405
  name=frame_name,
405
406
  traces=list(range(base_trace_count + secondary_trace_count)),
407
+ layout=base_frame.layout,
406
408
  )
407
409
  )
408
410
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: xarray_plotly
3
- Version: 0.0.9
3
+ Version: 0.0.11
4
4
  Summary: Interactive Plotly Express plotting accessor for xarray
5
5
  Author: Felix
6
6
  License: MIT
@@ -28,13 +28,13 @@ Provides-Extra: dev
28
28
  Requires-Dist: pytest==9.0.2; extra == "dev"
29
29
  Requires-Dist: pytest-cov==7.0.0; extra == "dev"
30
30
  Requires-Dist: mypy==1.19.1; extra == "dev"
31
- Requires-Dist: ruff==0.14.13; extra == "dev"
31
+ Requires-Dist: ruff==0.14.14; extra == "dev"
32
32
  Requires-Dist: pre-commit==4.5.1; extra == "dev"
33
- Requires-Dist: nbstripout==0.8.2; extra == "dev"
33
+ Requires-Dist: nbstripout==0.9.0; extra == "dev"
34
34
  Provides-Extra: docs
35
35
  Requires-Dist: mkdocs==1.6.1; extra == "docs"
36
36
  Requires-Dist: mkdocs-material==9.7.1; extra == "docs"
37
- Requires-Dist: mkdocstrings[python]==1.0.0; extra == "docs"
37
+ Requires-Dist: mkdocstrings[python]==1.0.1; extra == "docs"
38
38
  Requires-Dist: mkdocs-jupyter==0.25.1; extra == "docs"
39
39
  Requires-Dist: mkdocs-plotly-plugin==0.1.3; extra == "docs"
40
40
  Requires-Dist: jupyter==1.1.1; extra == "docs"
@@ -6,14 +6,14 @@ pandas>=1.5.0
6
6
  pytest==9.0.2
7
7
  pytest-cov==7.0.0
8
8
  mypy==1.19.1
9
- ruff==0.14.13
9
+ ruff==0.14.14
10
10
  pre-commit==4.5.1
11
- nbstripout==0.8.2
11
+ nbstripout==0.9.0
12
12
 
13
13
  [docs]
14
14
  mkdocs==1.6.1
15
15
  mkdocs-material==9.7.1
16
- mkdocstrings[python]==1.0.0
16
+ mkdocstrings[python]==1.0.1
17
17
  mkdocs-jupyter==0.25.1
18
18
  mkdocs-plotly-plugin==0.1.3
19
19
  jupyter==1.1.1
@@ -1,21 +0,0 @@
1
- name: Docs
2
-
3
- on:
4
- pull_request:
5
- branches: [main]
6
-
7
- jobs:
8
- docs:
9
- runs-on: ubuntu-latest
10
-
11
- steps:
12
- - uses: actions/checkout@v6
13
-
14
- - name: Install uv
15
- uses: astral-sh/setup-uv@v7
16
-
17
- - name: Install dependencies
18
- run: uv sync --extra docs
19
-
20
- - name: Build docs
21
- run: uv run mkdocs build
File without changes
File without changes
File without changes
File without changes
File without changes