Bug 190936 - Add a deprecation warning to console for Web SQL
Summary: Add a deprecation warning to console for Web SQL
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sihui Liu
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-10-25 18:05 PDT by Sihui Liu
Modified: 2018-10-30 10:33 PDT (History)
8 users (show)

See Also:


Attachments
Patch (30.79 KB, patch)
2018-10-25 18:08 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews103 for mac-sierra (2.50 MB, application/zip)
2018-10-25 19:10 PDT, EWS Watchlist
no flags Details
Archive of layout-test-results from ews106 for mac-sierra-wk2 (3.00 MB, application/zip)
2018-10-25 19:20 PDT, EWS Watchlist
no flags Details
Archive of layout-test-results from ews200 for win-future (12.82 MB, application/zip)
2018-10-25 19:42 PDT, EWS Watchlist
no flags Details
Archive of layout-test-results from ews126 for ios-simulator-wk2 (2.40 MB, application/zip)
2018-10-25 20:01 PDT, EWS Watchlist
no flags Details
Archive of layout-test-results from ews116 for mac-sierra (3.50 MB, application/zip)
2018-10-25 21:24 PDT, EWS Watchlist
no flags Details
Patch (41.63 KB, patch)
2018-10-26 11:54 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews102 for mac-sierra (2.50 MB, application/zip)
2018-10-26 12:47 PDT, EWS Watchlist
no flags Details
Patch (42.32 KB, patch)
2018-10-26 12:52 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Patch (41.22 KB, patch)
2018-10-29 09:25 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Patch for landing (40.96 KB, patch)
2018-10-30 09:43 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sihui Liu 2018-10-25 18:05:34 PDT
Tell web developers to switch to IndexedDB.
Comment 1 Sihui Liu 2018-10-25 18:08:43 PDT
Created attachment 353134 [details]
Patch
Comment 2 EWS Watchlist 2018-10-25 19:10:33 PDT
Comment on attachment 353134 [details]
Patch

Attachment 353134 [details] did not pass mac-ews (mac):
Output: https://webkit-queues.webkit.org/results/9732912

New failing tests:
http/tests/security/cross-origin-websql-allowed.html
http/tests/security/storage-blocking-loosened-websql.html
http/tests/security/same-origin-websql-blocked.html
fast/frames/sandboxed-iframe-storage.html
http/tests/storage/callbacks-are-called-in-correct-context.html
js/dom/callback-function-with-handle-event.html
inspector/runtime/CommandLineAPI-inspect.html
storage/websql/open-database-while-transaction-in-progress.html
fast/history/page-cache-webdatabase-no-transaction-db.html
js/dom/exceptions-thrown-in-callbacks.html
storage/websql/multiple-databases-garbage-collection.html
http/tests/security/storage-blocking-strengthened-websql.html
http/tests/security/cross-origin-websql.html
fast/dom/MutationObserver/database-callback-delivery.html
storage/websql/private-browsing-noread-nowrite.html
Comment 3 EWS Watchlist 2018-10-25 19:10:35 PDT
Created attachment 353141 [details]
Archive of layout-test-results from ews103 for mac-sierra

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews103  Port: mac-sierra  Platform: Mac OS X 10.12.6
Comment 4 EWS Watchlist 2018-10-25 19:20:57 PDT
Comment on attachment 353134 [details]
Patch

Attachment 353134 [details] did not pass mac-wk2-ews (mac-wk2):
Output: https://webkit-queues.webkit.org/results/9732934

New failing tests:
http/tests/security/cross-origin-websql-allowed.html
http/tests/security/storage-blocking-loosened-websql.html
http/tests/security/same-origin-websql-blocked.html
http/tests/storage/callbacks-are-called-in-correct-context.html
js/dom/callback-function-with-handle-event.html
fast/history/page-cache-webdatabase-no-transaction-db.html
js/dom/exceptions-thrown-in-callbacks.html
http/tests/security/storage-blocking-strengthened-websql.html
http/tests/security/cross-origin-websql.html
fast/dom/MutationObserver/database-callback-delivery.html
inspector/runtime/CommandLineAPI-inspect.html
Comment 5 EWS Watchlist 2018-10-25 19:20:59 PDT
Created attachment 353142 [details]
Archive of layout-test-results from ews106 for mac-sierra-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews106  Port: mac-sierra-wk2  Platform: Mac OS X 10.12.6
Comment 6 EWS Watchlist 2018-10-25 19:42:24 PDT
Comment on attachment 353134 [details]
Patch

Attachment 353134 [details] did not pass win-ews (win):
Output: https://webkit-queues.webkit.org/results/9733038

New failing tests:
http/tests/security/same-origin-websql-blocked.html
Comment 7 EWS Watchlist 2018-10-25 19:42:44 PDT
Created attachment 353146 [details]
Archive of layout-test-results from ews200 for win-future

The attached test failures were seen while running run-webkit-tests on the win-ews.
Bot: ews200  Port: win-future  Platform: CYGWIN_NT-6.1-2.9.0-0.318-5-3-x86_64-64bit
Comment 8 EWS Watchlist 2018-10-25 20:01:24 PDT
Comment on attachment 353134 [details]
Patch

Attachment 353134 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: https://webkit-queues.webkit.org/results/9732993

New failing tests:
http/tests/security/cross-origin-websql-allowed.html
http/tests/security/storage-blocking-loosened-websql.html
http/tests/security/same-origin-websql-blocked.html
js/dom/callback-function-with-handle-event.html
fast/history/page-cache-webdatabase-no-transaction-db.html
js/dom/exceptions-thrown-in-callbacks.html
http/tests/security/storage-blocking-strengthened-websql.html
http/tests/security/cross-origin-websql.html
fast/dom/MutationObserver/database-callback-delivery.html
storage/websql/private-browsing-noread-nowrite.html
Comment 9 EWS Watchlist 2018-10-25 20:01:26 PDT
Created attachment 353149 [details]
Archive of layout-test-results from ews126 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews126  Port: ios-simulator-wk2  Platform: Mac OS X 10.13.6
Comment 10 EWS Watchlist 2018-10-25 21:24:21 PDT
Comment on attachment 353134 [details]
Patch

Attachment 353134 [details] did not pass mac-debug-ews (mac):
Output: https://webkit-queues.webkit.org/results/9733570

New failing tests:
http/tests/security/cross-origin-websql-allowed.html
storage/websql/private-browsing-noread-nowrite.html
http/tests/security/storage-blocking-loosened-websql.html
http/tests/security/same-origin-websql-blocked.html
fast/frames/sandboxed-iframe-storage.html
http/tests/storage/callbacks-are-called-in-correct-context.html
storage/websql/open-database-while-transaction-in-progress.html
js/dom/callback-function-with-handle-event.html
fast/history/page-cache-webdatabase-no-transaction-db.html
js/dom/exceptions-thrown-in-callbacks.html
storage/websql/multiple-databases-garbage-collection.html
http/tests/security/storage-blocking-strengthened-websql.html
http/tests/security/cross-origin-websql.html
fast/dom/MutationObserver/database-callback-delivery.html
inspector/runtime/CommandLineAPI-inspect.html
Comment 11 EWS Watchlist 2018-10-25 21:24:23 PDT
Created attachment 353154 [details]
Archive of layout-test-results from ews116 for mac-sierra

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews116  Port: mac-sierra  Platform: Mac OS X 10.12.6
Comment 12 Sihui Liu 2018-10-26 11:54:28 PDT
Created attachment 353196 [details]
Patch
Comment 13 EWS Watchlist 2018-10-26 12:47:52 PDT
Comment on attachment 353196 [details]
Patch

Attachment 353196 [details] did not pass mac-ews (mac):
Output: https://webkit-queues.webkit.org/results/9742085

New failing tests:
http/tests/storage/callbacks-are-called-in-correct-context.html
Comment 14 EWS Watchlist 2018-10-26 12:47:54 PDT
Created attachment 353201 [details]
Archive of layout-test-results from ews102 for mac-sierra

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews102  Port: mac-sierra  Platform: Mac OS X 10.12.6
Comment 15 Sihui Liu 2018-10-26 12:52:00 PDT
Created attachment 353203 [details]
Patch
Comment 16 Daniel Bates 2018-10-26 19:48:15 PDT
Comment on attachment 353203 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=353203&action=review

> Source/WebCore/Modules/webdatabase/DOMWindowWebDatabase.cpp:48
> +    document->addConsoleMessage(MessageSource::Storage, MessageLevel::Warning, "Web SQL will be deprecated in WebKit. Please change over to IndexedDB.");

will be  => is
Comment 17 Daniel Bates 2018-10-26 19:49:28 PDT
(In reply to Daniel Bates from comment #16)
> Comment on attachment 353203 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=353203&action=review
> 
> > Source/WebCore/Modules/webdatabase/DOMWindowWebDatabase.cpp:48
> > +    document->addConsoleMessage(MessageSource::Storage, MessageLevel::Warning, "Web SQL will be deprecated in WebKit. Please change over to IndexedDB.");
> 
> will be  => is

Also, no need to mention WebKit as it is obvious to the audience.
Comment 18 Sihui Liu 2018-10-26 23:17:05 PDT
(In reply to Daniel Bates from comment #17)
> (In reply to Daniel Bates from comment #16)
> > Comment on attachment 353203 [details]
> > Patch
> > 
> > View in context:
> > https://bugs.webkit.org/attachment.cgi?id=353203&action=review
> > 
> > > Source/WebCore/Modules/webdatabase/DOMWindowWebDatabase.cpp:48
> > > +    document->addConsoleMessage(MessageSource::Storage, MessageLevel::Warning, "Web SQL will be deprecated in WebKit. Please change over to IndexedDB.");
> > 
> > will be  => is
> 
> Also, no need to mention WebKit as it is obvious to the audience.

Web SQL has not been dropped yet. Should I use "is" here?
Comment 19 Daniel Bates 2018-10-26 23:23:09 PDT
(In reply to Sihui Liu from comment #18)
> (In reply to Daniel Bates from comment #17)
> > (In reply to Daniel Bates from comment #16)
> > > Comment on attachment 353203 [details]
> > > Patch
> > > 
> > > View in context:
> > > https://bugs.webkit.org/attachment.cgi?id=353203&action=review
> > > 
> > > > Source/WebCore/Modules/webdatabase/DOMWindowWebDatabase.cpp:48
> > > > +    document->addConsoleMessage(MessageSource::Storage, MessageLevel::Warning, "Web SQL will be deprecated in WebKit. Please change over to IndexedDB.");
> > > 
> > > will be  => is
> > 
> > Also, no need to mention WebKit as it is obvious to the audience.
> 
> Web SQL has not been dropped yet. Should I use "is" here?

Are you planning to keep this message after its been removed?
Comment 20 Daniel Bates 2018-10-26 23:25:47 PDT
(In reply to Daniel Bates from comment #19)
> (In reply to Sihui Liu from comment #18)
> > (In reply to Daniel Bates from comment #17)
> > > (In reply to Daniel Bates from comment #16)
> > > > Comment on attachment 353203 [details]
> > > > Patch
> > > > 
> > > > View in context:
> > > > https://bugs.webkit.org/attachment.cgi?id=353203&action=review
> > > > 
> > > > > Source/WebCore/Modules/webdatabase/DOMWindowWebDatabase.cpp:48
> > > > > +    document->addConsoleMessage(MessageSource::Storage, MessageLevel::Warning, "Web SQL will be deprecated in WebKit. Please change over to IndexedDB.");
> > > > 
> > > > will be  => is
> > > 
> > > Also, no need to mention WebKit as it is obvious to the audience.
> > 
> > Web SQL has not been dropped yet. Should I use "is" here?
> 
> Are you planning to keep this message after its been removed?

*keep this message or a variant of it after Web SQL has been removed?
Comment 21 Daniel Bates 2018-10-26 23:27:54 PDT
(In reply to Sihui Liu from comment #18)
> (In reply to Daniel Bates from comment #17)
> > (In reply to Daniel Bates from comment #16)
> > > Comment on attachment 353203 [details]
> > > Patch
> > > 
> > > View in context:
> > > https://bugs.webkit.org/attachment.cgi?id=353203&action=review
> > > 
> > > > Source/WebCore/Modules/webdatabase/DOMWindowWebDatabase.cpp:48
> > > > +    document->addConsoleMessage(MessageSource::Storage, MessageLevel::Warning, "Web SQL will be deprecated in WebKit. Please change over to IndexedDB.");
> > > 
> > > will be  => is
> > 
> > Also, no need to mention WebKit as it is obvious to the audience.
> 
> Web SQL has not been dropped yet. Should I use "is" here?

I think “is” is appropriate here. They way this message is worded means this message is a notice of a future deprecation notice (I.e. a notice of a notice). One notice seems sufficient.
Comment 22 Chris Dumez 2018-10-27 09:46:33 PDT
(In reply to Daniel Bates from comment #21)
> (In reply to Sihui Liu from comment #18)
> > (In reply to Daniel Bates from comment #17)
> > > (In reply to Daniel Bates from comment #16)
> > > > Comment on attachment 353203 [details]
> > > > Patch
> > > > 
> > > > View in context:
> > > > https://bugs.webkit.org/attachment.cgi?id=353203&action=review
> > > > 
> > > > > Source/WebCore/Modules/webdatabase/DOMWindowWebDatabase.cpp:48
> > > > > +    document->addConsoleMessage(MessageSource::Storage, MessageLevel::Warning, "Web SQL will be deprecated in WebKit. Please change over to IndexedDB.");
> > > > 
> > > > will be  => is
> > > 
> > > Also, no need to mention WebKit as it is obvious to the audience.
> > 
> > Web SQL has not been dropped yet. Should I use "is" here?
> 
> I think “is” is appropriate here. They way this message is worded means this
> message is a notice of a future deprecation notice (I.e. a notice of a
> notice). One notice seems sufficient.

+1 for “is deprecated”.
Comment 23 Sihui Liu 2018-10-29 09:25:09 PDT
Created attachment 353292 [details]
Patch
Comment 24 Ryosuke Niwa 2018-10-29 15:02:27 PDT
Comment on attachment 353292 [details]
Patch

So I think our typical message is that "X is deprecated. Please use Y instead".
See examples for ApplicationCache, CSSKeyframesRule::insertRule, XMLHttpRequest::send(ArrayBuffer&), etc...
For consistency, we should do the same.

r=me with that message change.
Comment 25 Sihui Liu 2018-10-30 09:43:02 PDT
Created attachment 353377 [details]
Patch for landing
Comment 26 WebKit Commit Bot 2018-10-30 10:31:08 PDT
The commit-queue encountered the following flaky tests while processing attachment 353377 [details]:

fetch/fetch-worker-crash.html bug 187257 (author: youennf@gmail.com)
The commit-queue is continuing to process your patch.
Comment 27 WebKit Commit Bot 2018-10-30 10:32:14 PDT
Comment on attachment 353377 [details]
Patch for landing

Clearing flags on attachment: 353377

Committed r237591: <https://trac.webkit.org/changeset/237591>
Comment 28 WebKit Commit Bot 2018-10-30 10:32:16 PDT
All reviewed patches have been landed.  Closing bug.
Comment 29 Radar WebKit Bug Importer 2018-10-30 10:33:50 PDT
<rdar://problem/45672606>