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

Avoid unnecessary Capabilities requests #88

Merged
merged 1 commit into from
May 27, 2024

Conversation

gacarrillor
Copy link
Contributor

While parsing Opendata Swiss responses, we have a too broad condition (if "wms" in url.lower()) leading the plugin to go for resources like:

Title: WMS-Layer als Hintergrundkarten laden
Url: https://www.envidat.ch/dataset/seilaplan-tutorial-wms-layer-als-hintergrundkarten-laden/resource/18d13f78-0149-42bc-b962-fdd7bd972e4d
format: SERVICE

After this broad condition, I see there might be a code block with a wrong indentation, which makes the plugin always go for the resource (whose content in this case is malformed, thus the exception) as a WMS Capabilities resource, even if the resource didn't match another condition to be treated as a Capabilities one.

I guess it's a matter of fixing the indentation of this block to only perform the Capabilities request if it did match the aforementioned condition.

Fix #83

@3nids 3nids merged commit 4ced33a into opengisch:master May 27, 2024
2 checks passed
@3nids
Copy link
Member

3nids commented May 27, 2024

good catch

@gacarrillor gacarrillor deleted the fix_83 branch May 27, 2024 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Exceptions appear in QGIS Python console selecting locator search results
2 participants