Commit ed48d5a
committed
Add more explicit error message for [r,theta]grids
mypy was unhappy because the first parameter in each case (angles/radii) is optional for the pyplot wrapper but required for the set_[r,theta]grids axes methods. The variable is optional because the pyplot version acts as both the getter and the setter, but the type is not sufficiently narrowed for mypy. If passed None, the underlying setters would error, though deeper in the stack either in numpy or upon setting ticks. Just be a bit more explicit and fail early with a targetted error message1 parent 6d101fd commit ed48d5a
1 file changed
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2142 | 2142 | | |
2143 | 2143 | | |
2144 | 2144 | | |
| 2145 | + | |
| 2146 | + | |
2145 | 2147 | | |
2146 | 2148 | | |
2147 | 2149 | | |
| |||
2215 | 2217 | | |
2216 | 2218 | | |
2217 | 2219 | | |
| 2220 | + | |
| 2221 | + | |
2218 | 2222 | | |
2219 | 2223 | | |
2220 | 2224 | | |
| |||
0 commit comments