
This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
Created on2018-02-23 00:56 byterry.reedy, last changed2022-04-11 14:58 byadmin. This issue is nowclosed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 5830 | merged | cheryl.sabella,2018-02-23 12:36 | |
| PR 5844 | merged | miss-islington,2018-02-24 02:35 | |
| PR 5845 | merged | miss-islington,2018-02-24 02:36 | |
| Messages (6) | |||
|---|---|---|---|
| msg312606 -(view) | Author: Terry J. Reedy (terry.reedy)*![]() | Date: 2018-02-23 00:56 | |
Change 'str' to 'code' in pyparse and code that uses it. 'str' conflicts with the built-in name and it too general for 'the block of python code being processed'. 'code' is what the string is. The change applies to local 'str', 'self.str' references, and the 'set_str' method. The latter requires renames in other modules. From grep:F:\dev\3x\lib\idlelib\editor.py: 1305: y.set_str(rawtext)F:\dev\3x\lib\idlelib\editor.py: 1319: y.set_str(rawtext)F:\dev\3x\lib\idlelib\hyperparser.py: 47: parser.set_str(text.get(startatindex, stopatindex)+' \n')F:\dev\3x\lib\idlelib\hyperparser.py: 63: parser.set_str(text.get(startatindex, stopatindex)+' \n')editor imports pyparse and calls Parser once in y = pyparse.Parser...and never references y.strhyperparser imports pyparse and calls Parser once in parser = pyparse.Parser...and does reference the modifies parser.str once in line 67 self.rawtext = parser.str[:-2]set_str is not called within pyparse itselfThe existing pyparse tests are sufficient for pyparse since they execute every line containig 'str'. The hyperparser test covers the above lines in Hyperparser.__init__, but test_editor covers almost nothing and would miss the editor lines.The two files access various methods and the editor code, the C_ constants, so I am not inclined to change names that are not so actively obnoxious.Since this will impact other pyparse changes, I think it should be next. Cheryl, respond here if you want to do the PR. | |||
| msg312623 -(view) | Author: Cheryl Sabella (cheryl.sabella)*![]() | Date: 2018-02-23 09:44 | |
Yes, I agree. I'll start working on this one first. | |||
| msg312691 -(view) | Author: Terry J. Reedy (terry.reedy)*![]() | Date: 2018-02-24 02:35 | |
New changesetc29c03a34a9f3c82704b66f323ce5ea9dc89c8af by Terry Jan Reedy (Cheryl Sabella) in branch 'master':bpo-32916: IDLE: Change `str` to `code` in pyparse (GH-5830)https://github.com/python/cpython/commit/c29c03a34a9f3c82704b66f323ce5ea9dc89c8af | |||
| msg312694 -(view) | Author: miss-islington (miss-islington) | Date: 2018-02-24 02:59 | |
New changesetf409c9988e72eff7c0378ab5578f5edecb8b1855 by Miss Islington (bot) in branch '3.7':bpo-32916: IDLE: Change `str` to `code` in pyparse (GH-5830)https://github.com/python/cpython/commit/f409c9988e72eff7c0378ab5578f5edecb8b1855 | |||
| msg312695 -(view) | Author: miss-islington (miss-islington) | Date: 2018-02-24 03:16 | |
New changesetcd2112f0b9ce3d1a8cff61c16a9208115fb1dbf4 by Miss Islington (bot) in branch '3.6':bpo-32916: IDLE: Change `str` to `code` in pyparse (GH-5830)https://github.com/python/cpython/commit/cd2112f0b9ce3d1a8cff61c16a9208115fb1dbf4 | |||
| msg312699 -(view) | Author: Terry J. Reedy (terry.reedy)*![]() | Date: 2018-02-24 05:21 | |
Thanks. It is nice splitting the work this way. | |||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:58:58 | admin | set | github: 77097 |
| 2018-02-24 05:21:23 | terry.reedy | set | status: open -> closed type: enhancement messages: +msg312699 resolution: fixed stage: patch review -> resolved |
| 2018-02-24 03:16:02 | miss-islington | set | messages: +msg312695 |
| 2018-02-24 02:59:56 | miss-islington | set | nosy: +miss-islington messages: +msg312694 |
| 2018-02-24 02:36:48 | miss-islington | set | pull_requests: +pull_request5620 |
| 2018-02-24 02:35:49 | miss-islington | set | pull_requests: +pull_request5619 |
| 2018-02-24 02:35:29 | terry.reedy | set | messages: +msg312691 |
| 2018-02-23 12:36:55 | cheryl.sabella | set | keywords: +patch stage: needs patch -> patch review pull_requests: +pull_request5608 |
| 2018-02-23 09:44:01 | cheryl.sabella | set | messages: +msg312623 |
| 2018-02-23 00:59:58 | terry.reedy | link | issue32880 dependencies |
| 2018-02-23 00:56:01 | terry.reedy | create | |