Open andk opened 8 years ago
I think CPAN::Meta::Requirements should be able to (more gracefully) reject non-compliant version strings in all of the APIs that take them (using the validation regex in CPAN::Meta::Validator::version
).
What would "more gracefully" mean?
Throwing an exception like it currently does seems like the appropriate behavior to me. CPAN::Meta::Requirements->new
also accepts a bad_version_hook
option to do custom conversions on non-compliant versions.
This came to me a bit surprising. I cannot say whether it is a bug or feature. In my code I did not use eval and learned that I need it when I want to survive lax versions.