LibWeb: Print FIXME instead of throwing NotSupportedError in WebAudio
Some checks are pending
CI / Lagom (arm64, Sanitizer_CI, false, macOS, macos-15, Clang) (push) Waiting to run
CI / Lagom (x86_64, Fuzzers_CI, false, Linux, blacksmith-16vcpu-ubuntu-2404, Clang) (push) Waiting to run
CI / Lagom (x86_64, Sanitizer_CI, false, Linux, blacksmith-16vcpu-ubuntu-2404, GNU) (push) Waiting to run
CI / Lagom (x86_64, Sanitizer_CI, true, Linux, blacksmith-16vcpu-ubuntu-2404, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (arm64, macOS, macOS-universal2, macos-15) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (x86_64, Linux, Linux-x86_64, blacksmith-8vcpu-ubuntu-2404) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Label PRs with merge conflicts / auto-labeler (push) Waiting to run
Push notes / build (push) Waiting to run

This allows us to browse https://pierre.co/ instead of being navigated
to error screen.
This commit is contained in:
Aliaksandr Kalenik 2025-05-26 14:28:37 +03:00 committed by Alexander Kalenik
commit c2c9348636
Notes: github-actions[bot] 2025-05-28 18:39:06 +00:00
4 changed files with 24 additions and 14 deletions

View file

@ -88,7 +88,7 @@ WebIDL::ExceptionOr<GC::Ref<AudioParam>> AudioParam::set_value_at_time(float val
(void)value;
(void)start_time;
dbgln("FIXME: Implement AudioParam::set_value_at_time");
return GC::Ref<AudioParam> { *this };
return GC::Ref { *this };
}
// https://webaudio.github.io/web-audio-api/#dom-audioparam-linearramptovalueattime
@ -96,7 +96,8 @@ WebIDL::ExceptionOr<GC::Ref<AudioParam>> AudioParam::linear_ramp_to_value_at_tim
{
(void)value;
(void)end_time;
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioParam::linear_ramp_to_value_at_time"_string);
dbgln("FIXME: Implement AudioParam::linear_ramp_to_value_at_time");
return GC::Ref { *this };
}
// https://webaudio.github.io/web-audio-api/#dom-audioparam-exponentialramptovalueattime
@ -104,7 +105,8 @@ WebIDL::ExceptionOr<GC::Ref<AudioParam>> AudioParam::exponential_ramp_to_value_a
{
(void)value;
(void)end_time;
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioParam::exponential_ramp_to_value_at_time"_string);
dbgln("FIXME: Implement AudioParam::exponential_ramp_to_value_at_time");
return GC::Ref { *this };
}
// https://webaudio.github.io/web-audio-api/#dom-audioparam-settargetattime
@ -113,7 +115,8 @@ WebIDL::ExceptionOr<GC::Ref<AudioParam>> AudioParam::set_target_at_time(float ta
(void)target;
(void)start_time;
(void)time_constant;
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioParam::set_target_at_time"_string);
dbgln("FIXME: Implement AudioParam::set_target_at_time");
return GC::Ref { *this };
}
// https://webaudio.github.io/web-audio-api/#dom-audioparam-setvaluecurveattime
@ -122,21 +125,24 @@ WebIDL::ExceptionOr<GC::Ref<AudioParam>> AudioParam::set_value_curve_at_time(Spa
(void)values;
(void)start_time;
(void)duration;
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioParam::set_value_curve_at_time"_string);
dbgln("FIXME: Implement AudioParam::set_value_curve_at_time");
return GC::Ref { *this };
}
// https://webaudio.github.io/web-audio-api/#dom-audioparam-cancelscheduledvalues
WebIDL::ExceptionOr<GC::Ref<AudioParam>> AudioParam::cancel_scheduled_values(double cancel_time)
{
(void)cancel_time;
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioParam::cancel_scheduled_values"_string);
dbgln("FIXME: Implement AudioParam::cancel_scheduled_values");
return GC::Ref { *this };
}
// https://webaudio.github.io/web-audio-api/#dom-audioparam-cancelandholdattime
WebIDL::ExceptionOr<GC::Ref<AudioParam>> AudioParam::cancel_and_hold_at_time(double cancel_time)
{
(void)cancel_time;
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioParam::cancel_and_hold_at_time"_string);
dbgln("FIXME: Implement AudioParam::cancel_and_hold_at_time");
return GC::Ref { *this };
}
void AudioParam::initialize(JS::Realm& realm)

View file

@ -50,7 +50,8 @@ WebIDL::ExceptionOr<void> AudioScheduledSourceNode::start(double when)
// FIXME: 4. Queue a control message to start the AudioScheduledSourceNode, including the parameter values in the message.
// FIXME: 5. Send a control message to the associated AudioContext to start running its rendering thread only when all the following conditions are met:
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioScheduledSourceNode::start"_string);
dbgln("FIXME: Implement AudioScheduledSourceNode::start");
return {};
}
// https://webaudio.github.io/web-audio-api/#dom-audioscheduledsourcenode-stop
@ -67,7 +68,8 @@ WebIDL::ExceptionOr<void> AudioScheduledSourceNode::stop(double when)
// FIXME: 3. Queue a control message to stop the AudioScheduledSourceNode, including the parameter values in the message.
return WebIDL::NotSupportedError::create(realm(), "FIXME: Implement AudioScheduledSourceNode::stop"_string);
dbgln("FIXME: Implement AudioScheduledSourceNode::stop");
return {};
}
void AudioScheduledSourceNode::initialize(JS::Realm& realm)

View file

@ -316,3 +316,5 @@ Text/input/wpt-import/IndexedDB/idbfactory_open.any.html
; Slow on macOS. Takes ~200ms per request to the echo server.
; https://github.com/LadybirdBrowser/ladybird/issues/4850
Text/input/XHR/XMLHttpRequest-override-mimetype-blob.html
Text/input/wpt-import/webaudio/the-audio-api/the-periodicwave-interface/periodicWave.html

View file

@ -2,8 +2,8 @@ Harness status: OK
Found 317 tests
309 Pass
8 Fail
312 Pass
5 Fail
Pass # AUDIT TASK RUNNER STARTED.
Pass Executing "initialize"
Pass Executing "Offline createGain"
@ -318,6 +318,6 @@ Pass > [verifyTests]
Pass Number of nodes not tested : 0
Pass < [verifyTests] All assertions passed. (total 1 assertions)
Pass > [automation]
Fail X Test automations (check console logs) incorrectly threw NotSupportedError: "FIXME: Implement AudioParam::linear_ramp_to_value_at_time".
Fail < [automation] 1 out of 1 assertions were failed.
Fail # AUDIT TASK RUNNER FINISHED: 1 out of 24 tasks were failed.
Pass Test automations (check console logs) did not throw an exception.
Pass < [automation] All assertions passed. (total 1 assertions)
Pass # AUDIT TASK RUNNER FINISHED: 24 tasks ran successfully.