Skip to content

[GH-3495] Fix the GeoPandas API buffer docs, read_file warning and from_wkt/from_wkb arguments - #3496

Merged
jiayuasu merged 1 commit into
apache:masterfrom
jiayuasu:fix/geopandas-api-small-fixes
Oct 20, 2026
Merged

jiayuasu merged 1 commit into
apache:masterfrom
jiayuasu:fix/geopandas-api-small-fixes

Conversation

@jiayuasu

Copy link
Copy Markdown
Member

Did you read the Contributor Guide?

Is this PR related to a ticket?

What changes were proposed in this PR?

  • buffer: the single_sided docstring now says what the code does, as in GeoPandas: the sign of distance picks the side. A new test compares a negative-distance single-sided buffer with GeoPandas.
  • read_file no longer reports table_name as an unsupported argument, and still warns about the others. read_parquet no longer passes its keyword arguments on to read_file, so it warns about them once.
  • GeoSeries.from_wkt and GeoSeries.from_wkb raise TypeError for keyword arguments other than name, like GeoSeries.from_xy, and their docstrings say so. This is a behavior change: a call that passed another keyword argument, which was ignored, now raises.

How was this patch tested?

  • New tests:
    • test_buffer in test_match_geopandas_series.py gets the negative-distance case;
    • test_read_file_warns_only_about_unsupported_arguments in test_io.py;
    • test_wkt_wkb_keyword_arguments in test_geoseries.py.
  • Checked locally that both constructors raise TypeError naming the unsupported arguments, and still raise NotImplementedError for on_invalid other than 'raise'. The tests that need a Spark session with Sedona run in CI.
  • pre-commit run on the changed files passes.

Did this PR include necessary documentation updates?

  • Yes, the docstrings of buffer, read_file, from_wkt and from_wkb.

@jiayuasu jiayuasu added this to the sedona-2.0.0 milestone Oct 20, 2026
@jiayuasu
jiayuasu merged commit af2ef37 into apache:master Oct 20, 2026
32 checks passed
@jiayuasu
jiayuasu deleted the fix/geopandas-api-small-fixes branch October 20, 2026 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GeoPandas API: misleading buffer single_sided docs, read_file warns about table_name, from_wkt/from_wkb ignore keyword arguments

1 participant