-
Notifications
You must be signed in to change notification settings - Fork 0
/
CONST_CHANGELOG.txt
1139 lines (975 loc) · 35.4 KB
/
CONST_CHANGELOG.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
This file includes migration steps for each release of c2cgeoportal.
=============
Version 2.7.0
=============
Information to know before starting the upgrade
===============================================
1. Now the simple application is the default mode for new project, to continue with the advance application
mode you also should add an attribute ``advance: true`` in your ``project.yaml`` file before starting
the upgrade.
2. All the files will be formatted with isort, Black and Prettier to be similar to the initial scaffolds.
If you have mako files in ``.html`` files Prettier will break them, to avoid that you should create
``.prettierignore`` file with:
```
*.min.js
```
And the files you want to ignore.
3. The Upgrade to the Web Components started, the authentication and the LiDAR profile are migrated.
In the desktop_alt we introduce a canvas component who manage the application layout and plug the
components through slots.
In ngeo, the sources files from contribs/gmf/src are moved in ngeo src folder.
4. When importing external WMS layers through dedicated right panel in desktop interface, now we use the URL
from Capabilities/Request/GetMap/.../OnlineResource tag instead of Service/OnlineResource tag which,
regarding WMS specification, should contain the website URL.
Main versions updates
---------------------
Node is updated from 14.19 to 16.14
Npm is updated from 6.14 to 8.5
GDAL is updated from 3.2 to 3.4
Proj is updated from 7.2 to 8.2
Python packages updates
-----------------------
New packages:
* arrow at version 1.2
* azure-core at version 1.23
* azure-identity at version 1.8
* azure-storage-blob at version 12.10
* binaryornot at version 0.4
* boto3 at version 1.21
* botocore at version 1.24
* cffi at version 1.15
* cookiecutter at version 1.7
* cryptography at version 36.0
* Cython at version 0.29
* Deprecated at version 1.2
* greenlet at version 1.1
* importlib-metadata at version 4.11
* importlib-resources at version 5.4
* jinja2-time at version 0.2
* jmespath at version 0.10
* msal at version 1.17
* msal-extensions at version 0.3
* msrest at version 0.6
* packaging at version 21.3
* portalocker at version 2.4
* poyo at version 0.5
* pycparser at version 2.21
* PyJWT at version 2.3
* python-slugify at version 6.1
* requests-oauthlib at version 1.3
* s3transfer at version 0.5
* text-unidecode at version 1.3
* tilecloud at version 1.8
* typing-extensions at version 4.1
* wrapt at version 1.14
* zipp at version 3.7
Removed packages:
* python-editor
* simplejson
Major updates:
* attrs from 20.3 to 21.4
* boltons from 20.2 to 21.0
* c2cwsgiutils from 4.1 to 5.0
* certifi from 2020.12 to 2021.10
* click from 7.1 to 8.0
* cornice from 5.0 to 6.0
* decorator from 4.4 to 5.1
* idna from 2.10 to 3.3
* iso8601 from 0.1 to 1.0
* Jinja2 from 2.11 to 3.0
* MarkupSafe from 1.1 to 2.1
* pyparsing from 2.4 to 3.0
* pyramid from 1.10 to 2.0
* pyramid-multiauth from 0.9 to 1.0
* redis from 3.5 to 4.1
* ujson from 4.0 to 5.1
* waitress from 1.4 to 2.1
Minor updates:
* alembic from 1.5 to 1.7
* Chameleon from 3.8 to 3.9
* defusedxml from 0.6 to 0.7
* dogpile.cache from 1.0 to 1.1
* GDAL from 3.2 to 3.4
* GeoAlchemy2 from 0.8 to 0.11
* graphviz from 0.16 to 0.19
* gunicorn from 20.0 to 20.1
* lingua from 4.14 to 4.15
* lxml from 4.6 to 4.8
* Mako from 1.1 to 1.2
* netifaces from 0.10 to 0.11
* oauthlib from 3.1 to 3.2
* OWSLib from 0.22 to 0.25
* passwordgenerator from 1.4 to 1.5
* pbr from 5.5 to 5.8
* psycopg2 from 2.8 to 2.9
* psycopg2-binary from 2.8 to 2.9
* pycryptodome from 3.11 to 3.14
* Pygments from 2.7 to 2.11
* pygraphviz from 1.7 to 1.9
* pyotp from 2.5 to 2.6
* pyproj from 3.0 to 3.3
* pyramid-jinja2 from 2.8 to 2.9
* pyramid-tm from 2.4 to 2.5
* pytz from 2021.1 to 2021.3
* sentry-sdk from 1.0 to 1.5
* Shapely from 1.7 to 1.8
* six from 1.15 to 1.16
* SQLAlchemy from 1.3 to 1.4
* SQLAlchemy-Utils from 0.36 to 0.38
* stevedore from 3.3 to 3.5
* zope.interface from 5.2 to 5.4
* zope.sqlalchemy from 1.3 to 1.6
Npm packages updates
--------------------
New packages:
* @babel/plugin-proposal-class-properties at version 7.16
* @babel/plugin-proposal-decorators at version 7.17
* @babel/plugin-syntax-object-rest-spread at version 7.8
* @babel/plugin-transform-spread at version 7.16
* @babel/plugin-transform-typescript at version 7.16
* @babel/preset-typescript at version 7.16
* @lit/reactive-element at version 1.3
* @sentry/integrations at version 6.18
* @sentry/types at version 6.18
* angular at version 1.8
* co at version 4.6
* console-control-strings at version 1.1
* core-js at version 3.21
* doctrine at version 3.0
* eslint-plugin-jsdoc at version 38.0
* glob at version 7.2
* i18next-browser-languagedetector at version 6.1
* i18next-parser at version 6.0
* i18next-xhr-backend at version 3.2
* i18next at version 21.6
* jquery-mousewheel at version 3.1
* jquery at version 3.6
* lit-element at version 3.2
* lit-html at version 2.2
* lit at version 2.2
* loader-utils at version 2.0
* loc-i18next at version 0.1
* ol-mapbox-style at version 7.1
* ol at version 6.12
* raw-loader at version 4.0
* regenerator-runtime at version 0.13
* rxjs at version 7.5
* sass-loader at version 10.2
* style-loader at version 2.0
* terser at version 5.12
* tsconfig-paths at version 3.14
Removed packages:
* @geoblocks/proj
* eslint-config-openlayers
* eslint-plugin-googshift
* ng-raven
Major updates:
* chokidar from 2.1 to 3.5
* commander from 7.0 to 9.0
* d3 from 5.16 to 7.3
* editorconfig-checker from 3.3 to 4.0
* eslint from 7.19 to 8.11
* fast-sass-loader from 1.5 to 2.0
* fs-extra from 9.1 to 10.0
* node-sass from 4.14 to 6.0
* npm from 6.14 to 8.5
* puppeteer from 5.5 to 13.5
* sinon from 9.2 to 13.0
* svgo-loader from 2.2 to 3.0
* svgo from 1.3 to 2.8
* ts-node from 9.1 to 10.7
Minor updates:
* @babel/core from 7.12 to 7.17
* @babel/preset-env from 7.12 to 7.16
* @sentry/browser from 6.2 to 6.18
* @sentry/tracing from 6.2 to 6.18
* css-loader from 5.0 to 5.2
* jsts from 2.6 to 2.8
* localforage from 1.9 to 1.10
* mapillary-js from 4.0 to 4.1
* proj4 from 2.7 to 2.8
* webpack-merge from 5.7 to 5.8
Information
===========
1. The configuration of the QGIS authentication module is simplified,
now a new environment variable `GEOMAPFISH_ACCESSCONTROL_BASE_URL` is set to the base URL of
qgisserver, and we search for all the OGC servers that correspond to this URL.
Then the configuration file (`qgisserver/accesscontrol_config.yaml`) and the specified configuration
in the `docker-compose.yaml` file can be removed.
It also requires that the OGC servers are configured with an URL like that
``config://qgisserver?map=<project_file>``.
2. Some little changes in the application build:
- In the ``./build`` script, we no longer call the ``docker build`` command with custom parameters,
but call the ``docker-compose build`` command with two additional environment variables:
* ``SIMPLE``: ``TRUE`` or ``FALSE`` if we compile a simple or advance application.
* ``GIT_HASH``: the git hash of the current version.
The build specification has been moved to the ``docker-compose`` files.
- The ``--geoportal`` and ``--config`` arguments have been replaced by ``--service=geoportal`` and
``--service=config`` respectively.
- The external images used in the composition are pulled from the Docker hub on each build, but the
``./build`` script supports a new argument ``--no-pull`` for faster rebuild during development.
- ``./build`` script supports a new argument ``--fast-reload`` that will recreate all containers except
Redis containers to keep the cache.
- ``./build`` script supports a new argument ``--dry-run`` which only displays the ``docker`` and
``docker-compose`` commands without running them.
3. Upgrade c2cwsgiutils to version 5, see more information in the
c2cwsgiutils changelog https://github.com/camptocamp/c2cwsgiutils/blob/master/CHANGELOG.md.
SQLAlchemy upgrade to version 1.4
---------------------------------
SQLAlchemy has been upgraded to version 1.4 which serves as potential migration point for a more dramatic
series of API changes currently planned for release 2.0 of SQLAlchemy.
For more details about SQLAlchemy 1.4 see: https://docs.sqlalchemy.org/en/14/changelog/migration_14.html
To show SQLAlchemy deprecation warnings in your geoportal container logs, add this to your
`docker-compose.override.yaml` file:
```
---
version: '2.3'
services:
geoportal:
environment:
- PYTHONWARNINGS=default::DeprecationWarning
- SQLALCHEMY_WARN_20=true
```
For more information about Python warnings configuration see: https://docs.python.org/3/library/warnings.html#describing-warning-filters
Changes to apply
================
1. For advance application:
In the ``docker-compose.yaml`` file in the service ``geoportal`` you should replace
``service: geoportal`` by ``service: geoportal-advance``, and in service ``alembic`` you should replace
``service: alembic`` by ``service: alembic-advance``.
2. If you use the LiDAR profile you didn't need anymore to include your module in the controller.
3. In the tilegeneration configuration ``on``/``off`` is no more considered as boolean, it should be
converted to ``true``/``false``, and the properties ``mapcache_internal`` and ``mapcache`` should be
removed.
4. For the LiDAR profile you should update your controller, in the interface JavaScript file:
```javascript
+ import panels from 'gmfapi/store/panels';
...
constructor($scope, $injector) {
super($scope, $injector);
...
+ const $timeout = $injector.get('$timeout');
+
+ // Open the 'web-component' lidar panel
+ $scope.$watch(
+ () => this.drawLidarprofilePanelActive,
+ (newVal) => {
+ if (newVal) {
+ panels.openToolPanel('lidar');
+ } else {
+ panels.closeToolPanel();
+ }
+ }
+ );
+
+ // Make visible the footer
+ panels.getActiveFooterPanel().subscribe({
+ next: (panel) => {
+ this.lidarProfileFooterActive = panel === 'lidar';
+ $timeout(() => {}); // this triggered on DOM click, we call $timeout to force Angular digest
+ },
+ });
...
```
You should disable map interrogations when LiDAR tool is active, if missing add the following code to the controller:
```javascript
+ import ngeoMiscToolActivate from 'ngeo/misc/ToolActivate';
+ const drawLidarprofilePanelActive = new ngeoMiscToolActivate(this, 'drawLidarprofilePanelActive');
+ this.ngeoToolActivateMgr.registerTool('mapTools', drawLidarprofilePanelActive, false);
```
The interface HTML file needs a few changes.
To activate the LiDAR panel, you should makes sure to have correct ng-model attributes:
```html
...
<button ngeo-btn class="btn btn-default" ng-model="mainCtrl.drawLidarprofilePanelActive"
data-toggle="tooltip" data-placement="left" data-original-title="{{'LiDAR'|translate}}">
<span class="fa fa-chart-line"></span>
</button>
...
```
The LiDAR panel should looks like that, where other tools panels are:
```html
...
+ <div ng-show="mainCtrl.drawLidarprofilePanelActive" class="row">
+ <div class="col-sm-12">
+ <a class="btn close gmf-close" ng-click="mainCtrl.drawLidarprofilePanelActive = false">×</a>
+ <gmf-lidar-panel></gmf-lidar-panel>
+ </div>
+ </div>
...
```
Finally the LiDAR footer in the footer balise should looks like that:
```html
<footer>
+ <gmf-lidar-footer id="lidar-footer"></gmf-lidar-footer>
<gmf-profile
gmf-profile-active="profileChartActive"
gmf-profile-line="mainCtrl.profileLine"
...
</footer>
```
5. Here is a list of the low-level components migrated as a dependency (of other migrated components):
- download/Csv
- map/FeatureOverlay
- map/FeatureOverlayMgr
- message/Message
- message/Notification
All of them use the singleton pattern, which means that in general it may only need to be initialized once (when required).
The component need to be imported with an 'import', not from the AngularJS dependency injector.
You should take care of the custom code in that regard if one of these components is used, as it's may needs some changes to be working fully.
If it is already initialized, you may need to change the code using this component in the custom component of your project.
In any case, it will be different in each project and use case.
6. To access to the config in you components, previously it was injected through Angular, now you should get
it with RXJS, with:
```javascript
import {Configuration} from 'gmfapi/store/config';
window.gmfapi.store.config.getConfig().subscribe({
next: (configuration: Configuration) => {
if (configuration) {
...
}
},
})
```
7. To solve looping dependency we moved the `Cache` and `set_common_headers` function, then you should do
in your custom Python views a modification like:
```diff
- from c2cgeoportal_geoportal.lib.caching import Cache, set_common_headers
+ from c2cgeoportal_geoportal.lib.common_headers import Cache, set_common_headers
```
=============
Version 2.6.0
=============
Information to know before starting the upgrade
===============================================
Direct dependencies updates
---------------------------
Now we are based on the image `osgeo/gdal` (`ubuntu-small-3.2.1`) which is based on Ubuntu 20.04.
Previously we were based on image `camptocamp/c2cwsgiutils` (`release_3`) which is based on Ubuntu 18.04
Main version update
-------------------
Ubuntu is updated from 18.04.5 to 20.04.1
Python is updated from 3.7.5 to 3.8.5
Node is updated from 10.24.1 to 14.17.0
Npm is updated from 6.14.12 to 6.14.13
Postgres is updated from 13+226.pgdg18.04+1 to 13+226.pgdg20.04+1
Python package update
---------------------
New packages:
* c2cwsgiutils at version 4.1.1
* GDAL at version 3.2.1
* linesman at version 0.3.2
* networkx at version 1.7
* oauthlib at version 3.1.0
* Paste at version 3.5.0
* pbr at version 5.5.1
* Pillow at version 8.1.2
* pipfile at version 0.0.2
* pkgconfig at version 1.5.1
* pygraphviz at version 1.7
* pyyaml-include at version 1.2.post2
* stevedore at version 3.3.0
* toml at version 0.10.2
Removed packages:
* importlib-metadata
* simplejson
* typing-extensions
* zipp
Major updates:
* attrs from 19.3.0 to 20.3.0
* chardet from 3.0.4 to 4.0.0
* cornice from 4.0.1 to 5.0.3
* dogpile.cache from 0.9.0 to 1.0.2
* Jinja2 from 3.0.0a1 to 2.11.3
* MarkupSafe from 2.0.0a1 to 1.1.1
* pyparsing from 3.0.0a1 to 2.4.7
* pyproj from 2.6.0 to 3.0.0.post1
* pytz from 2019.3 to 2021.1
* sentry-sdk from 0.14.3 to 1.0.0
* ujson from 2.0.3 to 4.0.2
Minor updates:
* alembic from 1.4.2 to 1.5.3
* Babel from 2.8.0 to 2.9.0
* boltons from 20.1.0 to 20.2.1
* c2c.template from 2.1.0 to 2.3.0
* cee-syslog-handler from 0.5.0 to 0.6.0
* certifi from 2020.4.5.1 to 2020.12.5
* cligj from 0.5.0 to 0.7.1
* colander from 1.7.0 to 1.8.3
* GeoAlchemy2 from 0.7.0 to 0.8.4
* idna from 2.9 to 2.10
* numpy from 1.18.3 to 1.20.0
* objgraph from 3.4.1 to 3.5.0
* OWSLib from 0.19.2 to 0.22.0
* pipenv from 2020.5.28 to 2020.11.15
* Pygments from 2.6.1 to 2.7.4
* pyotp from 2.3.0 to 2.5.1
* pyramid-debugtoolbar from 4.6.1 to 4.9
* PyYAML from 5.3.1 to 5.4.1
* rasterio from 1.1.3 to 1.2.0
* redis from 3.4.1 to 3.5.3
* requests from 2.23.0 to 2.25.1
* six from 1.14.0 to 1.15.0
* translationstring from 1.3 to 1.4
* urllib3 from 1.25.9 to 1.26.4
* zope.interface from 5.1.0 to 5.2.0
Npm package update
------------------
New packages:
* @sentry/tracing at version 6.2.3
* babel-plugin-angularjs-annotate at version 0.10.0
* eslint at version 7.19.0
* event-hooks-webpack-plugin at version 2.2.0
* mapillary-js at version 2.21.0
* tinycolor2 at version 1.4.2
Removed packages:
* @camptocamp/babel-plugin-angularjs-annotate
* jsdoc
* jsdoc-plugin-typescript
* tsconfig-paths
* typescript
Major updates:
* @sentry/browser from 5.15.4 to 6.2.3
* commander from 5.0.0 to 7.0.0
* copy-webpack-plugin from 5.1.1 to 6.4.1
* css-loader from 3.5.2 to 5.0.1
* expose-loader from 0.7.5 to 1.0.3
* html-webpack-plugin from 3.2.0 to 4.5.1
* node-sass-importer from 1.0.0 to 2.0.2
* puppeteer from 2.1.1 to 5.5.0
* ts-node from 8.8.2 to 9.1.1
* webpack-merge from 4.2.2 to 5.7.3
Minor updates:
* @babel/core from 7.9.0 to 7.12.10
* @babel/preset-env from 7.9.5 to 7.12.11
* @fortawesome/fontawesome-free from 5.13.0 to 5.15.2
* @trevoreyre/autocomplete-js from 2.1.1 to 2.2.0
* angular-animate from 1.7.9 to 1.8.2
* angular-mocks from 1.7.9 to 1.8.2
* angular-sanitize from 1.7.9 to 1.8.2
* angular-touch from 1.7.9 to 1.8.2
* babel-loader from 8.1.0 to 8.2.2
* bootstrap from 4.4.1 to 4.6.0
* d3 from 5.15.1 to 5.16.0
* ejs-loader from 0.3.6 to 0.5.0
* extract-loader from 5.0.1 to 5.1.0
* file-loader from 6.0.0 to 6.2.0
* floatthead from 2.1.4 to 2.2.1
* fs-extra from 9.0.0 to 9.1.0
* jsts from 2.1.2 to 2.6.1
* localforage from 1.7.3 to 1.9.0
* moment from 2.24.0 to 2.29.1
* node-sass from 4.13.1 to 4.14.1
* ol-layerswitcher from 3.6.0 to 3.8.3
* proj4 from 2.6.1 to 2.7.0
* sinon from 9.0.2 to 9.2.4
* terser-webpack-plugin from 4.1.0 to 4.2.3
* webpack from 4.42.1 to 4.46.0
Other Docker images
~~~~~~~~~~~~~~~~~~~
* `camptocamp/mapfish_print` from 3.22 to 3.27.
* `camptocamp/mapserver` from 7.4 to 7.6.
* `camptocamp/geomapfish-qgisserver` from 3.10 to 3.16.
* `camptocamp/redis` from 5 to 6.
* `camptocamp/tilecloud-chain` from 1.13 to 1.15.
* `camptocamp/haproxy` from 1.9 to 2.2.
Main Changes
------------
The migration process impacts the following:
1. Openlayers view has a default value set to `false` for the `constrainOnlyCenter` parameter.
Add to the vars.yaml the following config: `constrainOnlyCenter: True` to `gmfOptions/view` if required to keep 2.5 view behavior.
The migration process will also require the following UI-related changes (visible in the html diffs):
1. Right panel is movable, so the handle has to be added
2. Draw and measure panel has extra fields for arrows drawing
Note: The list presented in this chapter is not exhaustive.
Client application configuration
--------------------------------
Previous versions had configuration in the `*.html.ejs`, in the `Controler*.js`, and in the `vars.yaml` file.
The goal of this change is to move this configuration to the `vars.yaml` file (with default values in
the `CONST_vars.yaml`). This will make future upgrades easier and increase configuration possibilities
in the simple application mode, see the documentation
<https://camptocamp.github.io/c2cgeoportal/${MAIN_BRANCH}/integrator/create_application.html#simple-application>.
When you apply the `ngeo.diff` you should first apply the changes in the `geoportal/vars.yaml` file.
For the next step, you should consult the documentation about:
- The interfaces_config documentation
<https://camptocamp.github.io/c2cgeoportal/${MAIN_BRANCH}/integrator/ngeo.html?highlight=ngeo#dynamic-json-view>
- GMF constants definitions <https://camptocamp.github.io/ngeo/master/jsdoc/module-contribs_gmf_src_options.html>
- ngeo constants definitions <https://camptocamp.github.io/ngeo/master/jsdoc/module-src_options.html>
Then configure the `vars/srid`, `vars/alternate_projections`, `vars/resolutions` and `vars/extent` they will
be dispatched using `c2ctemplate` or YAML link.
In the following, we show typical examples of necessary changes:
Example in API
..............
In the ngeo.diff:
```
--- a/geoportal/cartoriviera_geoportal/static-ngeo/api/index.js
+++ b/geoportal/cartoriviera_geoportal/static-ngeo/api/index.js
...
-// The URL to the search service.
-config.searchUrl = '{FULL_ENTRY_POINT}search?interface=api&limit=15';
```
And in your `geoportal/cartoriviera_geoportal/static-ngeo/api/index.js` file:
```
// The URL to the search service.
onfig.searchUrl = '{FULL_ENTRY_POINT}search?interface=api&limit=15';
```
We see that the project settings didn't correspond to the previous default settings, therefore you should
have in your vars file something like:
```
vars:
interfaces_config:
api:
routes:
searchUrl:
params:
limit: 15
update_paths:
- interfaces_config.api.routes.searchUrl # This one should already be present
```
In this case, you need to change this line of the `update_paths` as follows:
```
update_paths:
- interfaces_config.api.routes.searchUrl.params
```
This is because the default value in the
`geoportal/CONST_vars.yaml` defines the searchUrl like this:
```
searchUrl:
name: fulltextsearch
params:
limit: 15
partitionlimit: 5
dynamic_params:
interface: interface
```
You won't redefine the whole `searchUrl` configuration you only want to set the params. The `update_paths`
Allows you to update the one part of the configuration. Without this entry in the `update_paths`, the
whole `searchUrl` configuration would have been replaced.
Example in controller constructor
.................................
In the ngeo.diff:
```
- constructor($scope, $injector) {
- super({
- srid: 2056,
- mapViewConfig: {
- center: [2632464, 1185457],
- zoom: 3,
- resolutions: [250, 100, 50, 20, 10, 5, 2, 1, 0.5, 0.25, 0.1, 0.05],
- constrainResolution: true,
- extent: [2485071.54, 175346.36, 2828515.78, 1299941.84],
- }
- }, $scope, $injector);
```
And in your `geoportal/cartoriviera_geoportal/static-ngeo/api/index.js` file:
```
constructor($scope, $injector) {
super({
maxTilesLoading: Infinity,
srid: 2056,
mapViewConfig: {
center: [2559045, 1144195],
zoom: 1,
constrainResolution: true,
resolutions: [50, 20, 10, 5, 2.5, 2, 1.5, 1, 0.5, 0.25, 0.1, 0.05, 0.025]
}
}, $scope, $injector);
```
We see that the project settings didn't correspond to the previous default settings, therefore you should
have in your vars file something like:
```
vars:
interfaces_config:
default: # or interface name
constants:
gmfOptions:
map:
maxTilesLoading: .Inf
view: &view
projection: EPSG:{srid}
center: [2559045, 1144195]
zoom: 1
resolutions: &resolutions [50, 20, 10, 5, 2.5, 2, 1.5, 1, 0.5, 0.25, 0.1, 0.05, 0.025]
extent: &extent [2420000, 1030000, 2900000, 1350000]
geolocalisation: True
```
Standard example in controller
..............................
In the ngeo.diff:
```
- this.elevationLayers = ['aster', 'srtm'];
```
And in your `geoportal/cartoriviera_geoportal/static-ngeo/api/index.js` file:
```
this.elevationLayers = ['mns', 'mnt', 'rayglobal'];
```
We see that the project settings didn't correspond to the previous default settings, therefore you should
have in your vars file something like:
```
vars:
interfaces_config:
default: # or interface name
constants:
gmfElevationOptions:
layers: [mns, mnt, rayglobal]
```
Now we can easily switch between the display of query results in a window or in a grid by using
`gmfQueryGrid` configuration variable.
Now you can easily switch between flush theme mode and non-flush theme mode by using
`gmfTreeManagerModeFlush` configuration variable.
Optional point
..............
The header can be in a separate file, diff in the `*.html.ejs` file:
- <header>
- <div class="logo">
- <span></span>
- </div>
- <div class="logo-right">
- <span></span>
- </div>
- </header>
+ <ng-include src="'desktop_alt/header.html'"></ng-include>
The content will be in the `geoportal/geomapfish_geoportal/static/header.html` file.
Print
-----
- You can now switch easily between local print and mutualised print by setting one
of `DISABLE_MUTUALIZED_PRINT` and `DISABLE_LOCAL_PRINT` environment variavle to '#' ant the other to ''.
- The client timezone is added as a new attribute named `timezone`, you can use it with e.-g.:
`java.time.ZonedDateTime.now().format(java.time.format.DateTimeFormatter
.ofPattern("EEEE dd MMMM yyyy HH:mm")
.withLocale($P{REPORT_LOCALE})
.withZone(java.time.ZoneId.of($P{timezone}))`
- If you use the most recent version of the `legend.jrxml` print template, you will obtain a legend with
elements indented hierarchically per groups level. If you want to keep the previous legend style, keep
your previous `legend.jrxml` template and add a new variable `gmfPrintOptions.legend.showGroupsTitle` in
the `interfaces_config` constants of the vars file and set it to false.
Editing
-------
- The default order column for edition enumeration lists is now the value column ("name" per
default). You can set it through the new `editingEnumerations` layer metadata.
QGIS server
-----------
- The runtime variables of the GeoMapFish configuration (geomapfish.yaml.tmpl) are now filled in the config
container, previously it was in the QGIS server container.
Tile generation
---------------
- Some commands are added to generate the OpenLayers example,
and the legend images used in the WMTS capabilities (but not used in the web application).
Redis
-----
- Redis can be used in a scalable architecture (with sentinel), this is disabled by default.
Environment
-----------
C2C_SECRET: Default value "c2crulez" has been removed for evident security reason.
Changes to apply
================
1. All ngeo components are now configured via variables in your project variables file, in the section
interfaces_config. To ease future migration, you should remove any existing custom JavaScript code which is
setting such variables.
There is some new documentation about the constants in ngeo
https://camptocamp.github.io/ngeo/2.7/apidoc/index.html.
=============
Version 2.5.0
=============
Information to know before starting the upgrade
-----------------------------------------------
Main versions updates
.....................
Ubuntu is updated from 18.04.2 to 18.04.5
Python is updated from 3.6.7 to 3.7.5
Node is updated from 10.15.3 to 10.24.1
Npm is updated from 6.4.1 to 6.14.12
Python packages updates
.......................
New packages:
* appdirs at version 1.4.4
* beaker-redis at version 1.1.0
* click at version 7.1.1
* distlib at version 0.3.2
* filelock at version 3.0.12
* getitfixed at version 1.0.20
* importlib-metadata at version 4.6.0
* pipenv at version 2020.5.28
* psycopg2 at version 2.8.5
* pyotp at version 2.3.0
* sentry-sdk at version 0.14.3
* SQLAlchemy-Utils at version 0.36.3
* typing-extensions at version 3.10.0.0
* virtualenv-clone at version 0.5.4
* zipp at version 3.4.1
Removed packages:
* alabaster
* astroid
* atomicwrites
* awscli
* beautifulsoup4
* boto3
* botocore
* c2c.cssmin
* c2cgeoportal-admin
* c2cgeoportal-commons
* c2cgeoportal-geoportal
* c2cwsgiutils
* Click
* codacy-coverage
* codespell
* colorama
* coverage
* cssmin
* dateutils
* docopt
* docutils
* entrypoints
* flake8
* flake8-copyright
* flake8-mypy
* flake8-polyfill
* GDAL
* glob2
* htmlmin
* imagesize
* ipcalc
* isort
* jmespath
* JSTools
* junit2html
* lazy-object-proxy
* linesman
* mccabe
* more-itertools
* mypy
* mypy-extensions
* networkx
* packaging
* Paste
* PasteScript
* pathspec
* pep8
* pep8-naming
* Pillow
* pkgconfig
* pluggy
* py
* pyasn1
* pycodestyle
* pyflakes
* pygraphviz
* pykwalify
* pylint
* Pympler
* pytest
* pytest-base-url
* pytest-cov
* pytest-html
* pytest-metadata
* pytest-selenium
* pytest-variables
* python-slugify
* raven
* rsa
* s3transfer
* selenium
* snowballstemmer
* Sphinx
* sphinx-prompt
* sphinxcontrib-websupport
* tilecloud
* tilecloud-chain
* transifex-client
* typed-ast
* Unidecode
* WebTest
* wrapt
* wsgi-lineprof
* yamllint
* zgitignore
Major updates:
* boltons from 19.0.0 to 20.1.0
* certifi from 2019.3.9 to 2020.4.5.1
* cornice from 3.5.1 to 4.0.1
* gunicorn from 19.9.0 to 20.0.4
* pyproj from 1.9.6 to 2.6.0
* transaction from 2.4.0 to 3.0.0
* ujson from 1.35 to 2.0.3
* venusian from 1.2.0 to 3.0.0
* virtualenv from 16.4.3 to 20.4.7
* zope.interface from 4.6.0 to 5.1.0
Minor updates:
* affine from 2.2.2 to 2.3.0
* alembic from 1.0.9 to 1.4.2
* attrs from 19.1.0 to 19.3.0
* Babel from 2.6.0 to 2.8.0
* Beaker from 1.10.1 to 1.11.0
* c2cgeoform from 2.0.dev20190413 to 2.1.18
* Chameleon from 3.6.1 to 3.8.1
* defusedxml from 0.5.0 to 0.6.0
* dogpile.cache from 0.7.1 to 0.9.0
* GeoAlchemy2 from 0.6.1 to 0.7.0
* geojson from 2.4.1 to 2.5.0
* graphviz from 0.10.1 to 0.16
* hupper from 1.6.1 to 1.10.2
* idna from 2.8 to 2.9
* Jinja2 from 2.10.1 to 2.11.3
* lingua from 4.13 to 4.14
* lxml from 4.3.1 to 4.6.3
* Mako from 1.0.9 to 1.1.2
* munch from 2.3.2 to 2.5.0
* numpy from 1.16.3 to 1.18.3
* OWSLib from 0.17.1 to 0.19.2
* PasteDeploy from 2.0.1 to 2.1.0
* pycryptodome from 3.8.1 to 3.9.7
* Pygments from 2.3.1 to 2.6.1
* pyramid from 1.9.4 to 1.10.4
* pyramid-debugtoolbar from 4.5 to 4.6.1
* pyramid-mako from 1.0.2 to 1.1.0
* pyramid-tm from 2.2.1 to 2.4
* python-dateutil from 2.6.1 to 2.8.1
* pytz from 2019.1 to 2019.3
* PyYAML from 5.1 to 5.4.1
* rasterio from 1.0.2 to 1.1.3
* redis from 3.2.1 to 3.4.1
* requests from 2.21.0 to 2.23.0
* Shapely from 1.6.4.post2 to 1.7.0
* simplejson from 3.16.0 to 3.17.2
* six from 1.11.0 to 1.14.0
* urllib3 from 1.23 to 1.25.9
* waitress from 1.2.1 to 1.4.3
* zope.sqlalchemy from 1.1 to 1.3
Npm packages updates
....................
New packages:
* @sentry/browser at version 5.15.4
* @trevoreyre/autocomplete-js at version 2.1.1
* commander at version 5.0.0
* editorconfig-checker at version 3.3.0
* jsdoc at version 3.6.4
* jsdoc-plugin-typescript at version 2.0.5
* localforage at version 1.7.3
* ng-raven at version 1.0.1
* parse-absolute-css-unit at version 1.0.2
* popper.js at version 1.16.1
* puppeteer at version 2.1.1
* qruri at version 0.0.4
* resize-observer-polyfill at version 1.5.1
* simple-html-tokenizer at version 0.5.9
* sinon at version 9.0.2
* terser-webpack-plugin at version 4.1.0
* typescript at version 3.8.3
Removed packages:
* @openlayers/eslint-plugin
* @types/angular-animate
* @types/angular-dynamic-locale
* @types/angular-gettext
* @types/angular-mocks
* @types/bootstrap
* @types/cesium