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

Revert "Fix error message for deleteRule()" #16353

Merged
merged 1 commit into from Apr 15, 2019

Conversation

chromium-wpt-export-bot
Copy link
Collaborator

This reverts commit b2caae9ede888ede7d662c8760da9ab765904571.

Reason for revert: Reverting while I get more context on the deprecation of IndexSizeError

Original change's description:

Fix error message for deleteRule()

Previous to this CL, deleteRule on an empty style sheet would throw a
confusingly-worded IndexSizeError. Now, it properly throws a RangeError.

For example:

const styleEl = document.createElement('style');
document.head.appendChild(styleEl);
styleEl.sheet.deleteRule(0);
--> Uncaught RangeError: Failed to execute 'deleteRule' on 'CSSStyleSheet': The index provided (0) is outside the range [0, 0).

Bug: 949523
Change-Id: I306409f53be88f4bead261dd171466fd3aad5565
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1561410
Auto-Submit: Mason Freed <masonfreed@chromium.org>
Commit-Queue: Chris Harrelson <chrishtr@chromium.org>
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#650697}

TBR=chrishtr@chromium.org,masonfreed@chromium.org

Change-Id: I773160a6ffa263dd7b8d2eb9c9025ad46a970044
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 949523
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1566836
Reviewed-by: Mason Freed <masonfreed@chromium.org>
Commit-Queue: Mason Freed <masonfreed@chromium.org>
Cr-Commit-Position: refs/heads/master@{#650835}

This reverts commit b2caae9ede888ede7d662c8760da9ab765904571.

Reason for revert: Reverting while I get more context on the deprecation of IndexSizeError

Original change's description:
> Fix error message for deleteRule()
>
> Previous to this CL, deleteRule on an empty style sheet would throw a
> confusingly-worded IndexSizeError. Now, it properly throws a RangeError.
>
> For example:
>
> const styleEl = document.createElement('style');
> document.head.appendChild(styleEl);
> styleEl.sheet.deleteRule(0);
> --> Uncaught RangeError: Failed to execute 'deleteRule' on 'CSSStyleSheet': The index provided (0) is outside the range [0, 0).
>
> Bug: 949523
> Change-Id: I306409f53be88f4bead261dd171466fd3aad5565
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1561410
> Auto-Submit: Mason Freed <masonfreed@chromium.org>
> Commit-Queue: Chris Harrelson <chrishtr@chromium.org>
> Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#650697}

TBR=chrishtr@chromium.org,masonfreed@chromium.org

Change-Id: I773160a6ffa263dd7b8d2eb9c9025ad46a970044
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 949523
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1566836
Reviewed-by: Mason Freed <masonfreed@chromium.org>
Commit-Queue: Mason Freed <masonfreed@chromium.org>
Cr-Commit-Position: refs/heads/master@{#650835}
Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already reviewed downstream.

@chromium-wpt-export-bot chromium-wpt-export-bot merged commit 1a9adfc into master Apr 15, 2019
@chromium-wpt-export-bot chromium-wpt-export-bot deleted the chromium-export-87e1bab69e branch April 15, 2019 17:08
foolip pushed a commit that referenced this pull request Sep 6, 2019
This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
#16342
#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
foolip added a commit that referenced this pull request Sep 6, 2019
This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
#16342
#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
foolip added a commit that referenced this pull request Sep 9, 2019
This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
#16342
#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Sep 14, 2019
…estonly

Automatic update from web-platform-tests
Test more CSSStyleSheet error cases (#18892)

This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
web-platform-tests/wpt#16342
web-platform-tests/wpt#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
--

wpt-commits: 8ed93b5f2393c8f123d6cc8b6daea9ecbf2eb2fd
wpt-pr: 18892
xeonchen pushed a commit to xeonchen/gecko that referenced this pull request Sep 14, 2019
…estonly

Automatic update from web-platform-tests
Test more CSSStyleSheet error cases (#18892)

This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
web-platform-tests/wpt#16342
web-platform-tests/wpt#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
--

wpt-commits: 8ed93b5f2393c8f123d6cc8b6daea9ecbf2eb2fd
wpt-pr: 18892
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
Test more CSSStyleSheet error cases (#18892)

This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
web-platform-tests/wpt#16342
web-platform-tests/wpt#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
--

wpt-commits: 8ed93b5f2393c8f123d6cc8b6daea9ecbf2eb2fd
wpt-pr: 18892

UltraBlame original commit: 2e44fe0d766c1ca7c6410f9d4e0bffed071e5ef2
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
Test more CSSStyleSheet error cases (#18892)

This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
web-platform-tests/wpt#16342
web-platform-tests/wpt#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
--

wpt-commits: 8ed93b5f2393c8f123d6cc8b6daea9ecbf2eb2fd
wpt-pr: 18892

UltraBlame original commit: 2e44fe0d766c1ca7c6410f9d4e0bffed071e5ef2
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
Test more CSSStyleSheet error cases (#18892)

This is mainly to get coverage of calling `deleteRule()` on an empty
style, which was added and reverted with the wrong exception type:
web-platform-tests/wpt#16342
web-platform-tests/wpt#16353

The test is split into more subtests, but the order is kept the same
and only `assert_throws` tests were added in between tests to avoid
having to change anything. For this reason the order of subtests is a
bit haphazard.
--

wpt-commits: 8ed93b5f2393c8f123d6cc8b6daea9ecbf2eb2fd
wpt-pr: 18892

UltraBlame original commit: 2e44fe0d766c1ca7c6410f9d4e0bffed071e5ef2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants