Skip to content

Configurable global default max int value #3338

Open
@karlismelderis-mckinsey

Description

Clear and concise description of the problem

currently number.int() upper boundary is Number.MAX_SAFE_INTEGER
such values don't fit in postgres int (max 2147483647)

in our case it's acceptable to generate values with {max: 2147483647} but because a lot of faker data is auto-generated it's not easy to add max value everywhere and where it's possible it leads to repeating same configuration for .int()

Would be great if it would be possible to set global FAKER_MAX_INTEGER value

Suggested solution

add a global configuration option to override Number.MAX_SAFE_INTEGER

Alternative

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    c: featureRequest for new featurehas workaroundWorkaround provided or linkedm: numberSomething is referring to the number modulep: 1-normalNothing urgents: awaiting more infoAdditional information are requesteds: waiting for user interestWaiting for more users interested in this feature

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions