Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

489 logging changelog #526

Merged
merged 2 commits into from
Nov 27, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
- [#64](https://github.com/LayerManager/layman/issues/64) Responses of [GET Layers](doc/rest.md#get-layers), [GET Workspace Layers](doc/rest.md#get-workspace-layers), [GET Workspace Layer](doc/rest.md#get-workspace-layer), [PATCH Workspace Layer](doc/rest.md#patch-workspace-layer), [GET Maps](doc/rest.md#get-maps), [GET Workspace Maps](doc/rest.md#get-workspace-maps), [GET Workspace Map](doc/rest.md#get-workspace-map), [PATCH Workspace Map](doc/rest.md#patch-workspace-map) contains new attribute
- `native_crs` with code of native CRS in form "EPSG:<code>", e.g. "EPSG:4326"
- `native_bounding_box` with coordinates and CRS of native CRS [minx, miny, maxx, maxy, "EPSG:<code>"]
- [#489](https://github.com/LayerManager/layman/issues/489) Error responses from Micka and GeoServer are logged into log and also propagated as part of raised exception, so they can be seen from flower.

## v1.15.0
2021-11-18
Expand Down
8 changes: 4 additions & 4 deletions src/geoserver/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
logger = logging.getLogger(__name__)

FLASK_RULES_KEY = f"{__name__}:RULES"
WMS_VERSION = '1.3.0'
WFS_VERSION = '2.0.0'

RESERVED_WORKSPACE_NAMES = [
'default',
Expand Down Expand Up @@ -1025,8 +1027,7 @@ def bbox_to_native_bbox(bbox):


def wms_direct(wms_url, xml=None, version=None, headers=None):
from layman.layer.geoserver.wms import VERSION
version = version or VERSION
version = version or WMS_VERSION
try:
wms = WebMapService(wms_url, xml=xml.encode('utf-8') if xml is not None else xml, version=version, headers=headers)
except requests.exceptions.HTTPError as exc:
Expand All @@ -1037,8 +1038,7 @@ def wms_direct(wms_url, xml=None, version=None, headers=None):


def wfs_direct(wfs_url, xml=None, version=None, headers=None):
from layman.layer.geoserver.wfs import VERSION
version = version or VERSION
version = version or WFS_VERSION
try:
wfs = WebFeatureService(wfs_url, xml=xml.encode('utf-8') if xml is not None else xml, version=version, headers=headers)
except requests.exceptions.HTTPError as exc:
Expand Down
2 changes: 1 addition & 1 deletion src/layman/layer/geoserver/wfs.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
FLASK_PROXY_KEY = f'{__name__}:PROXY:{{workspace}}'

PATCH_MODE = patch_mode.DELETE_IF_DEPENDANT
VERSION = '2.0.0'
VERSION = gs_util.WFS_VERSION

get_publication_uuid = empty_method_returns_none
pre_publication_action_check = empty_method
Expand Down
2 changes: 1 addition & 1 deletion src/layman/layer/geoserver/wms.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
DEFAULT_GEOTIFF_STORE_PREFIX = 'geotiff'

PATCH_MODE = patch_mode.DELETE_IF_DEPENDANT
VERSION = '1.3.0'
VERSION = gs_util.WMS_VERSION

pre_publication_action_check = empty_method
post_layer = empty_method
Expand Down