Super-linter: Black formatter weird behavior with trailing comma and multiple lines

Created on 5 Mar 2021  Â·  5Comments  Â·  Source: github/super-linter

When running black locally (default config, v20.8b1) over my file certain lines are transformed into multiple lines (3) if trailing comma is found. However, when I push to my repo and super linter is passed against the changes these exact lines would be formatted to a single line by black (with a trailing comma included). This does not make any sense to me since Black default behavior leans toward multiple lines when a trailling comma is found.

Example of file after running Black locally:
image

Example of same file as output of Super Linter
image

Is there anything I am missing here? I've run black both manually and with pre-commit, and they both yield the same results and different to super linter.

question

All 5 comments

I can attest to the same. Any solutions for this?

so the fix it

On Sun, Mar 7, 2021 at 10:50 PM Umesh Timalsina notifications@github.com
wrote:

I can attest to the same. Any solutions for this?

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/github/super-linter/issues/1309#issuecomment-792515893,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ASHBZZFA5B5RQC6PKEBMN23TCRXTNANCNFSM4YVCGNRQ
.

so the fix it
…
On Sun, Mar 7, 2021 at 10:50 PM Umesh Timalsina @.*> wrote: I can attest to the same. Any solutions for this? — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <#1309 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASHBZZFA5B5RQC6PKEBMN23TCRXTNANCNFSM4YVCGNRQ .

What do you mean?

Pinning the latest super-linter (i.e. github/[email protected]) fixed it for me.

@umesh-timalsina @rubenlopezlozoya

It seems we had a weird issue with the super-linter releases not updating correctly and pulling an older image.

That was resolved last week and should be pulling in the right binaries with better behavior...

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bbaassssiiee picture bbaassssiiee  Â·  5Comments

dshevtsov picture dshevtsov  Â·  3Comments

bazzadp picture bazzadp  Â·  3Comments

brunomartinspro picture brunomartinspro  Â·  4Comments

karfau picture karfau  Â·  4Comments