Skip to content

Conversation

@dlech
Copy link
Member

@dlech dlech commented Aug 9, 2025

Add type checking to fix a crash if the arguments to cross() are not Matrix objects.

@dlech dlech requested a review from laurensvalk August 9, 2025 17:25
@coveralls
Copy link

coveralls commented Aug 9, 2025

Coverage Status

coverage: 59.931% (-0.01%) from 59.942%
when pulling 3fba188 on dlech:fix-cross-crash
into 8b576b3 on pybricks:master.

@laurensvalk
Copy link
Member

Thanks for catching this.

If we're going to add a verbose error, we should probably say that arguments should be three dimensional vectors (3x1 or 1x3 Matrix), combining it with the existing check below.

Add type checking to fix a crash if the arguments to `cross()` are not
`Matrix` objects.
@laurensvalk laurensvalk merged commit 3fba188 into pybricks:master Sep 30, 2025
17 checks passed
@laurensvalk
Copy link
Member

Thanks!

@dlech dlech deleted the fix-cross-crash branch September 30, 2025 14:16
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.

3 participants