Skip to content

Add script to remove experiments from tests when they have launched.#1781

Open
lrhn wants to merge 11 commits intomainfrom
retire-experiment-script
Open

Add script to remove experiments from tests when they have launched.#1781
lrhn wants to merge 11 commits intomainfrom
retire-experiment-script

Conversation

@lrhn
Copy link
Member

@lrhn lrhn commented Oct 30, 2025

Re: #1779 (comment)

I made a script to remove experiments from tests, and update the min-SDK version.

I haven't figured out how to find the matching analyzer package and update that in pubspec as well.
May need to run dart pub upgrade after running this script, or manually updating the analyzer package
to a version that supports the new language version without experiment flags.

@lrhn lrhn requested a review from munificent October 30, 2025 14:21
@lrhn
Copy link
Member Author

lrhn commented Oct 31, 2025

(Will format and remove unused members on Monday.)

@lrhn
Copy link
Member Author

lrhn commented Nov 3, 2025

Turns out the unreachable_from_main lint has false positives, so ignored for now.

@lrhn lrhn force-pushed the retire-experiment-script branch from d8dc658 to c98e937 Compare December 16, 2025 13:34
@lrhn
Copy link
Member Author

lrhn commented Dec 16, 2025

I think this can be landed.
Also Dart 3.10 has been released, so the result of running the script (#1779) can also be landed. I'll make sure it's up-to-date.

PTAL.

@lrhn
Copy link
Member Author

lrhn commented Jan 27, 2026

Ping @munificent

@lrhn
Copy link
Member Author

lrhn commented Jan 29, 2026

(Have we considered moving this package into the Dart SDK repo, so we can more easily keep them in sync?)

Copy link
Member

@munificent munificent left a comment

Choose a reason for hiding this comment

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

This is really cool! But I think it also re-invents some stuff that would be easier to reuse: arg parsing, test file parsing, and version comparison.

@lrhn
Copy link
Member Author

lrhn commented Feb 6, 2026

Uses args, pub_semver and TestFile now.

I needed to add output-functionality to TestFile (I did not want to make my own localized writing logic that had to be kept up-to-date, so it's put into the classes now.)
Maybe you can use that in update_tests.dart too.

PTAL.

@lrhn lrhn force-pushed the retire-experiment-script branch from 40d4afb to 487b8da Compare February 6, 2026 17:04
@lrhn lrhn force-pushed the retire-experiment-script branch from 487b8da to a6a022f Compare February 25, 2026 09:59
@lrhn lrhn force-pushed the retire-experiment-script branch from a6a022f to 54e3e18 Compare February 25, 2026 11:17
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.

2 participants