This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: [easy] undefined names in
Type: Stage: resolved
Components: Library (Lib), Windows Versions: Python 3.9, Python 3.8, Python 3.7
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Dennis Sweeney, corona10, miss-islington, paul.moore, steve.dower, tim.golden, vstinner, zach.ware
Priority: normal Keywords: newcomer friendly, patch

Created on 2020-04-30 23:45 by vstinner, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 19855 merged Dennis Sweeney, 2020-05-02 04:27
PR 19912 merged miss-islington, 2020-05-05 02:33
PR 19913 merged miss-islington, 2020-05-05 02:33
Messages (4)
msg367808 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2020-04-30 23:45
pyflakes found the two following issues in

Lib/ undefined name 'HKEY_LOCAL_MACHINE'
Lib/ undefined name 'QueryValueEx'

Line 353:

            with winreg.OpenKeyEx(winreg.HKEY_LOCAL_MACHINE, cvkey) as key:
                return winreg.QueryValueEx(key, 'EditionId')[0]

vs Line 401:

            with winreg.OpenKeyEx(HKEY_LOCAL_MACHINE, cvkey) as key:
                ptype = QueryValueEx(key, 'CurrentType')[0]

This issue seems easy to fix ;-)
msg368099 - (view) Author: Dong-hee Na (corona10) * (Python committer) Date: 2020-05-05 02:33
New changeset 1e7e4519a8ddc2239101a0146d788c9161143a77 by Dennis Sweeney in branch 'master':
bpo-40459: Fix NameError in (GH-19855)
msg368100 - (view) Author: miss-islington (miss-islington) Date: 2020-05-05 02:51
New changeset 8ddf91543890e38c76aa0029482c6f5f5c444837 by Miss Islington (bot) in branch '3.7':
bpo-40459: Fix NameError in (GH-19855)
msg368101 - (view) Author: miss-islington (miss-islington) Date: 2020-05-05 02:51
New changeset efc782d29e229924076ffb6645a72f26242fb3ef by Miss Islington (bot) in branch '3.8':
bpo-40459: Fix NameError in (GH-19855)
Date User Action Args
2022-04-11 14:59:30adminsetgithub: 84639
2020-05-05 02:57:49vstinnersetstatus: open -> closed
stage: patch review -> resolved
resolution: fixed
versions: + Python 3.7, Python 3.8
2020-05-05 02:51:52miss-islingtonsetmessages: + msg368101
2020-05-05 02:51:40miss-islingtonsetmessages: + msg368100
2020-05-05 02:33:47miss-islingtonsetpull_requests: + pull_request19228
2020-05-05 02:33:37miss-islingtonsetnosy: + miss-islington
pull_requests: + pull_request19227
2020-05-05 02:33:23corona10setnosy: + corona10
messages: + msg368099
2020-05-02 04:32:09xtreaksetnosy: + paul.moore, tim.golden, zach.ware, steve.dower
components: + Windows
2020-05-02 04:27:22Dennis Sweeneysetkeywords: + patch
nosy: + Dennis Sweeney

pull_requests: + pull_request19171
stage: patch review
2020-04-30 23:45:08vstinnercreate