Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
hsheth2 committed Jul 11, 2024
1 parent 9a1d10b commit c798c78
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion metadata-ingestion/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,6 @@
*sqlglot_lib,
"GitPython>2",
"python-liquid",
*sqlglot_lib,
}

bigquery_common = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
)
from datahub.metadata.urns import DatasetUrn
from datahub.sql_parsing.schema_resolver import SchemaResolver
from datahub.sql_parsing.sqlglot_utils import parse_statement
from datahub.sql_parsing.sqlglot_utils import get_dialect, parse_statement
from datahub.utilities import memory_footprint
from datahub.utilities.dedup_list import deduplicate_list

Expand Down Expand Up @@ -129,7 +129,7 @@ def parse_alter_table_rename(default_schema: str, query: str) -> Tuple[str, str,
Parses an ALTER TABLE ... RENAME TO ... query and returns the schema, previous table name, and new table name.
"""

parsed_query = parse_statement(query, dialect="redshift")
parsed_query = parse_statement(query, dialect=get_dialect("redshift"))
assert isinstance(parsed_query, sqlglot.exp.AlterTable)
prev_name = parsed_query.this.name
rename_clause = parsed_query.args["actions"][0]
Expand Down

0 comments on commit c798c78

Please sign in to comment.