Skip to content

refactor: remove panics from manifest - #456

Merged
zeroshade merged 2 commits into
apache:mainfrom
laskoviymishka:remove-panics
Jun 12, 2025
Merged

zeroshade merged 2 commits into
apache:mainfrom
laskoviymishka:remove-panics

Conversation

@laskoviymishka

Copy link
Copy Markdown
Contributor

panics in library code is a bad practice, if we can - we should prefer value err instead.

there is a plenty of panics, so i remove 2 of them (which is more natural as err values).

for the rest of code - better to fix it adhoc (1by1)

panics in library code is a bad practice, if we can - we should prefer value err instead.

there is a plenty of panics, so i remove 2 of them (which is more natural as err values).

for the rest of code - better to fix it adhoc (1by1)
@laskoviymishka laskoviymishka changed the title refactor: remove 2 panics refactor: remove panics from manifest Jun 7, 2025
@laskoviymishka
laskoviymishka marked this pull request as ready for review June 8, 2025 16:33
@zeroshade

Copy link
Copy Markdown
Member

So the primary reason for those being panics was because it was so unlikely that anything would actually hit those conditions. That said, I'm not opposed to this change

@laskoviymishka

Copy link
Copy Markdown
Contributor Author

Yes, adding assert-style panic is IMHO - OK, but we need to use this with caution, I would like to move a needle here a bit, I'll try to eliminate panics which are not impossible, and the one that is impossible made them more direct in intention (maybe wrap into some helper or so).

@zeroshade

Copy link
Copy Markdown
Member

Looks like there's just some lint stuff to fix here

@laskoviymishka

Copy link
Copy Markdown
Contributor Author

Looks like there's just some lint stuff to fix here

well, at some point i'll setup linters locally :D

@zeroshade zeroshade left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks!

@zeroshade
zeroshade merged commit d53cdeb into apache:main Jun 12, 2025
@laskoviymishka
laskoviymishka deleted the remove-panics branch April 14, 2026 07:13
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.

2 participants