diff --git a/geocatbridge/metadata.txt b/geocatbridge/metadata.txt index ec59aa5..cf7a60a 100644 --- a/geocatbridge/metadata.txt +++ b/geocatbridge/metadata.txt @@ -14,7 +14,7 @@ about=GeoCat is pleased to offer its Bridge plugin to the QGIS community. experimental=False category=Web qgisMinimumVersion=3.16 -version=4.5.0 +version=4.5.1 email=support@geocat.net icon=icons/geocat.png tags=style, symbology, cartography, publishing, sharing, SDI, metadata, MapServer, @@ -24,7 +24,11 @@ tracker=https://github.com/GeoCat/qgis-bridge-plugin/issues repository=https://github.com/GeoCat/qgis-bridge-plugin hasProcessingProvider=yes deprecated=False -changelog=Version 4.5.0, September 2024 +changelog=Version 4.5.1, October 2024 + - Fix bridgestyle (ExpressionConverter) causing some feature styles to fail [#189] + - Remove Python warnings + + Version 4.5.0, September 2024 - Properly release resources when plugin reloads [#187] - Replaced QtWebKit related code with regular Qt UI elements [#152, #185] - Replaced PNG icons with SVG icons diff --git a/geocatbridge/publish/style/__init__.py b/geocatbridge/publish/style/__init__.py index 457b8e9..72abba5 100644 --- a/geocatbridge/publish/style/__init__.py +++ b/geocatbridge/publish/style/__init__.py @@ -1,5 +1,5 @@ import json as _json -from warnings import catch_warnings +from warnings import catch_warnings, simplefilter from typing import Dict as _Dict, List, Tuple from xml.dom import minidom from xml.etree import ElementTree as ETree @@ -96,7 +96,8 @@ def layerStyleAsSld(layer: _lyr.BridgeLayer, lowercase_props: bool = False) -> T layer_name = ETree.SubElement(named_layer, "Name") layer_name.text = layer.web_slug if hasattr(layer, 'web_slug') else layer.name() user_style = ETree.SubElement(named_layer, "UserStyle") - with catch_warnings(action="ignore", category=DeprecationWarning): + with catch_warnings(): + simplefilter("ignore", DeprecationWarning) # As title() and abstract() actually point to metadata().title() and metadata().abstract(), # (see BridgeLayer.__init__), we can suppress the deprecation warning here... props = {