Skip to content
This repository has been archived by the owner on Jan 25, 2024. It is now read-only.

Consider harsher runtime type restrictions on component input #545

Open
tpoomlmly opened this issue Feb 13, 2020 · 1 comment
Open

Consider harsher runtime type restrictions on component input #545

tpoomlmly opened this issue Feb 13, 2020 · 1 comment
Labels
bug Something isn't working semver-patch This change requires an increment in the patch version number
Milestone

Comments

@tpoomlmly
Copy link
Member

In the setter for power in components/motor.py, booleans pass the new_power < -1 or new_power > 1 check and as such don't throw a ValueError. This might exist in other places.

@tpoomlmly tpoomlmly added the bug Something isn't working label Feb 13, 2020
@tpoomlmly tpoomlmly added this to the Pre-1.0.0 milestone Feb 13, 2020
@trickeydan trickeydan modified the milestones: Pre-1.0.0, 0.9.2 Mar 2, 2020
@trickeydan trickeydan added the semver-patch This change requires an increment in the patch version number label May 29, 2020
@trickeydan trickeydan removed this from the 0.9.2 milestone Jul 2, 2020
@trickeydan
Copy link
Contributor

Removed from 0.9.2 milestone, this is a tiny tiny bug. Students should read the documentation and expect errors in an duck typed language.

I think this issue should probably be developed into harsher runtime type restrictions on component input in general, as this issue is likely to be present in various bits of our codebase.

@trickeydan trickeydan added this to the Pre-1.0.0 milestone Jul 2, 2020
@trickeydan trickeydan changed the title Bad motor power validation Consider harsher runtime type restrictions on component input Jul 2, 2020
@trickeydan trickeydan modified the milestones: Pre-1.0.0, Post 1.0.0 Jul 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working semver-patch This change requires an increment in the patch version number
Projects
None yet
Development

No branches or pull requests

2 participants