Skip to content

Track: Remove deprecated core library APIs #49845

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

Open
1 of 3 tasks
nuritzi opened this issue Aug 29, 2022 · 6 comments
Open
1 of 3 tasks

Track: Remove deprecated core library APIs #49845

nuritzi opened this issue Aug 29, 2022 · 6 comments
Assignees
Labels
area-meta Cross-cutting, high-level issues (for tracking many other implementation issues, ...).

Comments

@nuritzi
Copy link

nuritzi commented Aug 29, 2022

Goal: We'd like to track progress on removing core library APIs that have earlier been deprecated. This will help us track progress towards our next Dart major version.

Frequency: we'd like to pull these stats on a weekly basis.

How to

You may be able to get this information by # search hits for "@deprecated" in sdk/lib/

Todos

  • Measure: Number of deprecations left to remove.
  • Document how you pulled this information (can be in a doc or in this issue).
  • Automate a weekly report if possible.
@nuritzi
Copy link
Author

nuritzi commented Aug 29, 2022

@itsjustkevin -- it looks like I don't have the ability to assign issues to people. Are you able to do so? this issue is meant for you to help with after the upcoming release.

@itsjustkevin itsjustkevin self-assigned this Aug 30, 2022
@itsjustkevin
Copy link
Contributor

I self-assigned.

@devoncarew devoncarew added the area-meta Cross-cutting, high-level issues (for tracking many other implementation issues, ...). label Aug 31, 2022
@itsjustkevin
Copy link
Contributor

@sigmundch I ran a git grep --count '@deprecated' over the sdk/lib directory and found that a lot of the @deprecated annotations are in dart2js.

My question is, what work do we need to do to remove these deprecations?

grep output

_internal/js_dev_runtime/patch/core_patch.dart:2
_internal/js_dev_runtime/private/isolate_helper.dart:1
_internal/js_runtime/lib/core_patch.dart:2
_internal/vm/lib/double_patch.dart:1
_internal/wasm/lib/double.dart:1
core/annotations.dart:3
core/double.dart:1
core/int.dart:1
core/num.dart:1
html/dart2js/html_dart2js.dart:33
io/security_context.dart:1
web_sql/dart2js/web_sql_dart2js.dart:2

@itsjustkevin
Copy link
Contributor

itsjustkevin commented Sep 13, 2022

_internal/js_dev_runtime/patch/core_patch.dart:2
_internal/js_dev_runtime/private/isolate_helper.dart:1
_internal/js_runtime/lib/core_patch.dart:2
_internal/vm/lib/double_patch.dart:1
_internal/wasm/lib/double.dart:1
core/annotations.dart:3
core/double.dart:1
core/int.dart:1
core/num.dart:1
html/dart2js/html_dart2js.dart:33
io/security_context.dart:1
web_sql/dart2js/web_sql_dart2js.dart:2

@sigmundch
Copy link
Member

@itsjustkevin - I know you are still circling back on the precise goals here, but some quick insights into the list you shared:

  • num.parse has a deprecated onError parameter, this deprecation is behind all the annotations in this list:
_internal/js_dev_runtime/patch/core_patch.dart:2
_internal/js_dev_runtime/private/isolate_helper.dart:1
_internal/js_runtime/lib/core_patch.dart:2
_internal/vm/lib/double_patch.dart:1
_internal/wasm/lib/double.dart:1
core/double.dart:1
core/int.dart:1
core/num.dart:1
  • deprecations on annotations and in dart:io are their own thing, but I'm not familiar with the plan here:
core/annotations.dart:3
io/security_context.dart:1
  • Finally we have the dart:html deprecations:
html/dart2js/html_dart2js.dart:33
web_sql/dart2js/web_sql_dart2js.dart:2

The web_sql library was practically removed for external developers since 2.15. The file exists, but we can ignore it. That's because it is not built into our sdk .dill files and it's not possible to import it (so we made this breaking change already at commit 38b5a841). The reason the file still exists is because cleaning it up is more work than it was worth at the moment.

Finally, as we briefly mentioned on the scrum the other day, the dart:html library is special. Given our plans to put together a new package that will eventually replace this library, we are less inclined to delete the deprecated APIs at this time. It's possible however that we will delete the few APIs related to this breaking change: #49536

@mit-mit
Copy link
Member

mit-mit commented Oct 10, 2022

I'm currently tracking this in #49529

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-meta Cross-cutting, high-level issues (for tracking many other implementation issues, ...).
Projects
None yet
Development

No branches or pull requests

5 participants