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

PB-1131: add warning when loading http resource #1123

Merged
merged 3 commits into from
Nov 14, 2024

Conversation

ltkum
Copy link
Contributor

@ltkum ltkum commented Nov 8, 2024

Issue: When importing an external layer through an http source, we didn't give a warning to the user.

Fix: If the resource can be loaded, and the scheme is only http, we give a warning so the user know he should use https resources.

Test link

Copy link

cypress bot commented Nov 8, 2024

web-mapviewer    Run #3812

Run Properties:  status check passed Passed #3812  •  git commit f2c5138ce9: PB-1131: rebase-friendly translations
Project web-mapviewer
Branch Review fix-PB-1131-add-warning-when-loading-http-resource
Run status status check passed Passed #3812
Run duration 04m 38s
Commit git commit f2c5138ce9: PB-1131: rebase-friendly translations
Committer Martin Künzi
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 21
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 212
View all changes introduced in this branch ↗︎

@ltkum ltkum force-pushed the fix-PB-1131-add-warning-when-loading-http-resource branch from 0574b2d to 6c988bf Compare November 12, 2024 10:51
Copy link
Contributor

@pakb pakb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you only add/edit i18n keys related to your specific work?
the next PRs will thank you for not creating a rebase hell 😉

Issue: When importing an external layer through an http source, we didn't give a warning to the user.

Fix: If the resource can be loaded, and the scheme is only http, we give a warning so the user know he should use https resources.
- adding a dispatcher to the warning message dispatch
- removing unused translation params
- changing regex to only look at the first instance of http(s) to see if this is a http resource.
@ltkum ltkum force-pushed the fix-PB-1131-add-warning-when-loading-http-resource branch from 6c988bf to 6d7f777 Compare November 14, 2024 13:45
@ltkum ltkum merged commit 3f7d4c3 into develop Nov 14, 2024
6 checks passed
@ltkum ltkum deleted the fix-PB-1131-add-warning-when-loading-http-resource branch November 14, 2024 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants