Skip to content

Python 3: more native imports and modules#9751

Merged
michaelDCurran merged 4 commits intonvaccess:threshold_py3_stagingfrom
josephsl:py3moreNativeImports
Jun 16, 2019
Merged

Python 3: more native imports and modules#9751
michaelDCurran merged 4 commits intonvaccess:threshold_py3_stagingfrom
josephsl:py3moreNativeImports

Conversation

@josephsl
Copy link
Copy Markdown
Contributor

Link to issue number:

None

Summary of the issue:

There are more modules that could see Python 3 native import.

Description of how this pull request fixes the issue:

Deferred from @michaelDCurran's native imports work:

  1. cPickle -> pickle
  2. Python console: builtin -> builtins, resolving things such as obtaining debug flag via Python Console.

Steps:

  1. Grep -r "__builtin" source and grep -r "cPickle", as well as others.
  2. Edit the source code as appropriate.

Testing performed:

Tested with both Python 2 and 3 versions of NVDA, along with Python interpreters.

Known issues with pull request:

None

Change log entry:

None

Additional context:

There might be more modules that are not seeing Python 3 native imports. Also, there might be modules that are imported but are not used at all e.g. io.StringIO is imported from config main module but isn't used.

@josephsl josephsl requested a review from michaelDCurran June 16, 2019 02:30
@michaelDCurran michaelDCurran merged commit 7ccbe6f into nvaccess:threshold_py3_staging Jun 16, 2019
@nvaccessAuto nvaccessAuto added this to the 2019.3 milestone Jun 16, 2019
@josephsl josephsl deleted the py3moreNativeImports branch July 19, 2020 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants