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

Adding Support for UUID Type #737

Closed
wants to merge 2 commits into from
Closed

Conversation

Jiraiya43
Copy link

This pull request introduces support for UUID (Universally Unique Identifier) types within your application.

@shalvah
Copy link
Contributor

shalvah commented Sep 29, 2023

I'm not sold on this. We try to restrict ourselves to the most common primitive data types, not subtypes. If we add a uuid type, what's stopping us from adding an ip type, or an email type?

@Jiraiya43
Copy link
Author

In fact, when I submitted the PR, I had the same thought. However, I thought that rather than restrict the options, we could use Faker as a generator and stick to the types it offers. What particularly frustrated me was that when I renamed the field to "uuid", it generated an example UUID, but when I set the type to "uuid", an example"string" type was provided instead.

@shalvah
Copy link
Contributor

shalvah commented Nov 21, 2023

That's an interesting proposal. Will need to consider it some more.

@shalvah
Copy link
Contributor

shalvah commented Jun 17, 2024

In fact, when I submitted the PR, I had the same thought. However, I thought that rather than restrict the options, we could use Faker as a generator and stick to the types it offers. What particularly frustrated me was that when I renamed the field to "uuid", it generated an example UUID, but when I set the type to "uuid", an example"string" type was provided instead.

I know it's been a while, but this is a good idea, and I could get behind it if you want to implement it. Esssentially:

  • you can use any type provided by Faker
  • Scribe will use that as a hint to generate the correct example

Closing this PR and making an issue from that.

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

Successfully merging this pull request may close these issues.

None yet

3 participants