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

Generated email addresses are sometimes invalid in certain locales #1739

Closed
ST-DDT opened this issue Jan 15, 2023 · 3 comments · Fixed by #1746
Closed

Generated email addresses are sometimes invalid in certain locales #1739

ST-DDT opened this issue Jan 15, 2023 · 3 comments · Fixed by #1746
Labels
c: bug Something isn't working m: internet Something is referring to the internet module p: 1-normal Nothing urgent s: accepted Accepted feature / Confirmed bug

Comments

@ST-DDT
Copy link
Member

ST-DDT commented Jan 15, 2023

Clear and concise description of the problem

Sometimes the generated email addresses are invalid in certain locales:

There are actually two different errors here:

  • The email address contains invalid characters
  • The email address is too long

Suggested solution

  1. Replace all invalid characters
  2. Limit the length of the generated e-mail address

Alternative

No response

Additional context

(There might be a different issue with the input data as well, but the method should generate valid addresses nevertheless.)

@ST-DDT ST-DDT added c: bug Something isn't working p: 1-normal Nothing urgent s: accepted Accepted feature / Confirmed bug m: internet Something is referring to the internet module labels Jan 15, 2023
@ST-DDT ST-DDT added this to the v8.0 - Module Re-Shuffling milestone Jan 15, 2023
@Shinigami92 Shinigami92 moved this to Todo in Faker Roadmap Jan 16, 2023
@matthewmayer
Copy link
Contributor

this is probably caused by #1554 - if there's a long unicode name, the resulting fallback string will be very long. Seems email addresses are limited to 64 chars for the local part.

@ST-DDT
Copy link
Member Author

ST-DDT commented Jan 17, 2023

#1746 fixes part two of the problem.

@matthewmayer
Copy link
Contributor

matthewmayer commented Jan 17, 2023

And part 1 should also be fixed for el and fa

@github-project-automation github-project-automation bot moved this from Todo to Done in Faker Roadmap Jan 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: bug Something isn't working m: internet Something is referring to the internet module p: 1-normal Nothing urgent s: accepted Accepted feature / Confirmed bug
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants