Skip to content

REST API example may break due to versioning shenanigansΒ #618

Open
@ben0x539

Description

A pal just ran into this and was stumped: If you copy the first example from web/clients/api/rest-get.md into a new cargo binary project and add the latest versions of reqwest and tokio to your Cargo.toml so it builds, you panic because #[tokio::main] is coming from a different tokio than what reqwest uses, so the reqwest calls are supposedly not on a tokio runtime.

You can probably figure out what is going on from googling the error message, but I suspect someone browsing a cookbook for examples to play with may not be up for package version debugging. idk if there's a robust way to save people from this terrible fate. :(

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions