Comments (4)
hmmm, seems like the fake library ("github.com/icrowley/fake") I have been using via fake.DigitN(1)
sometimes return 0
which make the null paragraphs my bad
If you change it to like this might help to overcome the problem, RandomInt picks random value b/w 1 & 5
// Random Paragraphs
func RandomParagraphs() string {
n := RandomInt(1, 5)
return fake.ParagraphsN(n)
}
@janpio do you want to open a pull request on that change I have provided above over here (https://github.com/pivotal-gss/mock-data/blob/master/randomizer.go#L139)
from mock-data.
Ok sure. Give me a bit.
Update: #19
from mock-data.
Possibly same problem:
time="2020-02-28 14:35:32" level=debug msg="Removing constraints for table: \"public\".\"users\"" file="constraintsBackup.go:96"
time="2020-02-28 14:35:32" level=debug msg="Extracting constraint info for table: \"public\".\"users\"" file="sql.go:314"
Mocking Table "public"."users" 30% [==============> ] (3/10) [0s:0s]
time="2020-02-28 14:35:34" level=debug msg="Table: \"public\".\"users\"" file="worker.go:168"
time="2020-02-28 14:35:34" level=debug msg="Copy Statement: COPY \"public\".\"users\"(\"id\",\"name\",\"handle\",\"created_at\",\"updated_at\") FROM STDIN WITH CSV DELIMITER '$' QUOTE e'\\x01'" file="worker.go:169"
time="2020-02-28 14:35:34" level=debug msg="Data: 5a919733-cf47-4e7b-a6c9-47a0219298b1$dolores natus ut fugiat. architecto adipisci non ea non doloribus. qui eos recusandae aliquam quia accusamus expedita voluptate eveniet magnam tempore. culpa maxime nobis! magnam illo enim soluta fuga veniam est et eveniet.\tmodi doloremque minus impedit voluptatem voluptatem voluptatem! asperiores molestias placeat! odit consequatur sit quia quia quidem. enim accusantium facere amet fugit ipsam doloribus numquam. iste culpa ea. quas in rem accusamus deleniti temporibus quos. eos esse et eum. impedit eaque aut laboriosam eum id. nihil asperiores aut hic facilis occaecati.\tvelit dolor nam dicta suscipit. ex libero maiores vero suscipit. ducimus qui voluptatem quod et rerum. repellat aut sapiente sed. omnis error iure soluta laudantium. doloremque sint non id est. eos eaque dolor doloremque distinctio earum.\tsunt id dolore ipsa est cumque cupiditate culpa repellat omnis. sed maxime ipsum pariatur aut voluptatem. qui quaerat expedita est ad doloribus nesciunt. quod quae repudiandae quo.\tut rerum recusandae. eum consectetur optio ut.$$2028-06-23 02:57:57$2017-10-25 16:43:38" file="worker.go:170"
time="2020-02-28 14:35:34" level=fatal msg="Error during committing data: ERROR #23502 null value in column \"handle\" violates not-null constraint" file="worker.go:171"
for schema https://github.com/prisma/database-schema-examples/blob/master/postgres/basic-twitter/schema.sql
from mock-data.
Ok, for these schemas it happens every time now so is not usable :/ Will wait for merge and release then
from mock-data.
Related Issues (20)
- Strategies to avoid constraint creation would fails? HOT 5
- [2.3] Encountered error when getting constraints for table \"public\".\"AO_0A5972_NOTIFICATION_SETTING\" from database, err: ERROR #42602 invalid name syntax HOT 13
- Possibly missing quotes for schema in "Extracting the column information from postgres database for table" step HOT 1
- Loop for "Fixing the Primary / Unique Key" HOT 2
- Error during committing data: ERROR #2201W LIMIT must not be negative HOT 3
- Error when execute the query to extract pk violators: ERROR #42601 syntax error at or near \"FROM\" HOT 13
- Error when updating the foreign key for table \"public\".\"jbid_io_attr\", err: ERROR #22P02 invalid input syntax for type bigint: \"\" HOT 4
- Error during committing data: ERROR #54000 index row requires 828856 bytes, maximum size is 8191 HOT 9
- Error during committing data: ERROR #42883 function periode_exist(text, integer) does not exist HOT 2
- Error when updating the foreign key for table \"public\".\"film_actor\", err: ERROR #23502 null value in column \"film_id\" violates not-null constraint HOT 8
- Error when updating the foreign key for table \"public\".\"baseball_action_pitches\", err: ERROR #22P02 invalid input syntax for type integer: \"\" HOT 12
- Stop showing progress bar on Debug HOT 1
- Run all those constraints HOT 1
- More information in debug output `Fixing the Primary / Unique Key` HOT 2
- Encountered error when connecting to the database, err: FATAL #28000 SSL connection is required. Please specify SSL options and retry HOT 4
- SSL mode verify-ca not supported HOT 4
- 同学,您这个项目引入了201个开源组件,存在2个漏洞,辛苦升级一下 HOT 1
- mock can't connect to db - dial tcp 127.0.0.1:5432: connect: connection refused HOT 5
- Error during execute custom command with two relateds tables HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mock-data.