From 779425010ce17ecfe867880c0ba707eed2792ef4 Mon Sep 17 00:00:00 2001 From: leendertvanwolfswinkel Date: Mon, 18 Sep 2023 19:33:12 +0200 Subject: [PATCH 1/7] Bump threedi dependencies --- CHANGES.rst | 4 +++- dependencies.py | 6 +++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 264120a8..1f2b3fc4 100755 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -5,7 +5,9 @@ ThreeDiToolBox changelog 2.5.5 (unreleased) ------------------ -- Nothing changed yet. +- Bump threedigrid to 2.0.* +- Bump threedi-modelchecker to 2.3.* +- Bump threedigrid-builder to 1.12.* 2.5.4 (2023-07-20) diff --git a/dependencies.py b/dependencies.py index 6f93ccad..8c178093 100644 --- a/dependencies.py +++ b/dependencies.py @@ -50,9 +50,9 @@ Dependency("GeoAlchemy2", "geoalchemy2", "==0.13.*", False), Dependency("lizard-connector", "lizard_connector", "==0.7.3", False), Dependency("pyqtgraph", "pyqtgraph", ">=0.13.2", False), - Dependency("threedigrid", "threedigrid", ">=2.0.3", False), + Dependency("threedigrid", "threedigrid", ">=2.0.*", False), Dependency("threedi-schema", "threedi_schema", "==0.217.*", False), - Dependency("threedi-modelchecker", "threedi_modelchecker", "==2.2.*", False), + Dependency("threedi-modelchecker", "threedi_modelchecker", "==2.3.*", False), Dependency("threedidepth", "threedidepth", "==0.6.1", False), Dependency("click", "click", ">=8.0", False), Dependency("alembic", "alembic", "==1.8.*", False), @@ -71,7 +71,7 @@ Dependency("networkx", "networkx", "", False), Dependency("condenser", "condenser", ">=0.2.1", False), Dependency("Shapely", "shapely", ">=2.0.0", False), - Dependency("threedigrid_builder", "threedigrid_builder", ">=1.11.4", False), + Dependency("threedigrid_builder", "threedigrid_builder", ">=1.12.*", False), Dependency("hydxlib", "hydxlib", "==1.5.1", False), Dependency("h5netcdf", "h5netcdf", "", False), Dependency("greenlet", "greenlet", "!=0.4.17", False), From a77373e8e6ce1988c4ecdd656dfe095a18cda9ec Mon Sep 17 00:00:00 2001 From: Arjan Verkerk Date: Tue, 19 Sep 2023 10:19:28 +0200 Subject: [PATCH 2/7] Add download links for threedigrid_builder==1.12.1. --- external-dependencies/populate.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/external-dependencies/populate.sh b/external-dependencies/populate.sh index ab521146..ea44f439 100755 --- a/external-dependencies/populate.sh +++ b/external-dependencies/populate.sh @@ -62,15 +62,15 @@ wget https://files.pythonhosted.org/packages/cd/84/66072ee12c3e79061f183c09a24be wget https://files.pythonhosted.org/packages/43/10/ead321694ef6adf0717ca4b3a7d4cf5b52e8456cc35c2b82abbd3777fd06/cftime-1.5.0-cp39-none-win_amd64.whl wget https://files.pythonhosted.org/packages/92/2e/8a85d66cd4646a81027f3efbc17278beaa86fd351b5f1339a7a5b0d79c14/netCDF4-1.5.4-cp39-cp39-win_amd64.whl#sha256=223b84f8d2a148e889b1933944109bdecbefc097200ab42e8a66c967b1398e1b wget https://files.pythonhosted.org/packages/b2/8e/83d9e3bff5c0ff7a0ec7e850c785916e616ab20d8793943f9e1d2a987fab/shapely-2.0.0-cp39-cp39-win_amd64.whl -wget https://files.pythonhosted.org/packages/23/8a/3dbc65fae7a4364c00df2c26a552fb6be4fdc71758b3d8b34502031d8cca/threedigrid_builder-1.11.4-cp39-cp39-win_amd64.whl#sha256=d5625545b148b8694607fcdb7ea89b77af8d95f006212f8b35116d29887a4933 +wget https://files.pythonhosted.org/packages/ae/8f/432412eadf4441519e3b7b94e7c53f542a5500f5a0c12aa3e16fd5e6bd07/threedigrid_builder-1.12.1-cp39-cp39-win_amd64.whl#sha256=0dd01a1a4fa33d7434858c90f4e54157afe163d334b63bbcdc9c7f9df048063e wget https://files.pythonhosted.org/packages/b3/89/1d3b78577a6b2762cb254f6ce5faec9b7c7b23052d1cdb7237273ff37d10/greenlet-2.0.2-cp39-cp39-win_amd64.whl#sha256=db1a39669102a1d8d12b57de2bb7e2ec9066a6f2b3da35ae511ff93b01b5d564 # Download linux wheels (both cp38 and cp310) wget https://files.pythonhosted.org/packages/44/51/bc9d47beee47afda1d335f05efa848dc403bd183344f03d431281518e8ab/cftime-1.5.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl#sha256=7a820e16357dbdc9723b2059f7178451de626a8b2e5f80b9d91a77e3dac42133 wget https://files.pythonhosted.org/packages/06/07/0700e5e33c44bc87e19953244c29f73669cfb6f19868899170f9c7e34554/shapely-2.0.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl wget https://files.pythonhosted.org/packages/4e/03/f3bcb7d96aef6d56b62e2f25996f161c05f92a45d452165be2007b756e0f/shapely-2.0.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl -wget https://files.pythonhosted.org/packages/3e/e5/ced7142226e2b2814b35318e0b9715da7a63f13274aa2e3949e37d2f416c/threedigrid_builder-1.11.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl#sha256=6f3d5bc788cc03d5baa7f55b8df9c78dfda8868db03f2099b69f9668330278ff -wget https://files.pythonhosted.org/packages/ce/59/6fd7a8a52856c85c1e860765c4181723895bfd8ab7aa20180b7e03a4ce0b/threedigrid_builder-1.11.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl#sha256=caa0c54d841b9899f101b254f71b58a31d460ae75fc2a71111b3f68a185f0602 +wget https://files.pythonhosted.org/packages/dc/20/bc17c88f5353e78b4e2a9832cc7a6560f5367b8ae657c08e80d3059c1b41/threedigrid_builder-1.12.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl#sha256=ea6270902886a99c89789e31f851cac8d217bf8dbc33f8c2de35d2c30946cc74 +wget https://files.pythonhosted.org/packages/36/2b/532a1482b307b5cb8efca69aa0c1fddfe01015ffde1fbf16bfebddc92926/threedigrid_builder-1.12.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl#sha256=6647ccc1e360af1a6673c4a7d0a2981d46254c82e11df2efce7c2e56927e703c wget https://files.pythonhosted.org/packages/6e/11/a1f1af20b6a1a8069bc75012569d030acb89fd7ef70f888b6af2f85accc6/greenlet-2.0.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl#sha256=d75209eed723105f9596807495d58d10b3470fa6732dd6756595e89925ce2470 wget https://files.pythonhosted.org/packages/7c/5f/ee39d27a08ae6b93f14faa953a6593dad888df75ae55ff479135e64ad4fe/greenlet-2.0.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl#sha256=acd2162a36d3de67ee896c43effcd5ee3de247eb00354db411feb025aa319857 From 9400eca2a8949dfcf77b9b7f4879982f5809c07b Mon Sep 17 00:00:00 2001 From: Arjan Verkerk Date: Tue, 19 Sep 2023 10:42:53 +0200 Subject: [PATCH 3/7] Flake8. --- models/base_fields.py | 2 +- tool_sideview/utils.py | 2 +- utils/qprojects.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/models/base_fields.py b/models/base_fields.py index 6a7cf294..6567afa5 100644 --- a/models/base_fields.py +++ b/models/base_fields.py @@ -61,7 +61,7 @@ def value(self, value): :return: new value of field row """ if self.field.field_type == CHECKBOX_FIELD: - if type(value) == bool: + if isinstance(value, bool): self._set_value(value) elif value == Qt.Checked: self._set_value(True) diff --git a/tool_sideview/utils.py b/tool_sideview/utils.py index 13064407..d556ae7e 100644 --- a/tool_sideview/utils.py +++ b/tool_sideview/utils.py @@ -66,7 +66,7 @@ def split_line_at_points( polyline.transform(transform) for point in point_features: - if type(point) == QgsFeature: + if isinstance(point, QgsFeature): point = { point_feature_id_field: point[point_feature_id_field], "geom": point.geometry(), diff --git a/utils/qprojects.py b/utils/qprojects.py index a056c74b..c1db513b 100644 --- a/utils/qprojects.py +++ b/utils/qprojects.py @@ -262,7 +262,7 @@ def save_setting_to_project(self, tool_name, key, value_list): name = self.get_tool_state_name(tool_name) - if type(value) == float: + if isinstance(value, float): QgsProject.instance().writeEntryDouble(name, key, value) else: if name in self.file_dict: From 2191655d4c45534e66a1e5320e290244f95ec8a3 Mon Sep 17 00:00:00 2001 From: leendertvanwolfswinkel Date: Tue, 19 Sep 2023 15:06:24 +0200 Subject: [PATCH 4/7] Update dependencies.py --- dependencies.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dependencies.py b/dependencies.py index 8c178093..667a124f 100644 --- a/dependencies.py +++ b/dependencies.py @@ -52,7 +52,7 @@ Dependency("pyqtgraph", "pyqtgraph", ">=0.13.2", False), Dependency("threedigrid", "threedigrid", ">=2.0.*", False), Dependency("threedi-schema", "threedi_schema", "==0.217.*", False), - Dependency("threedi-modelchecker", "threedi_modelchecker", "==2.3.*", False), + Dependency("threedi-modelchecker", "threedi_modelchecker", "==2.4.*", False), Dependency("threedidepth", "threedidepth", "==0.6.1", False), Dependency("click", "click", ">=8.0", False), Dependency("alembic", "alembic", "==1.8.*", False), From 9b13fed7d7c83678d5a86d17871abe8c7d10b1f0 Mon Sep 17 00:00:00 2001 From: leendertvanwolfswinkel Date: Tue, 19 Sep 2023 15:10:18 +0200 Subject: [PATCH 5/7] Update CHANGES.rst --- CHANGES.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGES.rst b/CHANGES.rst index 1f2b3fc4..ee9d9d5a 100755 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -6,7 +6,7 @@ ThreeDiToolBox changelog ------------------ - Bump threedigrid to 2.0.* -- Bump threedi-modelchecker to 2.3.* +- Bump threedi-modelchecker to 2.4.* - Bump threedigrid-builder to 1.12.* From 0101967d5b56231f1472b83b73d132915bdf935e Mon Sep 17 00:00:00 2001 From: Ben van Basten Date: Wed, 20 Sep 2023 11:04:42 +0200 Subject: [PATCH 6/7] Fixed threedigrid requirement --- dependencies.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dependencies.py b/dependencies.py index 667a124f..c370a411 100644 --- a/dependencies.py +++ b/dependencies.py @@ -50,7 +50,7 @@ Dependency("GeoAlchemy2", "geoalchemy2", "==0.13.*", False), Dependency("lizard-connector", "lizard_connector", "==0.7.3", False), Dependency("pyqtgraph", "pyqtgraph", ">=0.13.2", False), - Dependency("threedigrid", "threedigrid", ">=2.0.*", False), + Dependency("threedigrid", "threedigrid", "==2.0.*", False), Dependency("threedi-schema", "threedi_schema", "==0.217.*", False), Dependency("threedi-modelchecker", "threedi_modelchecker", "==2.4.*", False), Dependency("threedidepth", "threedidepth", "==0.6.1", False), From 3e703379468821d5b20691d33eb18d34e70f7d6a Mon Sep 17 00:00:00 2001 From: Ben van Basten Date: Wed, 20 Sep 2023 11:11:52 +0200 Subject: [PATCH 7/7] fixed another requirement --- dependencies.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dependencies.py b/dependencies.py index c370a411..d70814a0 100644 --- a/dependencies.py +++ b/dependencies.py @@ -71,7 +71,7 @@ Dependency("networkx", "networkx", "", False), Dependency("condenser", "condenser", ">=0.2.1", False), Dependency("Shapely", "shapely", ">=2.0.0", False), - Dependency("threedigrid_builder", "threedigrid_builder", ">=1.12.*", False), + Dependency("threedigrid_builder", "threedigrid_builder", "==1.12.*", False), Dependency("hydxlib", "hydxlib", "==1.5.1", False), Dependency("h5netcdf", "h5netcdf", "", False), Dependency("greenlet", "greenlet", "!=0.4.17", False),