Skip to content

Commit

Permalink
Attempt to fix issue with doc building on Mac/Windows (#436)
Browse files Browse the repository at this point in the history
  • Loading branch information
adehecq authored Jan 19, 2024
1 parent 5d5e269 commit f57df0d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion dev-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ dependencies:

# Doc dependencies
- sphinx
- pydata-sphinx-theme==0.13.3
- pydata-sphinx-theme
- sphinx-book-theme>=1.0
- sphinx-gallery
- sphinx-design
Expand Down
2 changes: 1 addition & 1 deletion examples/analysis/point_extraction/reduction.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
coords = rast.coords(grid=True)
x_closest = rast.copy(new_array=coords[0]).value_at_coords(x=x_coords, y=y_coords).squeeze()
y_closest = rast.copy(new_array=coords[1]).value_at_coords(x=x_coords, y=y_coords).squeeze()
from shapely import box
from shapely.geometry import box

geometry = [
box(x - 2 * rast.res[0], y - 2 * rast.res[1], x + 2 * rast.res[0], y + 2 * rast.res[1])
Expand Down
6 changes: 3 additions & 3 deletions tests/test_doc.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ class TestDocs:

def test_build(self) -> None:
"""Try building the documentation and see if it works."""
# Remove the build directory if it exists.

# Test only on Linux
if platform.system() == "Linux":
# Building the doc fails on Windows for the CLI section
if (platform.system() == "Linux") or (platform.system() == "Darwin"):

# Remove the build directory if it exists.
if os.path.isdir(os.path.join(self.docs_dir, "build/")):
shutil.rmtree(os.path.join(self.docs_dir, "build/"))
Expand Down

0 comments on commit f57df0d

Please sign in to comment.