{"action":"closed","issue":{"url":"https://api.github.com/repos/tgriesser/knex/issues/2972","repository_url":"https://api.github.com/repos/tgriesser/knex","labels_url":"https://api.github.com/repos/tgriesser/knex/issues/2972/labels{/name}","comments_url":"https://api.github.com/repos/tgriesser/knex/issues/2972/comments","events_url":"https://api.github.com/repos/tgriesser/knex/issues/2972/events","html_url":"https://github.com/tgriesser/knex/issues/2972","id":394053139,"node_id":"MDU6SXNzdWUzOTQwNTMxMzk=","number":2972,"title":"Feature Request: seed:run should print the file name of the failing seed","user":{"login":"Wintereise","id":5137170,"node_id":"MDQ6VXNlcjUxMzcxNzA=","avatar_url":"https://avatars3.githubusercontent.com/u/5137170?v=4","gravatar_id":"","url":"https://api.github.com/users/Wintereise","html_url":"https://github.com/Wintereise","followers_url":"https://api.github.com/users/Wintereise/followers","following_url":"https://api.github.com/users/Wintereise/following{/other_user}","gists_url":"https://api.github.com/users/Wintereise/gists{/gist_id}","starred_url":"https://api.github.com/users/Wintereise/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Wintereise/subscriptions","organizations_url":"https://api.github.com/users/Wintereise/orgs","repos_url":"https://api.github.com/users/Wintereise/repos","events_url":"https://api.github.com/users/Wintereise/events{/privacy}","received_events_url":"https://api.github.com/users/Wintereise/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-12-25T22:29:23Z","updated_at":"2018-12-27T17:20:14Z","closed_at":"2018-12-27T17:20:14Z","author_association":"NONE","body":"# Environment\r\n\r\nKnex version: 0.15.2\r\nDatabase + version: PostgreSQL 10.6\r\nOS: Ubuntu Linux\r\n\r\n# Feature discussion / request\r\n\r\n1. Why\r\n\r\nWhen `seed:run` is called and something goes wrong (perhaps due to a DB constraint), Knex does NOT print which exact seed file the issue happened in. This leaves you with a wild goose chase.\r\n\r\n2. Explain what kind of feature would support this\r\n\r\nSimply printing the file the error was generated while running + db + table-name would likely be plenty.\r\n\r\n3. Give some API proposal, how the feature should work\r\n\r\nSee above.\r\n\r\n# Demonstration\r\n\r\n```\r\nλ  knex seed:run\r\nerror: 値は型character varying(64)としては長すぎます\r\n    at Connection.parseE (G:\\xen\\manager\\node_modules\\pg\\lib\\connection.js:554:11)\r\n    at Connection.parseMessage (G:\\xen\\manager\\node_modules\\pg\\lib\\connection.js:379:19)\r\n    at Socket.<anonymous> (G:\\xen\\manager\\node_modules\\pg\\lib\\connection.js:119:22)\r\n    at emitOne (events.js:116:13)\r\n    at Socket.emit (events.js:211:7)\r\n    at addChunk (_stream_readable.js:263:12)\r\n    at readableAddChunk (_stream_readable.js:250:11)\r\n    at Socket.Readable.push (_stream_readable.js:208:10)\r\n    at TCP.onread (net.js:607:20)\r\n```\r\n\r\nFrom the above output, you really can't tell which one of my 20+ seed files this actually happened in (or which field for that matter). All it says is that the length validation failed in one of my many VARCHAR fields with length set to 64.\r\n\r\nThis issue is largely the same for the MySQL2 driver as well, and feels like something that should be addressed in core knex.\r\n\r\n"}}
{"actor":{"display_login":"kibertoad"}}