Closed Bug 1411026 Opened 2 years ago Closed 2 years ago

geckodriver discards Marionette stacktraces

Categories

(Testing :: geckodriver, enhancement)

Version 3
enhancement
Not set

Tracking

(firefox58 fixed)

RESOLVED FIXED
mozilla58
Tracking Status
firefox58 --- fixed

People

(Reporter: ato, Assigned: ato)

References

Details

Attachments

(3 files)

Stacktraces from Marionette are discarded when the WebDriverError is
constructed in testing/geckodriver/src/marionette.rs:

> if let Some(error) = resp.error {
>     let status = self.error_from_string(&error.status);
> 
>     return Err(WebDriverError::new(status, error.message));
> }
Assignee: nobody → ato
Status: NEW → ASSIGNED
https://bugzil.la/1411045 is also relevant to this change.
Comment on attachment 8921217 [details]
Bug 1411026 - Provide String type conversion for ErrorStatus.

https://reviewboard.mozilla.org/r/192212/#review197490
Attachment #8921217 - Flags: review?(hskupin) → review+
Comment on attachment 8921218 [details]
Bug 1411026 - Rename MarionetteError::status to ::code.

https://reviewboard.mozilla.org/r/192214/#review197492

Good find!
Attachment #8921218 - Flags: review?(hskupin) → review+
Comment on attachment 8921219 [details]
Bug 1411026 - Propagate Marionette stacks to WebDriver error.

https://reviewboard.mozilla.org/r/192216/#review197494

If you could also update the geckodriver changelog that would be great and will make the release work easier.

::: testing/geckodriver/src/marionette.rs:1270
(Diff revision 2)
>      }
>  }
>  
> +impl Into<WebDriverError> for MarionetteError {
> +    fn into(self) -> WebDriverError {
> +        let status = ErrorStatus::from(self.code);

s/status/code
Attachment #8921219 - Flags: review?(hskupin) → review+
Comment on attachment 8921219 [details]
Bug 1411026 - Propagate Marionette stacks to WebDriver error.

https://reviewboard.mozilla.org/r/192216/#review197494

> s/status/code

Apparently ErrorStatus is still named “status” so I’ll keep
this around, but we should think about renaming that as well!

Not good to mix code/status/error.
Pushed by atolfsen@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/135d220e2178
Provide String type conversion for ErrorStatus. r=whimboo
https://hg.mozilla.org/integration/autoland/rev/6a24cb5cb401
Rename MarionetteError::status to ::code. r=whimboo
https://hg.mozilla.org/integration/autoland/rev/7d3f5015ac7e
Propagate Marionette stacks to WebDriver error. r=whimboo
Blocks: 1412037
You need to log in before you can comment on or make changes to this bug.