Skip to content

Commit

Permalink
Use sphinx_gallery_start_ignore and sphinx_gallery_end_ignore flags t…
Browse files Browse the repository at this point in the history
  • Loading branch information
seisman committed Jul 9, 2024
1 parent 8dfd10c commit e15462f
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
7 changes: 6 additions & 1 deletion examples/gallery/lines/roads.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,15 @@
# %%
import geopandas as gpd
import pygmt

# sphinx_gallery_start_ignore
# Workaround for https://github.com/GenericMappingTools/pygmt/issues/3301
import pyogrio

# Read shapefile data using geopandas
pyogrio.core._register_drivers()
# sphinx_gallery_end_ignore

# Read shapefile data using geopandas
gdf = gpd.read_file(
"http://www2.census.gov/geo/tiger/TIGER2015/PRISECROADS/tl_2015_15_prisecroads.zip"
)
Expand Down
5 changes: 5 additions & 0 deletions examples/get_started/04_table_inputs.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,14 @@
import numpy as np
import pandas as pd
import pygmt

# sphinx_gallery_start_ignore
# Workaround for https://github.com/GenericMappingTools/pygmt/issues/3301
import pyogrio

pyogrio.core._register_drivers()
# sphinx_gallery_end_ignore


# %%
# ASCII table file
Expand Down
2 changes: 1 addition & 1 deletion pygmt/tests/test_clib_loading.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ def _mock_ctypes_cdll_return(self, libname):
# libname is a loaded GMT library
return self.loaded_libgmt

@pytest.fixture
@pytest.fixture()
def _mock_ctypes(self, monkeypatch):
"""
Patch the ctypes.CDLL function.
Expand Down

0 comments on commit e15462f

Please sign in to comment.