example: use the tuple with the updated "in_compliance" value returned by _replace() #842
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.
What does this Pull Request accomplish?
nidcpower_source_dc_voltage
measurement to support multisite in example: update nidcpower measurement to support multiple instrument sessions #676, I overlooked the update to thein_compliance
value in the_Measurement
tuple. Since tuples are immutable, invoking_replace()
on a tuple doesn't modify the original tuple; instead, it returns a new tuple with the updated values._replace()
method wasn't captured or assigned to any variable, resulting in the use of the original tuple, which did not have the correct "in_compliance" value. This PR ensures that the tuple returned by the_replace()
method is properly appended to the finalmeasurements
list.Why should this Pull Request be merged?
in_compliance
value was not assigned properly.What testing has been done?