{{ message }}
[3.8] bpo-41306: Allow scale value to not be rounded (GH-21715)#22596
Merged
miss-islington merged 1 commit intoOct 8, 2020
Merged
[3.8] bpo-41306: Allow scale value to not be rounded (GH-21715)#22596miss-islington merged 1 commit into
miss-islington merged 1 commit into
Conversation
This fixes the test failure with Tk 6.8.10 which is caused by changes to how Tk rounds the `from`, `to` and `tickinterval` arguments. This PR uses `noconv` if the patchlevel is greater than or equal to 8.6.10 (credit to Serhiy for this idea as it is much simpler than what I previously proposed). Going into more detail for those who want it, the Tk change was made in [commit 591f68c](tcltk/tk@591f68c) and means that the arguments listed above are rounded relative to the value of `from`. However, when rounding the `from` argument ([line 623](https://github.com/tcltk/tk/blob/591f68cb382525b72664c6fecaab87742b6cc87a/generic/tkScale.cGH-L623)), it is rounded relative to itself (i.e. rounding `0`) and therefore the assigned value for `from` is always what is given (no matter what values of `from` and `resolution`). Automerge-Triggered-By: @pablogsal (cherry picked from commit aecf036) Co-authored-by: E-Paine <63801254+E-Paine@users.noreply.github.com>
Contributor
Author
|
@E-Paine: Status check is done, and it's a success ✅ . |
Sorry, something went wrong.
Contributor
Author
|
@E-Paine: Status check is done, and it's a success ✅ . |
Sorry, something went wrong.
2 similar comments
Contributor
Author
|
@E-Paine: Status check is done, and it's a success ✅ . |
Sorry, something went wrong.
Contributor
Author
|
@E-Paine: Status check is done, and it's a success ✅ . |
Sorry, something went wrong.
E-Paine
approved these changes
Oct 8, 2020
E-Paine
left a comment
Contributor
There was a problem hiding this comment.
Not sure if this is required but it doesn't seem to be merging by itself
Sorry, something went wrong.
pablogsal
approved these changes
Oct 8, 2020
Contributor
Author
|
@E-Paine: Status check is done, and it's a success ✅ . |
Sorry, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.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.
This fixes the test failure with Tk 6.8.10 which is caused by changes to how Tk rounds the
from,toandtickintervalarguments. This PR usesnoconvif the patchlevel is greater than or equal to 8.6.10 (credit to Serhiy for this idea as it is much simpler than what I previously proposed).Going into more detail for those who want it, the Tk change was made in commit 591f68c and means that the arguments listed above are rounded relative to the value of
from. However, when rounding thefromargument (line 623), it is rounded relative to itself (i.e. rounding0) and therefore the assigned value forfromis always what is given (no matter what values offromandresolution).Automerge-Triggered-By: @pablogsal
(cherry picked from commit aecf036)
Co-authored-by: E-Paine 63801254+E-Paine@users.noreply.github.com
https://bugs.python.org/issue41306