|
4 | 4 | import os |
5 | 5 | import sys |
6 | 6 | import typing as t |
| 7 | +from pathlib import Path |
7 | 8 |
|
8 | 9 | import click |
| 10 | + |
9 | 11 | from sqlmesh import configure_logging, remove_excess_logs |
10 | 12 | from sqlmesh.cli import error_handler |
11 | 13 | from sqlmesh.cli import options as opt |
12 | 14 | from sqlmesh.cli.project_init import ( |
| 15 | + InitCliMode, |
13 | 16 | ProjectTemplate, |
14 | 17 | init_example_project, |
15 | | - InitCliMode, |
16 | 18 | interactive_init, |
17 | 19 | ) |
18 | 20 | from sqlmesh.core.analytics import cli_analytics |
19 | | -from sqlmesh.core.console import configure_console, get_console |
20 | | -from sqlmesh.utils import Verbosity |
21 | 21 | from sqlmesh.core.config import load_configs |
| 22 | +from sqlmesh.core.console import configure_console, get_console |
22 | 23 | from sqlmesh.core.context import Context |
| 24 | +from sqlmesh.utils import Verbosity |
23 | 25 | from sqlmesh.utils.date import TimeLike |
24 | 26 | from sqlmesh.utils.errors import MissingDependencyError, SQLMeshError |
25 | | -from pathlib import Path |
26 | 27 |
|
27 | 28 | logger = logging.getLogger(__name__) |
28 | 29 |
|
@@ -355,6 +356,7 @@ def evaluate( |
355 | 356 | "--append-newline", |
356 | 357 | is_flag=True, |
357 | 358 | help="Include a newline at the end of each file.", |
| 359 | + default=None, |
358 | 360 | ) |
359 | 361 | @opt.format_options |
360 | 362 | @click.pass_context |
@@ -805,7 +807,11 @@ def check_intervals( |
805 | 807 | context = ctx.obj |
806 | 808 | context.console.show_intervals( |
807 | 809 | context.check_intervals( |
808 | | - environment, no_signals=no_signals, select_models=select_model, start=start, end=end |
| 810 | + environment, |
| 811 | + no_signals=no_signals, |
| 812 | + select_models=select_model, |
| 813 | + start=start, |
| 814 | + end=end, |
809 | 815 | ) |
810 | 816 | ) |
811 | 817 |
|
@@ -1107,7 +1113,10 @@ def clean(obj: Context) -> None: |
1107 | 1113 | @error_handler |
1108 | 1114 | @cli_analytics |
1109 | 1115 | def table_name( |
1110 | | - obj: Context, model_name: str, environment: t.Optional[str] = None, prod: bool = False |
| 1116 | + obj: Context, |
| 1117 | + model_name: str, |
| 1118 | + environment: t.Optional[str] = None, |
| 1119 | + prod: bool = False, |
1111 | 1120 | ) -> None: |
1112 | 1121 | """Prints the name of the physical table for the given model.""" |
1113 | 1122 | print(obj.table_name(model_name, environment, prod)) |
|
0 commit comments