From affa5f79766fddc7910bff6c43546a7fd89631b7 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 4 Apr 2023 00:20:12 +0000 Subject: [PATCH 1/2] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/pre-commit-hooks: v4.3.0 → v4.4.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.3.0...v4.4.0) - [github.com/psf/black: 22.8.0 → 23.3.0](https://github.com/psf/black/compare/22.8.0...23.3.0) - [github.com/pycqa/isort: 5.10.1 → 5.12.0](https://github.com/pycqa/isort/compare/5.10.1...5.12.0) - [github.com/pycqa/flake8: 5.0.4 → 6.0.0](https://github.com/pycqa/flake8/compare/5.0.4...6.0.0) --- .pre-commit-config.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 146a6e2..8091948 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -2,7 +2,7 @@ exclude: "node_modules|migrations|.venv|tests/dev/|tests/fixtures/|presentations fail_fast: false repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.3.0 + rev: v4.4.0 hooks: - id: check-added-large-files args: ["--maxkb=500"] @@ -18,18 +18,18 @@ repos: args: [--markdown-linebreak-ext=md] - repo: https://github.com/psf/black - rev: 22.8.0 + rev: 23.3.0 hooks: - id: black - repo: https://github.com/pycqa/isort - rev: 5.10.1 + rev: 5.12.0 hooks: - id: isort args: ["--profile", "black", "--filter-files"] - repo: https://github.com/pycqa/flake8 - rev: 5.0.4 + rev: 6.0.0 hooks: - id: flake8 language: python From f47fc8f4c3958e4f5b73ed49856b50081c7fa1de Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 4 Apr 2023 00:21:31 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- docs/conf.py | 1 + gml_application_schema_toolbox/core/load_gml_as_xml.py | 1 - gml_application_schema_toolbox/gui/database_widget.py | 2 +- gml_application_schema_toolbox/gui/import_gmlas_panel.py | 1 - gml_application_schema_toolbox/model_dialog.py | 3 --- 5 files changed, 2 insertions(+), 6 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index dc3c7c4..dd5f919 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -108,6 +108,7 @@ # -- Options for Sphinx API doc ---------------------------------------------- + # run api doc def run_apidoc(_): from sphinx.ext.apidoc import main diff --git a/gml_application_schema_toolbox/core/load_gml_as_xml.py b/gml_application_schema_toolbox/core/load_gml_as_xml.py index 312a2d4..f691f82 100644 --- a/gml_application_schema_toolbox/core/load_gml_as_xml.py +++ b/gml_application_schema_toolbox/core/load_gml_as_xml.py @@ -604,7 +604,6 @@ def _create_layer(self, geom_type: str, srid, attributes, title, tag): def _add_properties_to_layer( self, layer, xml_uri, is_remote, attributes, geom_mapping ): - tag = layer.customProperty("tag") fn = "{}_{}.gpkg".format(self.output_local_file, tag) qgs_layer = QgsVectorLayer("{}|layername=meta".format(fn), "meta", "ogr") diff --git a/gml_application_schema_toolbox/gui/database_widget.py b/gml_application_schema_toolbox/gui/database_widget.py index bf8bb78..9803620 100644 --- a/gml_application_schema_toolbox/gui/database_widget.py +++ b/gml_application_schema_toolbox/gui/database_widget.py @@ -412,7 +412,7 @@ def get_foreign_keys(self) -> List[str]: results = conn.executeSql(sql) except QgsProviderConnectionException as err: self.log(message=err, log_level=2, push=True) - for (layer_name, field_name, child_layer, child_pkid) in results: + for layer_name, field_name, child_layer, child_pkid in results: foreign_keys.append( ForeignKey( table=layer_name, diff --git a/gml_application_schema_toolbox/gui/import_gmlas_panel.py b/gml_application_schema_toolbox/gui/import_gmlas_panel.py index 753239e..f4fcd21 100644 --- a/gml_application_schema_toolbox/gui/import_gmlas_panel.py +++ b/gml_application_schema_toolbox/gui/import_gmlas_panel.py @@ -166,7 +166,6 @@ def on_loadLayersButton_clicked(self): self.unsetCursor() def validate(self): - data_source = self.gmlas_datasource() if data_source is None: diff --git a/gml_application_schema_toolbox/model_dialog.py b/gml_application_schema_toolbox/model_dialog.py index 271d765..42d69cc 100644 --- a/gml_application_schema_toolbox/model_dialog.py +++ b/gml_application_schema_toolbox/model_dialog.py @@ -53,7 +53,6 @@ class ModelDialog(QGraphicsView): - tableSelected = pyqtSignal(str) def __init__(self, model, parent=None): @@ -97,7 +96,6 @@ def spiral_iterator(): class TableWidget(QWidget): - linkActivated = pyqtSignal(str) def __init__(self, table): @@ -202,7 +200,6 @@ def enable_link_item(item): class ModelDialogScene(QGraphicsScene): - tableSelected = pyqtSignal(str) def __init__(self, model, parent):