Skip to content
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

Remove experimental formatter warning #8148

Merged
merged 2 commits into from
Oct 24, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions crates/ruff_cli/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,6 @@ pub fn run(
}

fn format(args: FormatCommand, log_level: LogLevel) -> Result<ExitStatus> {
warn_user_once!("`ruff format` is not yet stable, and subject to change in future versions.");

let (cli, overrides) = args.partition();

if is_stdin(&cli.files, cli.stdin_filename.as_deref()) {
Expand Down
12 changes: 0 additions & 12 deletions crates/ruff_cli/tests/format.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ if condition:
print('Hy "Micha"') # Should not change quotes

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
"###);
}

Expand Down Expand Up @@ -89,7 +88,6 @@ if condition:
print('Should change quotes')

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
"###);
Ok(())
}
Expand Down Expand Up @@ -117,7 +115,6 @@ fn mixed_line_endings() -> Result<()> {
----- stdout -----

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
2 files left unchanged
"###);
Ok(())
Expand Down Expand Up @@ -187,7 +184,6 @@ OTHER = "OTHER"
2 files would be reformatted

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
"###);
Ok(())
}
Expand Down Expand Up @@ -221,7 +217,6 @@ if __name__ == '__main__':
----- stdout -----

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
"###);
Ok(())
}
Expand Down Expand Up @@ -278,7 +273,6 @@ if condition:
print('Should change quotes')

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
warning: The following rules may cause conflicts when used with the formatter: 'Q000'. To avoid unexpected behavior, we recommend disabling these rules, either by removing them from the `select` or `extend-select` configuration, or adding then to the `ignore` configuration.
"###);
Ok(())
Expand Down Expand Up @@ -360,7 +354,6 @@ def say_hy(name: str):
1 file reformatted

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
warning: The following rules may cause conflicts when used with the formatter: 'COM812', 'COM819', 'D206', 'E501', 'ISC001', 'Q000', 'Q001', 'Q002', 'Q003', 'W191'. To avoid unexpected behavior, we recommend disabling these rules, either by removing them from the `select` or `extend-select` configuration, or adding then to the `ignore` configuration.
warning: The following isort options may cause conflicts when used with the formatter: 'isort.force-single-line', 'isort.force-wrap-aliases', 'isort.lines-after-imports', 'isort.lines_between_types'. To avoid unexpected behavior, we recommend disabling these options by removing them from the configuration.
"###);
Expand Down Expand Up @@ -400,7 +393,6 @@ def say_hy(name: str):
print(f"Hy {name}")

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
warning: The following rules may cause conflicts when used with the formatter: 'COM812', 'COM819', 'D206', 'E501', 'ISC001', 'Q000', 'Q001', 'Q002', 'Q003', 'W191'. To avoid unexpected behavior, we recommend disabling these rules, either by removing them from the `select` or `extend-select` configuration, or adding then to the `ignore` configuration.
warning: The following isort options may cause conflicts when used with the formatter: 'isort.force-single-line', 'isort.force-wrap-aliases', 'isort.lines-after-imports', 'isort.lines_between_types'. To avoid unexpected behavior, we recommend disabling these options by removing them from the configuration.
"###);
Expand Down Expand Up @@ -443,7 +435,6 @@ fn test_diff() {
z = 3

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
2 files would be reformatted, 1 file left unchanged
"###);
});
Expand Down Expand Up @@ -473,7 +464,6 @@ fn test_diff_no_change() {
z = 3

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
1 file would be reformatted
"###
);
Expand Down Expand Up @@ -507,7 +497,6 @@ fn test_diff_stdin_unformatted() {
z = 3

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
"###);
}

Expand All @@ -524,6 +513,5 @@ fn test_diff_stdin_formatted() {
----- stdout -----

----- stderr -----
warning: `ruff format` is not yet stable, and subject to change in future versions.
"###);
}
Loading