-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Further standardise nimble parameters #58
Comments
This might be scope creep for this PR, but we need to fix all the errant references to |
This issue is things that I want to do after PR #57 is merged. 57 is already huge, but I wanted a list of things to do afterwards so they were not forgotten. I 100% agree that is it a shelf or a tray is a key question and we need to standardise. Will make new issue rather than scope creep this one |
Concerning the task "Stop using groups of strings for parameters and string comparisons, and start using enums" I'm actually a fan of parameter definitions like My reasons:
If needed the types can also be named e.g. While there are still arguments to use enums in certain conditions, I would not vote for a general rule to ONLY use enums. |
Thanks @drayde, I suppose I am somewhat biased by a combination of my terrible spelling and the tools that I use that don't autocomplete this well. I have done a bit more learning and I can see there is more to this that meets the eye. In terms of linting, typed inputs. This is something I don't get from PyLint. I assume we need a type checker like MyPy? I think that the thing I like least about them is not when you are making a call to a function with a Literal input, but when you are writing the function itself. For the function itself there is no type checking when you actually do the string comparison to use the parameters. A spelling error here would be a really hard bug to detect or lint. Which I suppose is an argument for unit tests. I can see this comes down to personal preference. |
You are right @julianstirling , flake8 or pylint won't catch a spelling mistake. So I guess you are right, we should not use it unless we integrate mypy or do unit test that would catch it |
The parameters in
nimble_builder
are either hard coded or repeatedly specified in different files. Now we have a RackParameters class we should be using this to define hole sizes.We need to
The text was updated successfully, but these errors were encountered: