Skip to content

Commit 38b5a84

Browse files
sigmundchcommit-bot@chromium.org
authored andcommitted
[dart-web] Remove dart:web_sql library.
The WebSQL standard was abandoned more than 10 years ago and is not supported by many browsers. The `dart:web_sql` library was marked as deprecated in Dart 2.14. This CL makes the library inaccesible, removes support for `dart:web_sql` imports, and removes the `Window.openDatabase` API. The old code for `dart:web_sql` is still generated by the html generators. Removing that will be handled by a separate change. Closes #46316 Change-Id: I892107396b3b227b4f33344377585aa5e5328288 Bug: #46316 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216080 Reviewed-by: Srujan Gaddam <srujzs@google.com> Commit-Queue: Sigmund Cherem <sigmund@google.com>
1 parent 5fff311 commit 38b5a84

File tree

25 files changed

+40
-344
lines changed

25 files changed

+40
-344
lines changed

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -427,6 +427,19 @@
427427
`callConstructor`, and `newObject` now support a generic type argument
428428
to specify the return type.
429429

430+
#### `dart:web_sql`
431+
432+
- **Breaking Change** [#46316](https://github.com/dart-lang/sdk/issues/46316):
433+
The WebSQL standard was abandoned more than 10
434+
years ago and is not supported by many browsers. This release completely
435+
deletes the `dart:web_sql` library.
436+
437+
#### `dart:html`
438+
439+
- **Breaking Change** [#46316](https://github.com/dart-lang/sdk/issues/46316):
440+
Related to the removal of `dart:web_sql` (see above), the
441+
`window.openDatabase` has been removed as well.
442+
430443
### Tools
431444

432445
#### Dart command line

pkg/compiler/lib/src/common/names.dart

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -224,9 +224,6 @@ class Uris {
224224
/// The URI for 'dart:web_gl'.
225225
static final Uri dart_web_gl = Uri(scheme: 'dart', path: 'web_gl');
226226

227-
/// The URI for 'dart:web_sql'.
228-
static final Uri dart_web_sql = Uri(scheme: 'dart', path: 'web_sql');
229-
230227
/// The URI for 'dart:_js_helper'.
231228
static final Uri dart__js_helper = Uri(scheme: 'dart', path: '_js_helper');
232229

pkg/compiler/lib/src/js_model/element_map_impl.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1359,7 +1359,6 @@ class JsKernelToElementMap implements JsToElementMap, IrToElementMap {
13591359
type ??= findIn(Uris.dart_svg);
13601360
type ??= findIn(Uris.dart_web_audio);
13611361
type ??= findIn(Uris.dart_web_gl);
1362-
type ??= findIn(Uris.dart_web_sql);
13631362
type ??= findIn(Uris.dart_indexed_db);
13641363
type ??= findIn(Uris.dart_typed_data);
13651364
type ??= findIn(Uris.dart__rti);

pkg/compiler/lib/src/kernel/dart2js_target.dart

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ const Iterable<String> _allowedDartSchemePaths = [
3636
'_native_typed_data',
3737
'web_audio',
3838
'web_gl',
39-
'web_sql'
4039
];
4140

4241
List<Pattern> _allowedNativeTestPatterns = [
@@ -246,7 +245,6 @@ const _requiredLibraries = <String, List<String>>{
246245
'dart:svg',
247246
'dart:web_audio',
248247
'dart:web_gl',
249-
'dart:web_sql',
250248
],
251249
'dart2js_server': [
252250
'dart:_dart2js_runtime_metrics',

pkg/compiler/lib/src/kernel/element_map_impl.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -949,7 +949,6 @@ class KernelToElementMapImpl implements KernelToElementMap, IrToElementMap {
949949
type ??= findIn(Uris.dart_svg);
950950
type ??= findIn(Uris.dart_web_audio);
951951
type ??= findIn(Uris.dart_web_gl);
952-
type ??= findIn(Uris.dart_web_sql);
953952
type ??= findIn(Uris.dart_indexed_db);
954953
type ??= findIn(Uris.dart_typed_data);
955954
type ??= findIn(Uris.dart__rti);

pkg/compiler/test/impact/data/jsinterop.dart

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ class JsInteropClass {
4343
native:OverconstrainedError,
4444
native:PositionError,
4545
native:SensorErrorEvent,
46-
native:SpeechRecognitionError,
47-
native:SqlError]
46+
native:SpeechRecognitionError]
4847
*/
4948
@JS()
5049
external double method();

pkg/compiler/test/impact/data/jsinterop_setter1.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@ import 'package:js/js.dart';
6161
native:PositionError,
6262
native:SensorErrorEvent,
6363
native:SpeechRecognitionError,
64-
native:SqlError,
6564
param:Function*]
6665
*/
6766
@JS()

pkg/compiler/test/impact/data/jsinterop_setter2.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ import 'package:js/js.dart';
6868
native:PositionError,
6969
native:SensorErrorEvent,
7070
native:SpeechRecognitionError,
71-
native:SqlError,
7271
param:void Function(String*,File*)*]
7372
*/
7473
@JS()

pkg/compiler/test/impact/data/native.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ main() {
2929
type=[inst:JSNull,inst:JSString,native:bool,native:int]
3030
*/
3131
testJSCall() => foreign.JS(
32-
'int|bool|NativeUint8List|Rectangle|IdbFactory|SqlDatabase|TypedData|ContextAttributes',
32+
'int|bool|NativeUint8List|Rectangle|IdbFactory|TypedData|ContextAttributes',
3333
'#',
3434
null);
3535

pkg/dev_compiler/lib/src/kernel/native_types.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@ class NativeTypeSet {
7171
_addPendingExtensionTypes(sdk.getLibrary('dart:svg'));
7272
_addPendingExtensionTypes(sdk.getLibrary('dart:web_audio'));
7373
_addPendingExtensionTypes(sdk.getLibrary('dart:web_gl'));
74-
_addPendingExtensionTypes(sdk.getLibrary('dart:web_sql'));
7574

7675
// For testing purposes only, we add extension types outside the Dart SDK.
7776
// These are only allowed for native tests (see allowedNativeTest).

0 commit comments

Comments
 (0)