cli icon indicating copy to clipboard operation
cli copied to clipboard

Do not hide migrations log as they run

Open kiwicopple opened this issue 4 years ago • 1 comments

Chore

Describe the chore

Here is a video that shows some migrations running:

https://user-images.githubusercontent.com/10214025/150527243-411c0728-2157-4173-a248-0d70de1147d9.mov

There is an error on one of the files - but I don't know which one because the migration log disappears and then just shows the error. (I can keep a very close eye on the files to see which one it is, but it would be better to know for sure)

Would we be able to print all the files to the terminal as they are being run? Or at the very least, print the last one that is run before the error occurs

kiwicopple avatar Jan 21 '22 12:01 kiwicopple

Hmm yeah, error reporting could be improved here by also printing which migration file and more context from psql. One litmus test would be: you should know where the error is by reading stdout logs when using the CLI in a CI job.

soedirgo avatar Jan 21 '22 14:01 soedirgo

Closing this ticket as the CLI now prints migration logs to stderr instead of diseappearing.

There's a slight problem with making logs pretty on windows #514 which we will fix separately.

sweatybridge avatar Oct 14 '22 07:10 sweatybridge