Skip to content

Conversation

@overlookmotel
Copy link
Member

@overlookmotel overlookmotel commented Apr 3, 2025

#10134 fixed the start span of Program in TS AST to align with TS-ESLint.

Change the method this is achieved by - use a custom converter instead of mutating the AST in to_estree_ts_json and to_pretty_estree_ts_json. This method is more convoluted, but I think it's preferable if serialization does not have side effect of mutating the AST.

@github-actions github-actions bot added A-ast Area - AST C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior labels Apr 3, 2025
Copy link
Member Author


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@overlookmotel overlookmotel marked this pull request as ready for review April 3, 2025 09:25
@overlookmotel overlookmotel force-pushed the 04-03-refactor_ast_estree_alter_program_start_span_with_converter branch from 9979c1a to e4d8baf Compare April 3, 2025 09:26
@codspeed-hq
Copy link

codspeed-hq bot commented Apr 3, 2025

CodSpeed Instrumentation Performance Report

Merging #10195 will degrade performances by 4.8%

Comparing 04-03-refactor_ast_estree_alter_program_start_span_with_converter (b662df4) with main (abc9ea4)

Summary

❌ 1 regressions
✅ 35 untouched benchmarks

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark BASE HEAD Change
formatter[react.development.js] 41.4 µs 43.5 µs -4.8%

@overlookmotel
Copy link
Member Author

Does not alter serialized output, so merging without review.

cc @therewillbecode FYI.

@overlookmotel overlookmotel added the 0-merge Merge with Graphite Merge Queue label Apr 3, 2025
Copy link
Member Author

overlookmotel commented Apr 3, 2025

Merge activity

@therewillbecode
Copy link
Contributor

Does not alter serialized output, so merging without review.

cc @therewillbecode FYI.

Nice one!

#10134 fixed the start span of `Program` in TS AST to align with TS-ESLint.

Change the method this is achieved by - use a custom converter instead of mutating the AST in `to_estree_ts_json` and `to_pretty_estree_ts_json`. This method is more convoluted, but I think it's preferable if serialization does not have side effect of mutating the AST.
@graphite-app graphite-app bot force-pushed the 04-03-refactor_ast_estree_alter_program_start_span_with_converter branch from e4d8baf to b662df4 Compare April 3, 2025 09:36
@graphite-app graphite-app bot merged commit b662df4 into main Apr 3, 2025
28 checks passed
@graphite-app graphite-app bot deleted the 04-03-refactor_ast_estree_alter_program_start_span_with_converter branch April 3, 2025 09:43
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Apr 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-ast Area - AST C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants