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

Should we rewrite/canonicalize WebDriver errors? #50076

Open
gsnedders opened this issue Jan 14, 2025 · 0 comments
Open

Should we rewrite/canonicalize WebDriver errors? #50076

gsnedders opened this issue Jan 14, 2025 · 0 comments

Comments

@gsnedders
Copy link
Member

See https://github.com/web-platform-tests/wpt/pull/48866/files#r1821477471

We currently canonicalize an empty message string to None, an empty stacktrace string to None, and an empty data object to None.

As @whimboo reasonably pointed out in the above review thread,

I think we shouldn’t modify the returned value if it’s an empty list (or any similar value that evaluates to None). Doing so would alter the data we actually want to test and could lead to discrepancies with the spec—or could let issues slip by unnoticed, such as when a client returns an incorrect type.

We should maybe revisit this.

The stacktrace case goes back to when the code was originally written in 48edfb1 (no justification given for this behaviour), the message case goes back to 3b83423 when I changed it to make the if message is None check actually work, and the data case goes back to when #48866 lands, matching the other two.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant