Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecations for 2021.1 #12123

Closed
18 tasks done
seanbudd opened this issue Mar 5, 2021 · 11 comments
Closed
18 tasks done

Deprecations for 2021.1 #12123

seanbudd opened this issue Mar 5, 2021 · 11 comments
Assignees
Labels
deprecated/2021.1 Label used to track deprecations due for removal in the 2021.1 release
Milestone

Comments

@seanbudd
Copy link
Member

seanbudd commented Mar 5, 2021

A ticket to manage and track the code removal for upcoming deprecations in the 2021.1 release

- 'NVDAObject' (and derivatives) property 'isCurrent' now strictly returns 'controlTypes.IsCurrent'. It is no longer Optional, and thus will not return None. When an object is not current 'controlTypes.IsCurrent.NO' is returned. (#11782)
- The 'controlTypes.isCurrentLabels' has been removed, instead use the 'displayString' property on a 'controlTypes.IsCurrent' enum value. EG 'controlTypes.IsCurrent.YES.displayString' (#11782)
- `LiveText._getTextLines` has been removed. Instead, override `_getText` which returns a string of all text in the object. (#11639)
- `LiveText` objects can now calculate diffs by character. To forcibly modify this for a particular object, override the `diffAlgo` property (see the docstring for details). (#11639)
- Module level  `REASON_*` constants are removed from `controlTypes` - please use `controlTypes.OutputReason` instead. (#11969)
- `REASON_QUICKNAV` has been removed from `browseMode` - use `controlTypes.OutputReason.QUICKNAV` instead. (#11969)
- The following functions are removed from the config module (#11935): 
   - `canStartOnSecureScreens` - use `config.isInstalledCopy` instead.
   - `hasUiAccess` and `execElevated` - use them from the `systemUtils` module.
   - `getConfigDirs` - use `globalVars.appArgs.configPath` instead
 - `winKernel.GetTimeFormat` has been removed - use `winKernel.GetTimeFormatEx` instead (#12139)
 - `winKernel.GetDateFormat` has been removed - use `winKernel.GetDateFormatEx` instead (#12139)
- `gui.DriverSettingsMixin` has been removed - use `gui.AutoSettingsMixin` (#12144)
- `speech.getSpeechForSpelling` has been removed - use `speech.getSpellingSpeech` (#12145)
- Commands cannot be directly imported from speech as `import speech; speech.ExampleCommand()` or `import speech.manager; speech.manager.ExampleCommand()` - use  `from speech.commands import ExampleCommand` instead (#12126)
- `speakTextInfo` will no longer send speech through `speakWithoutPauses` if reason is `SAYALL`, as `sayAllhandler` does this manually now. (#12150)
- Support of `TextInfo`s that do not inherit from `contentRecog.BaseContentRecogTextInfo` is removed (#12157)
- `ROLE_EQUATION` has been removed from controlTypes - use `ROLE_MATH` instead (#12164)
- `driverSetting` classes are removed from `driverHandler` - please use them from `autoSettingUtils` (#12168)
- the `synthDriverHandler` module is no longer star imported into `globalCommands` and `gui.settingsDialogs`  - use `from synthDriverHandler import synthFunctionExample` instead. (#12172)
- `speech.speakWithoutPauses` has been removed - please use `speech.SpeechWithoutPauses(speakFunc=speech.speak).speakWithoutPauses` instead. (#12195)
- `speech.re_last_pause` has been removed - please use `speech.SpeechWithoutPauses.re_last_pause` instead. (#12195)
- `WelcomeDialog`, `LauncherDialog` and `AskAllowUsageStatsDialog` are moved to the `gui.startupDialogs` (#12105)
- `getDocFilePath` has been moved from `gui` to the `documentationUtils` module. (#12105)
- IAccessibleHandler no longer star imports everything from IAccessible and IA2 COM interfaces - please use them directly.
- `wx.CENTRE_ON_SCREEN` and `wx.CENTER_ON_SCREEN` is deprecated, use `self.CentreOnScreen()` instead. 
@seanbudd seanbudd added the deprecated/2021.1 Label used to track deprecations due for removal in the 2021.1 release label Mar 5, 2021
@seanbudd seanbudd added this to the 2021.1 milestone Mar 5, 2021
@seanbudd seanbudd self-assigned this Mar 5, 2021
@lukaszgo1
Copy link
Contributor

* [x]  #10703, #10732 (work done in #11969)

#10732 has not been fixed yet. #11969 only removed code marked as deprecated in #10703.

@seanbudd
Copy link
Member Author

seanbudd commented Mar 8, 2021

Thanks @lukaszgo1, I think I misread something

@codeofdusk
Copy link
Contributor

codeofdusk commented Mar 9, 2021

@seanbudd Just curious, do you have any relationship with NV Access?

@seanbudd
Copy link
Member Author

seanbudd commented Mar 9, 2021

Hi @codeofdusk, yes, I'm a recent software developer hire at NV Access. I'll have a short introduction about me in an upcoming newsletter.

edit: here it is!

@lukaszgo1
Copy link
Contributor

I've grepped the sources for "backwards compat" in addition to "deprec" and it turns out there are a few more places which come up.

There are two more which are in my view worth discussing:

@feerrenrut
Copy link
Contributor

Thanks @lukaszgo1. Yes, these alias's with comments "kept for backwards compatibility" should be removed.

@seanbudd
Copy link
Member Author

I saw Issue #10916 and PR #12105 as other ones worth discussing/adding to this list of deprecations/breaking changes.

@seanbudd
Copy link
Member Author

There are two more which are in my view worth discussing:

@lukaszgo1 Given Reef's clarification, were you looking at fixing these? Happy to pick them up if not.

@lukaszgo1
Copy link
Contributor

I'll look into them either later today or during the weekend.

@seanbudd
Copy link
Member Author

I'm going to start on removing the backwards compatibility introduced in #10934 tomorrow, if you haven't already started on it

@lukaszgo1
Copy link
Contributor

I'm going to start on removing the backwards compatibility introduced in #10934 tomorrow, if you haven't already started on it

I've written most of the code already - it is available in IAccessibleHandlerNoStarImportsForCOMInterfaces on my fork. I'll finish it off as soon as I can.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deprecated/2021.1 Label used to track deprecations due for removal in the 2021.1 release
Projects
None yet
Development

No branches or pull requests

4 participants