Skip to content

FIX: Handle empty points in geometry projection#2640

Merged
rcomer merged 1 commit intoSciTools:mainfrom
greglucas:fix-project-empty-point
Mar 15, 2026
Merged

FIX: Handle empty points in geometry projection#2640
rcomer merged 1 commit intoSciTools:mainfrom
greglucas:fix-project-empty-point

Conversation

@greglucas
Copy link
Contributor

It looks like we didn't have a check for an empty shapely.Point(), but did have an empty array check on the transform_points() method. The error is in the attribute look-up, which we can avoid by just returning the empty point directly since it can't be transformed anyways.

closes #2635

Copy link
Member

@rcomer rcomer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems right. The doc build failure is troubling but also appearing in other PRs so nothing to do with this change.

@rcomer rcomer merged commit a076abf into SciTools:main Mar 15, 2026
24 of 26 checks passed
@greglucas greglucas deleted the fix-project-empty-point branch March 15, 2026 19:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error drawing 0-area path/contour

2 participants