Skip to content

Migration tool incremental opt out emits incorrect version markers #44704

@leafpetersen

Description

@leafpetersen

Running the migration tool from flutter master.

I ran the tool, and chose to not migrate several files, letting the migration tool mark them as opted out. The tool produced (for certain files) the following diff:

 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
 import 'package:flutter/foundation.dart';
+
+// @dart=2.9
+
 import 'package:flutter/material.dart';

Note that the language version marker is after the first directive, which is invalid and causes it to be ignored by the tooling.

cc @stereotype441 @srawlins

Metadata

Metadata

Assignees

Labels

P1A high priority bug; for example, a single project is unusable or has many test failuresarea-migration (deprecated)Deprecated: this label is no longer actively used (was: issues with the `dart migrate` tool).

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions