From 78c2d0983313157c62db069404792d182b586d3b Mon Sep 17 00:00:00 2001 From: Hongbo Miao <3375461+hongbo-miao@users.noreply.github.com> Date: Tue, 10 Dec 2024 02:05:05 -0800 Subject: [PATCH] chore(git): ignore .duckdb (#21417) --- .dockerignore | 1 + .gitignore | 1 + .markdownlint-cli2.jsonc | 1 + .prettierignore | 1 + .rubocop.yml | 1 + .ruff.toml | 1 + .solhintignore | 1 + .sqlfluffignore | 1 + .stylelintignore | 1 + .yamllint.yaml | 1 + api-node/eslint.config.mjs | 1 + .../hm-prefect/workflows/calculate/.prefectignore | 1 + .../hm-prefect/workflows/greet/.prefectignore | 1 + .../workflows/print-platform/.prefectignore | 1 + data-storage/hm-duckdb/src/main.py | 2 +- .../grafana/hm-panel-plugin/eslint.config.js | 1 + .../iads-config-reader/src/main.py | 15 +++++++-------- ethereum/eslint.config.mjs | 1 + mobile/mobile-react-native/eslint.config.mjs | 1 + web-cypress/eslint.config.mjs | 1 + web/eslint.config.mjs | 1 + 21 files changed, 27 insertions(+), 9 deletions(-) diff --git a/.dockerignore b/.dockerignore index 4237833f13..cd9e47a9e9 100644 --- a/.dockerignore +++ b/.dockerignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/.gitignore b/.gitignore index d0761121e6..46076ac3ab 100644 --- a/.gitignore +++ b/.gitignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local # **/.gitkeep diff --git a/.markdownlint-cli2.jsonc b/.markdownlint-cli2.jsonc index 7f5b1b3e7f..5f79251393 100644 --- a/.markdownlint-cli2.jsonc +++ b/.markdownlint-cli2.jsonc @@ -25,6 +25,7 @@ "**/*.tfstate", "**/*.unsealed.yaml", "**/.DS_Store", + "**/*.duckdb", "**/.env.development.local", "**/.env.production.local", "**/.gitkeep", diff --git a/.prettierignore b/.prettierignore index 99b38980a6..c9b765d4b3 100644 --- a/.prettierignore +++ b/.prettierignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/.rubocop.yml b/.rubocop.yml index f4182915c3..364e05ff04 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -21,6 +21,7 @@ AllCops: - '**/*.tfstate' - '**/*.unsealed.yaml' - '**/.DS_Store' + - '**/*.duckdb' - '**/.env.development.local' - '**/.env.production.local' - '**/.gitkeep' diff --git a/.ruff.toml b/.ruff.toml index db2d5a6404..d540e71385 100644 --- a/.ruff.toml +++ b/.ruff.toml @@ -17,6 +17,7 @@ exclude = [ "**/*.tfstate", "**/*.unsealed.yaml", "**/.DS_Store", + "**/*.duckdb", "**/.env.development.local", "**/.env.production.local", "**/.gitkeep", diff --git a/.solhintignore b/.solhintignore index 0b5a729dab..4b3cad97c3 100644 --- a/.solhintignore +++ b/.solhintignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/.sqlfluffignore b/.sqlfluffignore index a140cf5091..6de45b1612 100644 --- a/.sqlfluffignore +++ b/.sqlfluffignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/.stylelintignore b/.stylelintignore index 09eae5ff10..57f11bf886 100644 --- a/.stylelintignore +++ b/.stylelintignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/.yamllint.yaml b/.yamllint.yaml index 0e3e3a915d..869e6732bf 100644 --- a/.yamllint.yaml +++ b/.yamllint.yaml @@ -21,6 +21,7 @@ ignore: | **/*.tfstate **/*.unsealed.yaml **/.DS_Store + **/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/api-node/eslint.config.mjs b/api-node/eslint.config.mjs index 22372887d0..674d79ae6d 100644 --- a/api-node/eslint.config.mjs +++ b/api-node/eslint.config.mjs @@ -30,6 +30,7 @@ export default [ '**/*.tfstate', '**/*.unsealed.yaml', '**/.DS_Store', + '**/*.duckdb', '**/.env.development.local', '**/.env.production.local', '**/.gitkeep', diff --git a/data-orchestration/hm-prefect/workflows/calculate/.prefectignore b/data-orchestration/hm-prefect/workflows/calculate/.prefectignore index fdfc280f7c..928ccfe804 100644 --- a/data-orchestration/hm-prefect/workflows/calculate/.prefectignore +++ b/data-orchestration/hm-prefect/workflows/calculate/.prefectignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/data-orchestration/hm-prefect/workflows/greet/.prefectignore b/data-orchestration/hm-prefect/workflows/greet/.prefectignore index fdfc280f7c..928ccfe804 100644 --- a/data-orchestration/hm-prefect/workflows/greet/.prefectignore +++ b/data-orchestration/hm-prefect/workflows/greet/.prefectignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/data-orchestration/hm-prefect/workflows/print-platform/.prefectignore b/data-orchestration/hm-prefect/workflows/print-platform/.prefectignore index fdfc280f7c..928ccfe804 100644 --- a/data-orchestration/hm-prefect/workflows/print-platform/.prefectignore +++ b/data-orchestration/hm-prefect/workflows/print-platform/.prefectignore @@ -16,6 +16,7 @@ **/*.tfstate **/*.unsealed.yaml **/.DS_Store +**/*.duckdb **/.env.development.local **/.env.production.local **/.gitkeep diff --git a/data-storage/hm-duckdb/src/main.py b/data-storage/hm-duckdb/src/main.py index 3b80a399cb..7ac4806ad4 100644 --- a/data-storage/hm-duckdb/src/main.py +++ b/data-storage/hm-duckdb/src/main.py @@ -24,7 +24,7 @@ def save_to_duckdb(df: pd.DataFrame, db_path: str) -> None: def query_from_duckdb(db_path: str, age: int) -> list[tuple[str, int]]: with duckdb.connect(db_path) as conn: return conn.execute( - "SELECT name, age FROM people WHERE age > ?", [age] + "select name, age from people where age > ?", [age] ).fetchall() diff --git a/data-visualization/grafana/hm-panel-plugin/eslint.config.js b/data-visualization/grafana/hm-panel-plugin/eslint.config.js index cd000c2e20..d957b9fe8c 100644 --- a/data-visualization/grafana/hm-panel-plugin/eslint.config.js +++ b/data-visualization/grafana/hm-panel-plugin/eslint.config.js @@ -23,6 +23,7 @@ module.exports = [ '**/*.tfstate', '**/*.unsealed.yaml', '**/.DS_Store', + '**/*.duckdb', '**/.env.development.local', '**/.env.production.local', '**/.gitkeep', diff --git a/data-visualization/iads/iads-data-manager/iads-config-reader/src/main.py b/data-visualization/iads/iads-data-manager/iads-config-reader/src/main.py index 23d256c0da..f34c2d80d7 100644 --- a/data-visualization/iads/iads-data-manager/iads-config-reader/src/main.py +++ b/data-visualization/iads/iads-data-manager/iads-config-reader/src/main.py @@ -9,20 +9,20 @@ def show_version_from_file(iads_config: Any, iads_config_path: Path) -> None: try: version = iads_config.VersionFromFile(iads_config_path) - logging.info(f"Version from file: {version}") + logging.info(f"{version = }") except Exception as e: - logging.error(f"Could not get version from {iads_config_path}: {e}") + logging.error(f"{iads_config_path = }, {e = }") def execute_query(iads_config: Any, query: str) -> None: try: - logging.info(f"Executing: {query}") + logging.info(f"{query = }") results: list[Any] | None = iads_config.Query(query) if results: for result in results: - logging.info(f"Result: {result}") + logging.info(f"{result = }") except Exception as e: - logging.error(f"Query failed: {e}") + logging.error(f"{e = }") def process_config(iads_config_path: Path) -> None: @@ -34,14 +34,13 @@ def process_config(iads_config_path: Path) -> None: show_version_from_file(iads_config, iads_config_path) iads_config.Open(iads_config_path, True) - # Execute queries execute_query(iads_config, "select * from Desktops") execute_query(iads_config, "select System.RowNumber from Desktops") execute_query(iads_config, "select Parameter from ParameterDefaults") iads_config.Close(True) except Exception as e: - logging.error(f"Error occurred: {e}") + logging.error(f"{e = }") finally: # Clean up COM resources if iads_config: @@ -50,10 +49,10 @@ def process_config(iads_config_path: Path) -> None: def main() -> None: - logging.basicConfig(level=logging.INFO) iads_config_path = Path("pfConfig") process_config(iads_config_path) if __name__ == "__main__": + logging.basicConfig(level=logging.INFO) main() diff --git a/ethereum/eslint.config.mjs b/ethereum/eslint.config.mjs index 145e0084e4..a5acdeeff8 100644 --- a/ethereum/eslint.config.mjs +++ b/ethereum/eslint.config.mjs @@ -28,6 +28,7 @@ export default [ '**/*.tfstate', '**/*.unsealed.yaml', '**/.DS_Store', + '**/*.duckdb', '**/.env.development.local', '**/.env.production.local', '**/.gitkeep', diff --git a/mobile/mobile-react-native/eslint.config.mjs b/mobile/mobile-react-native/eslint.config.mjs index ecb01027c8..3f1b527b45 100644 --- a/mobile/mobile-react-native/eslint.config.mjs +++ b/mobile/mobile-react-native/eslint.config.mjs @@ -29,6 +29,7 @@ export default [ '**/*.tfstate', '**/*.unsealed.yaml', '**/.DS_Store', + '**/*.duckdb', '**/.env.development.local', '**/.env.production.local', '**/.gitkeep', diff --git a/web-cypress/eslint.config.mjs b/web-cypress/eslint.config.mjs index ae8cdf34ef..c9707a9e9e 100644 --- a/web-cypress/eslint.config.mjs +++ b/web-cypress/eslint.config.mjs @@ -28,6 +28,7 @@ export default [ '**/**.tfstate', '**/**.unsealed.yaml', '**/.DS_Store', + '**/*.duckdb', '**/.env.development.local', '**/.env.production.local', '**/.gitkeep', diff --git a/web/eslint.config.mjs b/web/eslint.config.mjs index b084f8809c..059061e920 100644 --- a/web/eslint.config.mjs +++ b/web/eslint.config.mjs @@ -35,6 +35,7 @@ export default [ '**/*.tfstate', '**/*.unsealed.yaml', '**/.DS_Store', + '**/*.duckdb', '**/.env.development.local', '**/.env.production.local', '**/.gitkeep',