You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug Faker().date().birthday() is returning the invalid date February 29, 1959.
Theory: Today's day is February 19, 2024 so birthday() must not be account for leap days
Exception Thrown
Invalid date 'February 29' as '1959' is not a leap year
java.time.DateTimeException: Invalid date 'February 29' as '1959' is not a leap year
at java.base/java.time.LocalDate.create(Unknown Source)
at java.base/java.time.LocalDate.of(Unknown Source)
at java.base/java.time.LocalDateTime.of(Unknown Source)
at net.datafaker.providers.base.DateAndTime.birthday(DateAndTime.java:258)
at net.datafaker.providers.base.DateAndTime.birthday(DateAndTime.java:233)
To Reproduce
Call Faker().date().birthday() on February 19, 2024
Expected behavior
Function should return only valid days
Versions:
OS: OSX 14.2.1
JDK OpenJDK 17.0.7
Faker Version 1.8.1
Additional context
Platform: Android
The text was updated successfully, but these errors were encountered:
Describe the bug
Faker().date().birthday()
is returning the invalid date February 29, 1959.Theory: Today's day is February 19, 2024 so
birthday()
must not be account for leap daysException Thrown
To Reproduce
Call
Faker().date().birthday()
on February 19, 2024Expected behavior
Function should return only valid days
Versions:
Additional context
Platform: Android
The text was updated successfully, but these errors were encountered: