concurrently icon indicating copy to clipboard operation
concurrently copied to clipboard

Prefix ([0] [1]) randomly missing

Open danbord opened this issue 1 year ago • 1 comments

Description: I'm usign concurrently for my azure fucntions node.js project. I need to compile my typescript and run the azure functions at the same time.

here is my package.json script "start": "concurrently --kill-others \"tsc -w\" \"func start\"",

Problem is that randomly the prefix is missing from the logs. Which misalign my data in the logs which can be pretty annoying sometimes:

image

I tried to remove the prefix (since I don't really need it) but setting it to an empty string brings back the [0] and [1]. I also tried setting it to a radom caracter like "-" but still have the same issue

Expected Behavior:

  1. Do not skip some prefix
  2. Be able to remove the prefix by setting it to empty string

Environment Node.js v18.19

danbord avatar Feb 29 '24 19:02 danbord

Thanks for the report. I'm pretty sure that your command must be writing multiple lines without a line break at the end, e.g. process.stdout.write('hello\nworld').

How this has been a bug for so long is beyond me 🤦 https://github.com/open-cli-tools/concurrently/blame/v8.2.2/src/logger.ts#L238-L239

gustavohenke avatar Apr 07 '24 10:04 gustavohenke

Hey! This is now fixed in v9.0.0. https://github.com/open-cli-tools/concurrently/releases/tag/v9.0.0

gustavohenke avatar Sep 08 '24 13:09 gustavohenke