Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Repeated Capabilites documentation improvements #1686
base: master
Are you sure you want to change the base?
Repeated Capabilites documentation improvements #1686
Changes from 4 commits
e9b6f72
7b3a1a5
8bc69bc
93d62f1
e4ba124
4fda89a
948db7a
f2dc5ea
f04652c
d48cfc9
1cc9cf4
ce93c56
8e8833c
cf13613
76fede8
fb8c3a0
ad59a96
30efefd
e461d65
19b2208
d2c61ae
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this will work since this is not the correct syntax for Python
range
. But['0:2']
will work because of the custom logic we have for handling range-based strings.Having said that, I don't think any of the ways I've enumerated above can be recommended over others.
int
is obviously the go-to for single instances. Basic sequence types andslice
are good to use because they're part of the language, Range-based strings provides syntactic sugar for defining ranges. e.g.['0:2']
rather than[range(0,2)]
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see @marcoskirsch doesn't like us to recommend the range-based strings. Since I saw we had logic specifically for handling it, I thought it was important. But it sounds like it was ill-conceived. I don't mind not documenting it.
Once we land on recommended ways, we should go over the examples to ensure only recommended types are used.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I add anything to the recommend types above, I should add an example usage, here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here is where we could add an example using an iterable, below line 42?
session.channles[range(3)].output_function = nidcpower.OutputFunction.DC_CURRENT