|
34 | 34 | from argparse import Namespace |
35 | 35 |
|
36 | 36 | CODEFLASH_LOGO: str = ( |
37 | | - f"{LF}" |
| 37 | + f"{LF}" # noqa: ISC003 |
38 | 38 | r" _ ___ _ _ " + f"{LF}" |
39 | 39 | r" | | / __)| | | | " + f"{LF}" |
40 | 40 | r" ____ ___ _ | | ____ | |__ | | ____ ___ | | _ " + f"{LF}" |
@@ -126,7 +126,8 @@ def ask_run_end_to_end_test(args: Namespace) -> None: |
126 | 126 |
|
127 | 127 |
|
128 | 128 | def should_modify_pyproject_toml() -> bool: |
129 | | - """Check if the current directory contains a valid pyproject.toml file with codeflash config |
| 129 | + """Check if the current directory contains a valid pyproject.toml file with codeflash config. |
| 130 | +
|
130 | 131 | If it does, ask the user if they want to re-configure it. |
131 | 132 | """ |
132 | 133 | from rich.prompt import Confirm |
@@ -468,7 +469,7 @@ def check_for_toml_or_setup_file() -> str | None: |
468 | 469 | return cast("str", project_name) |
469 | 470 |
|
470 | 471 |
|
471 | | -def install_github_actions(override_formatter_check: bool = False) -> None: |
| 472 | +def install_github_actions(override_formatter_check: bool = False) -> None: # noqa: FBT001, FBT002 |
472 | 473 | try: |
473 | 474 | config, config_file_path = parse_config_file(override_formatter_check=override_formatter_check) |
474 | 475 |
|
@@ -563,7 +564,7 @@ def install_github_actions(override_formatter_check: bool = False) -> None: |
563 | 564 | apologize_and_exit() |
564 | 565 |
|
565 | 566 |
|
566 | | -def determine_dependency_manager(pyproject_data: dict[str, Any]) -> DependencyManager: |
| 567 | +def determine_dependency_manager(pyproject_data: dict[str, Any]) -> DependencyManager: # noqa: PLR0911 |
567 | 568 | """Determine which dependency manager is being used based on pyproject.toml contents.""" |
568 | 569 | if (Path.cwd() / "poetry.lock").exists(): |
569 | 570 | return DependencyManager.POETRY |
@@ -641,7 +642,10 @@ def get_github_action_working_directory(toml_path: Path, git_root: Path) -> str: |
641 | 642 |
|
642 | 643 |
|
643 | 644 | def customize_codeflash_yaml_content( |
644 | | - optimize_yml_content: str, config: tuple[dict[str, Any], Path], git_root: Path, benchmark_mode: bool = False |
| 645 | + optimize_yml_content: str, |
| 646 | + config: tuple[dict[str, Any], Path], |
| 647 | + git_root: Path, |
| 648 | + benchmark_mode: bool = False, # noqa: FBT001, FBT002 |
645 | 649 | ) -> str: |
646 | 650 | module_path = str(Path(config["module_root"]).relative_to(git_root) / "**") |
647 | 651 | optimize_yml_content = optimize_yml_content.replace("{{ codeflash_module_path }}", module_path) |
@@ -877,7 +881,7 @@ def test_sort(self): |
877 | 881 | input = list(reversed(range(100))) |
878 | 882 | output = sorter(input) |
879 | 883 | self.assertEqual(output, list(range(100))) |
880 | | -""" |
| 884 | +""" # noqa: PTH119 |
881 | 885 | elif args.test_framework == "pytest": |
882 | 886 | bubble_sort_test_content = f"""from {Path(args.module_root).name}.bubble_sort import sorter |
883 | 887 |
|
|
0 commit comments