Skip to content

New Release v1.9.0 - #minor#692

Merged
ltshb merged 75 commits intomasterfrom
develop
Mar 7, 2024
Merged

New Release v1.9.0 - #minor#692
ltshb merged 75 commits intomasterfrom
develop

Conversation

@ltshb
Copy link
Contributor

@ltshb ltshb commented Mar 6, 2024

pakb and others added 30 commits March 1, 2024 17:19
so that this values do not extend above 360 (or bellow -360). This was resulting in some e2e test flakiness when a 360 deg would sometimes be interpreted as 360, and other times 0.
With this change, it will be way more predictable and consistent
When changing the config (opacity, visibility) of an external layer (KML, GPX,
WMS or WMTS) and then use the browser history navigation to revert the changes,
it triggered a reload of the layer and set its name back to the default until
the layer has been reloaded.

We can simply avoid this by updating the current layer object instead of
creating a new one.
PB-322: Avoid reloading external layer upon browser history navigation
and deconstruct its content when called, should shorten most calls to constructors that were using many default/blank/null values to reach one last argument and set it to something else

Adding the updateDelay param to GeoJson layer (it will be relevant only relevant for this type of layers)
calculated once and for all at layer creation
we had once some attributes that were getThisId or someUrl, and other that used getThisID and someURL...
I thought it would be easier to navigate all this if we sticked to a single way of naming thing, hence the move to baseUrl instead of baseURL
hopefully it is a bit clearer what this is about with this name
checking that what has been deconstructed from the single Object entry is sufficient to go on building the instance.

Also moving the timeConfig directly in GeoAdminLayer, so that it may be set to any kind of layer (will be useful in the future) and add layer config parsing of hasLegend
OL features getId was caught by my IDE as I hadn't enabled case sensitivity... So this reverts all .getId() being replaced by .id on OL features
A couple tests also slipped by when renaming baseURL to baseUrl
And finally there was a little mistake in how kmlMetadata was handled when loading a legacy KML
set default attribution to false across the board, and either fail if none is given (for GeoAdmin layers) or create a default one based on the host for externals
So, in essence, attributions are mandatory for GeoAdmin layers, and optional for externals

change LayerLegend and GroupOfLayers to also be based on an args constructor
In the legacy viewer the layer title was part of the URL and some layer
could contain a coma in its title which broke the layers parsing as the layers
in URL are separated by coma.
In the WMS we can add a group of layer form the base of the capabilities.
Legacy external WMS layer name could contain comma, therefore added a comma
to the unit tests.

On the other hand new url don't contains anymore the layer name in the url.

Also the legacy WMTS url did not contain the layer name therefore remove it from
the test
The base layer was not parsed, so added a unit test to cover this.
PB-102: Fix legacy external layers with coma in layer tilte
When loading the menu as async componenent, it adds a kind of race condition
when toggling in 3d mode for the first time making the application crash.

So avoid this race condition by keeping the menu module within the index
chunk.

NOTE: I did not track down the race condition to understand what was really
the issue.PB.2559: Fix toggling in 3d race condition
PB-259: Manual chunks for better startup performance
This is a 1 to 1 rewrite of the infobox module, switching it to
composition API. Since we're going to change some logical lines within
this file, it stands to reason to change it.

The 'scrollTo' doesn't seem to work, but it's the same as in the current
implementation.
pakb and others added 16 commits March 6, 2024 08:43
upgrade to OL v9.0.0 and update other libs
and waiting on the animation of the menu to finish before giving the caller the control back (should alleviate some race condition we had with menu open/close and action triggered just after the call to the util)
…test_utils

Replace the single clickOnMenuIfMobile by two open/close utils
Avoid loading multiple times the WMS/WMTS capabilities and avoid doing multiple
dispatch.

This reduce the startup time especially with multiple layers of the same source
we can gain several seconds.
Make sure that that the layers coming from different urls and when adding more than
one layer from a provider that the get capabilities is not called several times.

Also make sure that the correct layer config is applied.
The layer id and also URL could contains specials characters ;,@| that are used
by the parsing. So we need to encode them. They are encoded using percent encode.

Other special characters are encoded by vue router.
The test now test the initial loading of several layers and make sure that
the Get Capabilities are called only once
External layer that did not specified its opacity in URL could not be displayed
as they default opacity was set to undefined. This has been broken with PR #677
The list of layer was inverted in the test.
PB-259, PB-329: Improve external WMS/WMTS layers startup performance
When exiting the drawing, we could have a race condition between the closing
save and pending debounced save. Sometimes a pending debounce save, not started
was started after the closing and closing save, which saved an empty kml because
the drawing layer would have been removed.

This was making some test failing time to time and could also have been an
issue for a real user if he would close the drawing too quickly.
Fix save drawing race condition
The logic has two issues, one is that for group of layers we counted always
one index too much, and that for the on top of all layers we did not took the
group of layers into account.

This solve the issues in the e2e tests for the external layers.
@ltshb ltshb requested a review from pakb March 6, 2024 11:00
@github-actions github-actions bot changed the title new release New Release v1.9.0 - #minor Mar 6, 2024
@cypress
Copy link

cypress bot commented Mar 6, 2024

Passing run #954 ↗︎

0 167 22 0 Flakiness 0

Details:

Merge pull request #686 from geoadmin/feat-PB-244-coordinate-display-css-styling...
Project: web-mapviewer Commit: 1008b1a7e7
Status: Passed Duration: 05:34 💡
Started: Mar 7, 2024 6:24 AM Ended: Mar 7, 2024 6:29 AM

Review all test suite changes for PR #692 ↗︎

ltshb and others added 7 commits March 7, 2024 05:57
Apparently the debouncing of the feature title and description in drawing together
with the save drawing debouncing creates a race condition when editing the title
and/or description and closing the drawing mode. In this case the save kml
triggered by the title/description update debounced happens only when the
drawing mode is closed and when the drawing layer has removed all its
feature which result to saving an empty drawing, clearing the existing drawing.

To avoid this we speed up debouncing, this is not a perfect fix but it works
and I could not find a way of correctly cleaning up the debouncing for
the closing drawing menu event.
PB-341: Fix race condition in drawing e2e tests
@rebert rebert self-requested a review March 7, 2024 06:40
Copy link
Contributor

@rebert rebert left a comment

Choose a reason for hiding this comment

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

LGTM

@ltshb ltshb merged commit 66bd988 into master Mar 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants