Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Choose sanitizing behavior of max_len #27

Open
thombashi opened this issue Sep 10, 2022 · 1 comment
Open

Choose sanitizing behavior of max_len #27

thombashi opened this issue Sep 10, 2022 · 1 comment
Milestone

Comments

@thombashi
Copy link
Owner

thombashi commented Sep 10, 2022

For now, sanitizing functions will trim the trailing string when the byte length exceeds the max_len.
This behavior may not be preferable in some cases.
Make it possible to choose the behavior of sanitizing when a byte length of the value exceeds max_len and change the default behavior.

Choices of behavior:

  • KEEP: do nothing
  • TRIM: trim the trailing string (current default)
  • TRIM_NAME: trim the trailing string except for the file extension
  • ERROR: raise an exception (new default)
@thombashi thombashi added this to the V4 milestone Aug 12, 2023
@exislow
Copy link

exislow commented Apr 21, 2024

This function would be awesome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants