Skip to content

chore(CI): Remove Biome in favour of prettier #15461

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Feb 25, 2025

Conversation

timfish
Copy link
Collaborator

@timfish timfish commented Feb 20, 2025

We never fully migrated to Biome because it didn't support all the lints we required.

Because we still have to run eslint (and prettier for some files) so there are no real gains to running Biome too.

@timfish timfish marked this pull request as ready for review February 20, 2025 19:05
@timfish timfish requested a review from a team as a code owner February 20, 2025 19:05
@timfish timfish requested a review from AbhiPrasad February 20, 2025 19:05
@AbhiPrasad
Copy link
Member

Don't we have to re-enable some eslint rules?

@timfish
Copy link
Collaborator Author

timfish commented Feb 20, 2025

The eslint config hasn't been touched much in years.

The thing that is missing is calling prettier in all the packages!

@timfish timfish marked this pull request as draft February 20, 2025 19:15
@timfish
Copy link
Collaborator Author

timfish commented Feb 20, 2025

Ok, prettier is re-enabled for TypeScript and JavaScript.

Rather than run it for each package individually which is quite slow, it follows how Biome worked and runs against the entire repository at once which is much faster.

Unfortunatly, prettier and Biome aren't identical in how they handle formatting so there are some changes to files. It seems that prettier more forcefully collapses things when they would have fitted all on one line.

This doesn't yet enable formatting for svelte, vue, and astro files but that can be enabled later.

@timfish timfish marked this pull request as ready for review February 20, 2025 19:56
@timfish timfish marked this pull request as draft February 20, 2025 20:04
@timfish timfish marked this pull request as ready for review February 20, 2025 20:40
@timfish timfish changed the title chore(CI): Remove Biome chore(CI): Remove Biome in favour of prettier Feb 20, 2025
Copy link
Member

@chargome chargome left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks Tim!

Copy link
Member

@Lms24 Lms24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Tim!

@AbhiPrasad
Copy link
Member

@timfish mind rebasing this? Lets get this merged in!

Copy link

codecov bot commented Feb 25, 2025

❌ 1 Tests Failed:

Tests completed Failed Passed Skipped
4657 1 4656 322
View the top 1 failed test(s) by shortest run time
kafkajs traces producers and consumers
Stack Traces | 18.8s run time
Error: expect(received).toMatchObject(expected)

- Expected  -  4
+ Received  + 10

@@ -1,17 +1,23 @@
  Object {
    "contexts": Object {
-     "trace": ObjectContaining {
-       "data": ObjectContaining {
+     "trace": Object {
+       "data": Object {
          "messaging.destination": "test-topic",
+         "messaging.operation": "process",
          "messaging.system": "kafka",
-         "otel.kind": "PRODUCER",
+         "otel.kind": "CONSUMER",
          "sentry.op": "message",
-         "sentry.origin": "auto.kafkajs.otel.producer",
+         "sentry.origin": "auto.kafkajs.otel.consumer",
+         "sentry.source": "route",
        },
        "op": "message",
+       "origin": "auto.kafkajs.otel.consumer",
+       "parent_span_id": "fc7494215b035c6a",
+       "span_id": "ffac23fab60dd181",
        "status": "ok",
+       "trace_id": "ba5fe03a2f7e099c793993d83feae8d3",
      },
    },
    "event_id": Any<String>,
    "spans": Any<Array>,
    "start_timestamp": Anything,
    at assertSentryTransaction (.../node-integration-tests/utils/assertions.ts:32:18)
    at expectTransactionEvent (.../node-integration-tests/utils/runner.ts:484:28)
    at newEnvelope (.../node-integration-tests/utils/runner.ts:288:15)
    at tryParseEnvelopeFromStdoutLine (.../node-integration-tests/utils/runner.ts:393:15)
    at Socket.<anonymous> (.../node-integration-tests/utils/runner.ts:411:15)
    at Socket.emit (node:events:524:28)
    at addChunk (node:internal/streams/readable:561:12)
    at readableAddChunkPushByteMode (node:internal/streams/readable:512:3)
    at Socket.Readable.push (node:internal/streams/readable:392:5)
    at Pipe.onStreamRead (node:internal/stream_base_commons:189:23)

To view more test analytics, go to the Test Analytics Dashboard
📋 Got 3 mins? Take this short survey to help us improve Test Analytics.

@AbhiPrasad AbhiPrasad merged commit 512f43c into develop Feb 25, 2025
149 checks passed
@AbhiPrasad AbhiPrasad deleted the timfish/chore/remove-biome branch February 25, 2025 15:39
@billyvg
Copy link
Member

billyvg commented Feb 25, 2025

I think there are some biome-ignore comments to clean up

Lms24 pushed a commit that referenced this pull request Feb 26, 2025
These are no longer required since  #15461
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants