LemmyNet / lemmy

🐀 A link aggregator and forum for the fediverse
https://join-lemmy.org
GNU Affero General Public License v3.0
13.3k stars 882 forks source link

Removing a few expects from production and test code. #5193

Closed dessalines closed 2 weeks ago

dessalines commented 2 weeks ago

There are still a few expects in production code, but this removes a few of the more obvious ones.

dessalines commented 2 weeks ago

K fixed a lot of the issues above.

Nutomic commented 2 weeks ago

Would be good if you can set the lint expect_used to deny.

dessalines commented 2 weeks ago

I'll try, but iirc there are a lot of cases I couldn't figure out the correct way to do.

Nutomic commented 2 weeks ago

True there are a lot. One option would be to annotate those places with #[expect(clippy::expect_used)]

dessalines commented 2 weeks ago

I'll do that now.