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

Deprecated APIs message does not suggest replacements #14494

Closed
DartBot opened this issue Oct 26, 2013 · 12 comments
Closed

Deprecated APIs message does not suggest replacements #14494

DartBot opened this issue Oct 26, 2013 · 12 comments
Assignees
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. closed-obsolete Closed as the reported issue is no longer relevant docs-api library-html P3 A lower priority bug or feature request

Comments

@DartBot
Copy link

DartBot commented Oct 26, 2013

This issue was originally filed by LukeEChur...@gmail.com


E.g. add queryAll("");

The popup text reads:

"ElementList queryAll(String relativeSelectors)

Alias for [querySelectorAll]. Note this function is deprecated because its semantics will be changing in
 the future."

This is unhelpful, esp. as we have published documents (https://www.dartlang.org/docs/dart-up-and-running/contents/ch03.html) suggesting that this is correct.

As per the guidance https://codereview.chromium.org/21242002/diff/20001/dart/sdk/lib/_internal/compiler/implementation/warnings.dart

to the compiler team, error messages need to state:

 1. what is wrong
2. why is it wrong
3. how do I fix

As such recommend:

  • What is wrong: "This function is depreciated."
  • Why is it wrong: "Its behaviour will be changing, so using it today may result in bugs in the future"
  • How do I fix it (???)

For such an essential API the lack of (3) is a serious defect.

======

Putting this under editor to start with - but I suspect it may need to be moved to another area.

@clayberg
Copy link

In this case, I the "how do I fix" is to replace queryAll() with querySelectorAll(). I presume this could be derived from the rest of the message and added on at the end.

@clayberg
Copy link

Set owner to @jwren.
Added this to the Later milestone.

@clayberg
Copy link

clayberg commented Nov 8, 2013

Removed this from the Later milestone.
Added this to the M9 milestone.

@clayberg
Copy link

Removed this from the M9 milestone.
Added this to the 1.1 milestone.

@clayberg
Copy link

Removed this from the 1.1 milestone.
Added this to the 1.2 milestone.

@jwren
Copy link
Member

jwren commented Feb 7, 2014

This is a general SDK-documentation concern. Assigning to DartDoc, perhaps when generating the DartDoc, anything marked as deprecated should also somehow be required or encouraged to provide a way to not use the deprecated method?


Removed the owner.
Removed this from the 1.2 milestone.
Added this to the 1.3 milestone.
Removed Area-Editor label.
Added Area-DartDoc label.

@kevmoo
Copy link
Member

kevmoo commented Mar 17, 2014

Added Pkg-DartDoc label.

@kevmoo
Copy link
Member

kevmoo commented Mar 17, 2014

Removed Area-DartDoc label.
Added Area-Pkg label.

@kevmoo
Copy link
Member

kevmoo commented Apr 7, 2014

Removed Pkg-DartDoc label.
Added Pkg-DocGen label.

@kasperl
Copy link

kasperl commented Jun 4, 2014

Removed this from the 1.3 milestone.
Added this to the 1.6 milestone.

@sethladd
Copy link
Contributor

Removed this from the 1.6 milestone.
Removed Priority-High, Area-Pkg, Pkg-DocGen labels.
Added Priority-Low, Docs-API, Area-Library, Library-Html labels.

@alan-knight
Copy link
Contributor

This might fall in the general ballpark of generating better doc comments. I'll grab it for the moment.


Set owner to @alan-knight.

@DartBot DartBot added Type-Defect P3 A lower priority bug or feature request docs-api area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. library-html labels Jan 13, 2015
@mit-mit mit-mit added the closed-obsolete Closed as the reported issue is no longer relevant label Sep 11, 2015
@mit-mit mit-mit closed this as completed Sep 11, 2015
@kevmoo kevmoo removed the triaged label Mar 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. closed-obsolete Closed as the reported issue is no longer relevant docs-api library-html P3 A lower priority bug or feature request
Projects
None yet
Development

No branches or pull requests

8 participants