I'm trying to get my front-end to work on docker on the last day, and I narrowed down some irregular behavior on eslint-watch and docker. I restored the minimum working repo of the error that I encountered.
It seems that linting is somehow hit when using docker-compose ( docker-compose up in particular, docker-compose run seems to work fine). Rather, the last console log entries are staggered. I'm not sure what it is, but from my reading the best interpretation I can give is that the log messages that need to be printed for iteration, for some reason, do not exit the node message queue.
I narrowed down the printing of the message in the eslint watcher file. If I add more console logs at the end of this method, it crosses out the listing, but it breaks my logs (i.e., Recent logs in execution). It's funny if I save again, it clears the remaining message queue, that is, previous logs are printed.
To replicate, download my repo, run docker-compose up and edit the test.js file and save. Follow the logs in your terminal for listing. You will see what I mean.
I hope this is quite descriptive, this is a really strange mistake and hard to explain in the question.
Any ideas how I can figure this out?
source share