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
**_WARNING_**: Choosing huge numbers, along with a "complex" regex, could easily cause your system to freeze!
93
+
94
+
For example, if you try to generate a list of _all_ 5-letter words: `/\w{5}/.examples(max_group_results: 999)`, then - since there are actually `63` "word" characters (upper/lower case letters, numbers and "\_"), this will try to generate `63**5 #=> 992436543` (almost 1 trillion) examples!
95
+
96
+
In other words, think twice before playing around with this config!
97
+
98
+
A more sensible use case might be, for example, to generate one random 1-4 digit string: `/\d{1,4}/.examples(max_repeater_variance: 3, max_group_results: 10).sample(1)`. (Note: I may develop a much more efficient way to "generate one example" in a later release of this gem.)
99
+
66
100
## Known Bugs
67
101
68
102
There are a few obscure bugs that have yet to be resolved:
0 commit comments