Skip to content

Conversation

@acarl005
Copy link
Contributor

This PR removes some panicking code paths from the directwrite wrappers.

It builds off of servo/dwrote-rs#62 to consume the new fallible methods that result Results instead of panicking. Note that it needs a version bump in the Cargo.toml once that is published.

I also have servo/dwrote-rs#63 open so I can migrate more calls if that one lands.

@mrobinson mrobinson changed the title remove some panics from directwrite methods Avoid panics when calling into dwrote Mar 10, 2025
@mrobinson
Copy link
Member

I think this will also need to bump the version of dwrote used when the new one is released.

Copy link
Member

@mrobinson mrobinson left a comment

Choose a reason for hiding this comment

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

Please increase the dwrote dependency version (might require a new release there) and also update the commit title to match the new PR title.

@acarl005 acarl005 force-pushed the andy/fallible-directwrite-1 branch from 3372aeb to 2978461 Compare March 23, 2025 13:58
@acarl005
Copy link
Contributor Author

I've updated the commit message per the new title. I don't think there's a published version with the required changes, so I've updated the Cargo.toml to point to a git revision for the moment.

@jdm
Copy link
Member

jdm commented Mar 23, 2025

Waiting on servo/dwrote-rs#65 so I can publish a new version.

@jdm
Copy link
Member

jdm commented Mar 26, 2025

dwrote 0.11.3 is on crates.io.

@jdm jdm dismissed mrobinson’s stale review March 29, 2025 20:39

Addressed.

@jdm jdm enabled auto-merge March 29, 2025 20:39
@jdm jdm added this pull request to the merge queue Mar 29, 2025
Merged via the queue into servo:main with commit 30dae22 Mar 29, 2025
4 checks passed
acarl005 added a commit to warpdotdev/font-kit that referenced this pull request Sep 26, 2025
* Avoid panics when calling into dwrote

* bump dwrote version

* migrate another method call
acarl005 added a commit to warpdotdev/font-kit that referenced this pull request Sep 26, 2025
…ssertions-panicking

Avoid panics when calling into `dwrote` (servo#260)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants