CS-SI / eodag

Earth Observation Data Access Gateway
https://eodag.readthedocs.io
Apache License 2.0
316 stars 44 forks source link

fix(server): correct STAC collection generation #1278

Closed alambare closed 2 weeks ago

alambare commented 2 months ago
github-actions[bot] commented 2 months ago

Test Results

    4 files  ±0      4 suites  ±0   6m 14s :stopwatch: ±0s   555 tests ±0    552 :white_check_mark: ±0    3 :zzz: ±0  0 :x: ±0  2 220 runs  ±0  2 118 :white_check_mark: ±0  102 :zzz: ±0  0 :x: ±0 

Results for commit 1d9d5b2a. ± Comparison against base commit 97b7b6f8.

:recycle: This comment has been updated with latest results.

github-actions[bot] commented 2 months ago

badge

Code Coverage (Ubuntu)

``` Filename Stmts Miss Cover Missing ----------------------------------------- ------- ------ ------- ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- __init__.py 8 0 100.00% cli.py 303 50 83.50% 654-700, 802-853, 857 config.py 367 27 92.64% 82-84, 93, 101, 105-107, 184, 196, 469-471, 535-538, 585-586, 595-596, 705, 774-779, 781 crunch.py 5 5 0.00% 20-24 api/__init__.py 0 0 100.00% api/core.py 758 74 90.24% 640, 684-687, 725, 762, 792, 840, 844-849, 875, 971, 1054, 1191, 1281-1293, 1333, 1335, 1363, 1367-1378, 1391-1397, 1487-1490, 1523-1543, 1599, 1616-1619, 1631-1634, 1656-1663, 1989, 2022-2028, 2295, 2299-2302, 2316-2318, 2353 api/search_result.py 51 4 92.16% 75, 84, 91, 105 api/product/__init__.py 6 0 100.00% api/product/_assets.py 48 5 89.58% 80, 157, 167, 170-174 api/product/_product.py 187 20 89.30% 70-72, 242-243, 325, 354, 415, 429-432, 445, 469-472, 515-521 api/product/metadata_mapping.py 675 81 88.00% 131-133, 234, 266-267, 313-314, 324-336, 338, 349, 355-367, 412-413, 450, 471-474, 497, 505-506, 582-583, 607-608, 614-617, 632-633, 782, 828, 1002-1007, 1138, 1152-1172, 1192, 1197, 1307, 1329, 1343, 1356-1375, 1414, 1466, 1504-1508, 1527 api/product/drivers/__init__.py 6 0 100.00% api/product/drivers/base.py 6 1 83.33% 41 plugins/__init__.py 0 0 100.00% plugins/base.py 21 2 90.48% 48, 55 plugins/manager.py 130 12 90.77% 105-110, 160, 201, 223, 227, 253, 292-293 plugins/apis/__init__.py 0 0 100.00% plugins/apis/base.py 4 0 100.00% plugins/apis/ecmwf.py 91 8 91.21% 150-152, 199-200, 226-228 plugins/apis/usgs.py 180 31 82.78% 132, 233, 267, 302-304, 309, 335-336, 341, 371-378, 389-394, 416-422, 424-430, 453 plugins/authentication/__init__.py 6 1 83.33% 31 plugins/authentication/aws_auth.py 19 0 100.00% plugins/authentication/base.py 17 2 88.24% 34, 47 plugins/authentication/generic.py 14 2 85.71% 40, 50 plugins/authentication/header.py 19 0 100.00% plugins/authentication/keycloak.py 46 4 91.30% 132, 156-161 plugins/authentication/oauth.py 13 7 46.15% 32-34, 38-41 plugins/authentication/openid_connect.py 183 17 90.71% 119, 133-158, 166, 320-323, 347 plugins/authentication/qsauth.py 34 1 97.06% 83 plugins/authentication/sas_auth.py 47 1 97.87% 76 plugins/authentication/token.py 88 16 81.82% 79, 107, 109, 131-143, 198-202 plugins/authentication/token_exchange.py 35 19 45.71% 74-80, 92-120 plugins/crunch/__init__.py 0 0 100.00% plugins/crunch/base.py 10 1 90.00% 40 plugins/crunch/filter_date.py 59 14 76.27% 51-56, 70, 79, 88, 91, 103-105, 114-116, 123 plugins/crunch/filter_latest_intersect.py 47 8 82.98% 51-52, 71, 80-83, 85, 92-95 plugins/crunch/filter_latest_tpl_name.py 31 1 96.77% 87 plugins/crunch/filter_overlap.py 66 18 72.73% 28-30, 72-75, 82-85, 91, 99, 110-126 plugins/crunch/filter_property.py 30 7 76.67% 58-63, 66-67, 83-87 plugins/download/__init__.py 0 0 100.00% plugins/download/aws.py 489 163 66.67% 273, 286, 353-356, 370-374, 420-422, 426, 460-461, 467-471, 504, 539, 543, 550, 580-588, 592, 630-638, 645-647, 688-762, 780-841, 852-857, 873-886, 915, 930-932, 935, 945-953, 961-974, 984-1015, 1022-1034, 1075, 1101, 1146-1148, 1368 plugins/download/base.py 253 51 79.84% 145, 180, 319-320, 340-346, 377-381, 387-388, 432, 435-449, 461, 465, 538-542, 572-573, 581-598, 605-613, 615-619, 666, 688, 710, 718 plugins/download/creodias_s3.py 17 9 47.06% 44-58 plugins/download/http.py 534 129 75.84% 203-215, 217-218, 253-256, 320-323, 325-326, 333-338, 356-371, 388-390, 402, 450, 457-463, 481, 495, 509, 517-519, 535-540, 551, 569, 611-615, 637, 677, 722, 736-742, 778-842, 860, 893-902, 928-929, 956-961, 967, 970, 986, 1003-1004, 1034-1035, 1042, 1104-1110, 1165-1166, 1172, 1182, 1218, 1254, 1272-1288, 1314-1316 plugins/download/s3rest.py 116 24 79.31% 121, 157, 164, 199, 229-236, 239-241, 245, 258-264, 272-273, 276-280, 303, 324-327 plugins/search/__init__.py 22 0 100.00% plugins/search/base.py 128 9 92.97% 104, 108, 121, 271, 291, 350-351, 371, 380 plugins/search/build_search_result.py 181 23 87.29% 97, 141-142, 148, 159, 295-298, 327, 384-401, 463, 466, 476, 493, 521, 523 plugins/search/cop_marine.py 197 47 76.14% 55, 63-65, 71-72, 88, 90, 93, 128-130, 142-143, 183-192, 196, 199, 203, 221, 251, 255, 270, 274, 278, 282, 286-290, 296-299, 302-316, 333, 356, 359, 365 plugins/search/creodias_s3.py 55 3 94.55% 56, 74, 108 plugins/search/csw.py 105 81 22.86% 58-59, 63-64, 72-120, 126-139, 147-179, 197-238 plugins/search/data_request_search.py 200 67 66.50% 90-93, 109, 121, 125-126, 137, 142, 147, 154, 167-170, 224-225, 229, 239-245, 250, 276-279, 287-298, 315, 317, 324-325, 327-328, 346-350, 383, 393, 404, 417, 423-438, 443 plugins/search/qssearch.py 666 81 87.84% 391, 395-401, 409-410, 516-522, 572, 588, 598, 625, 627, 670-673, 747-748, 796, 815, 822, 834, 892, 913, 916-917, 926-927, 936-937, 946-947, 974, 1045-1050, 1054-1063, 1097, 1119, 1179, 1228, 1302-1306, 1366, 1369, 1375-1376, 1397, 1424-1436, 1443, 1475-1477, 1487-1493, 1523, 1546, 1561, 1583, 1692-1702 plugins/search/static_stac_search.py 72 10 86.11% 101-128, 144, 157 rest/__init__.py 4 2 50.00% 21-22 rest/cache.py 33 7 78.79% 35-37, 53-55, 59, 68 rest/config.py 26 0 100.00% rest/constants.py 7 0 100.00% rest/core.py 234 26 88.89% 281, 365, 475, 702, 709-757 rest/server.py 283 53 81.27% 108, 131-133, 246-248, 304-305, 317-333, 425-430, 458, 626-633, 662, 706-707, 730, 803-805, 822-827, 856, 858, 862-863, 867-868 rest/stac.py 464 118 74.57% 322, 344, 392-395, 419-445, 450-456, 479-481, 504, 539-540, 568, 581, 626-666, 694-710, 807-811, 818, 874-875, 942, 1010-1012, 1231, 1241-1253, 1266-1288, 1302-1347, 1509-1510 rest/types/__init__.py 0 0 100.00% rest/types/collections_search.py 13 13 0.00% 18-44 rest/types/eodag_search.py 179 5 97.21% 232-236, 289, 292, 360 rest/types/queryables.py 56 1 98.21% 174 rest/types/stac_search.py 126 7 94.44% 130, 176, 191-193, 201, 205 rest/utils/__init__.py 93 12 87.10% 108-109, 128-130, 182, 192-206 rest/utils/cql_evaluate.py 48 5 89.58% 69, 76, 90, 97, 105 rest/utils/rfc3339.py 23 3 86.96% 49, 61, 63 types/__init__.py 114 14 87.72% 53, 70, 129-132, 199, 213-222, 232, 253, 266 types/bbox.py 43 19 55.81% 46-61, 72-74, 85-87, 99-101, 113-115, 123 types/download_args.py 9 0 100.00% types/queryables.py 81 0 100.00% types/search_args.py 70 18 74.29% 60-64, 71-88, 104 types/whoosh.py 15 0 100.00% utils/__init__.py 500 37 92.60% 85, 90, 194-195, 204-231, 234, 248, 330-334, 410-414, 435-437, 519, 534, 572-573, 969-972, 980-981, 1022-1023, 1205 utils/constraints.py 119 37 68.91% 94-103, 144, 149, 153, 164, 190-192, 202, 216-232, 241-252 utils/exceptions.py 35 1 97.14% 93 utils/import_system.py 28 19 32.14% 67-81, 93-103 utils/logging.py 29 1 96.55% 123 utils/notebook.py 44 23 47.73% 25-29, 36-41, 58-62, 72-78, 83-87 utils/repr.py 30 8 73.33% 36, 38, 42, 76, 94-101 utils/requests.py 55 11 80.00% 69, 96, 98, 100, 102, 104, 123, 131-133, 141 utils/rest.py 36 1 97.22% 57 utils/stac_reader.py 111 45 59.46% 56-57, 63-85, 95-97, 101, 143, 159-162, 215-224, 234-264 TOTAL 9553 1622 83.02% ```

Diff against develop

Filename        Stmts    Miss  Cover
------------  -------  ------  -------
rest/stac.py        0      -2  +0.43%
TOTAL               0      -2  +0.02%

Results for commit: 1d9d5b2a2b4151cf65e172cdc22f3f2313a1a528

Minimum allowed coverage is 70%

:recycle: This comment has been updated with latest results

github-actions[bot] commented 2 months ago

badge

Code Coverage (Windows)

``` Filename Stmts Miss Cover Missing ----------------------------------------- ------- ------ ------- ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- __init__.py 8 0 100.00% cli.py 303 50 83.50% 654-700, 802-853, 857 config.py 367 28 92.37% 82-84, 93, 101, 105-107, 184, 196, 469-471, 535-538, 585-586, 595-596, 705, 739, 774-779, 781 crunch.py 5 5 0.00% 20-24 api/__init__.py 0 0 100.00% api/core.py 758 74 90.24% 640, 684-687, 725, 762, 792, 840, 844-849, 875, 971, 1054, 1191, 1281-1293, 1333, 1335, 1363, 1367-1378, 1391-1397, 1487-1490, 1523-1543, 1599, 1616-1619, 1631-1634, 1656-1663, 1989, 2022-2028, 2295, 2299-2302, 2316-2318, 2353 api/search_result.py 51 4 92.16% 75, 84, 91, 105 api/product/__init__.py 6 0 100.00% api/product/_assets.py 48 5 89.58% 80, 157, 167, 170-174 api/product/_product.py 187 20 89.30% 70-72, 242-243, 325, 354, 415, 429-432, 445, 469-472, 515-521 api/product/metadata_mapping.py 675 81 88.00% 131-133, 234, 266-267, 313-314, 324-336, 338, 349, 355-367, 412-413, 450, 471-474, 497, 505-506, 582-583, 607-608, 614-617, 632-633, 782, 828, 1002-1007, 1138, 1152-1172, 1192, 1197, 1307, 1329, 1343, 1356-1375, 1414, 1466, 1504-1508, 1527 api/product/drivers/__init__.py 6 0 100.00% api/product/drivers/base.py 6 1 83.33% 41 plugins/__init__.py 0 0 100.00% plugins/base.py 21 3 85.71% 48, 55, 68 plugins/manager.py 130 12 90.77% 105-110, 160, 201, 223, 227, 253, 292-293 plugins/apis/__init__.py 0 0 100.00% plugins/apis/base.py 4 0 100.00% plugins/apis/ecmwf.py 91 8 91.21% 150-152, 199-200, 226-228 plugins/apis/usgs.py 180 31 82.78% 132, 233, 267, 302-304, 309, 335-336, 341, 371-378, 389-394, 416-422, 424-430, 453 plugins/authentication/__init__.py 6 1 83.33% 31 plugins/authentication/aws_auth.py 19 0 100.00% plugins/authentication/base.py 17 2 88.24% 34, 47 plugins/authentication/generic.py 14 2 85.71% 40, 50 plugins/authentication/header.py 19 0 100.00% plugins/authentication/keycloak.py 46 4 91.30% 132, 156-161 plugins/authentication/oauth.py 13 7 46.15% 32-34, 38-41 plugins/authentication/openid_connect.py 183 17 90.71% 119, 133-158, 166, 320-323, 347 plugins/authentication/qsauth.py 34 1 97.06% 83 plugins/authentication/sas_auth.py 47 1 97.87% 76 plugins/authentication/token.py 88 16 81.82% 79, 107, 109, 131-143, 198-202 plugins/authentication/token_exchange.py 35 19 45.71% 74-80, 92-120 plugins/crunch/__init__.py 0 0 100.00% plugins/crunch/base.py 10 1 90.00% 40 plugins/crunch/filter_date.py 59 14 76.27% 51-56, 70, 79, 88, 91, 103-105, 114-116, 123 plugins/crunch/filter_latest_intersect.py 47 33 29.79% 48-53, 69-114 plugins/crunch/filter_latest_tpl_name.py 31 1 96.77% 87 plugins/crunch/filter_overlap.py 66 18 72.73% 28-30, 72-75, 82-85, 91, 99, 110-126 plugins/crunch/filter_property.py 30 7 76.67% 58-63, 66-67, 83-87 plugins/download/__init__.py 0 0 100.00% plugins/download/aws.py 489 163 66.67% 273, 286, 353-356, 370-374, 420-422, 426, 460-461, 467-471, 504, 539, 543, 550, 580-588, 592, 630-638, 645-647, 688-762, 780-841, 852-857, 873-886, 915, 930-932, 935, 945-953, 961-974, 984-1015, 1022-1034, 1075, 1101, 1146-1148, 1368 plugins/download/base.py 253 53 79.05% 145, 180, 250-252, 319-320, 340-346, 377-381, 387-388, 432, 435-449, 461, 465, 538-542, 572-573, 581-598, 605-613, 615-619, 666, 688, 710, 718 plugins/download/creodias_s3.py 17 9 47.06% 44-58 plugins/download/http.py 534 130 75.66% 203-215, 217-218, 253-256, 320-323, 325-326, 333-338, 356-371, 388-390, 402, 450, 457-463, 481, 495, 509, 517-519, 535-540, 551, 569, 611-615, 637, 677, 722, 736-742, 778-842, 860, 893-902, 928-929, 956-961, 967, 970, 986, 1003-1004, 1017, 1034-1035, 1042, 1104-1110, 1165-1166, 1172, 1182, 1218, 1254, 1272-1288, 1314-1316 plugins/download/s3rest.py 116 24 79.31% 121, 157, 164, 199, 229-236, 239-241, 245, 258-264, 272-273, 276-280, 303, 324-327 plugins/search/__init__.py 22 0 100.00% plugins/search/base.py 128 14 89.06% 104, 108, 121, 271, 291, 350-351, 371, 374-382, 384 plugins/search/build_search_result.py 181 30 83.43% 97, 141-142, 148, 159, 295-298, 327, 384-401, 463, 466, 476, 493, 513-528 plugins/search/cop_marine.py 197 47 76.14% 55, 63-65, 71-72, 88, 90, 93, 128-130, 142-143, 183-192, 196, 199, 203, 221, 251, 255, 270, 274, 278, 282, 286-290, 296-299, 302-316, 333, 356, 359, 365 plugins/search/creodias_s3.py 55 3 94.55% 56, 74, 108 plugins/search/csw.py 105 81 22.86% 58-59, 63-64, 72-120, 126-139, 147-179, 197-238 plugins/search/data_request_search.py 200 67 66.50% 90-93, 109, 121, 125-126, 137, 142, 147, 154, 167-170, 224-225, 229, 239-245, 250, 276-279, 287-298, 315, 317, 324-325, 327-328, 346-350, 383, 393, 404, 417, 423-438, 443 plugins/search/qssearch.py 666 109 83.63% 391, 395-401, 409-410, 516-522, 572, 575, 588, 598, 617-632, 670-673, 747-748, 796, 815, 822, 834, 892, 913, 916-917, 926-927, 936-937, 946-947, 974, 1045-1050, 1054-1063, 1097, 1119, 1179, 1228, 1302-1306, 1366, 1369, 1375-1376, 1397, 1424-1436, 1443, 1475-1477, 1487-1493, 1523, 1546, 1561, 1583, 1651-1722 plugins/search/static_stac_search.py 72 10 86.11% 101-128, 144, 157 rest/__init__.py 4 2 50.00% 21-22 rest/cache.py 33 22 33.33% 35-37, 44-70 rest/config.py 26 4 84.62% 34-36, 68 rest/constants.py 7 0 100.00% rest/core.py 234 149 36.32% 167-248, 272-326, 339-375, 412-444, 464-480, 503-514, 523-559, 578, 624-663, 702, 709-757 rest/server.py 283 283 0.00% 18-879 rest/stac.py 464 393 15.30% 128-134, 142-167, 198-203, 235, 255-378, 388-457, 475-514, 530-583, 593-616, 626-666, 694-710, 720, 736-739, 758-837, 855-891, 920-945, 953-969, 977-982, 992-1019, 1029-1031, 1039-1041, 1054-1056, 1070-1087, 1097-1118, 1128-1150, 1158-1175, 1198-1221, 1231, 1241-1253, 1266-1288, 1302-1347, 1355-1372, 1382-1540 rest/types/__init__.py 0 0 100.00% rest/types/collections_search.py 13 13 0.00% 18-44 rest/types/eodag_search.py 179 15 91.62% 122, 232-236, 269-271, 289, 292, 298, 302, 360, 372-375 rest/types/queryables.py 56 13 76.79% 51-52, 59-60, 67-68, 97-102, 111-112, 174 rest/types/stac_search.py 126 18 85.71% 128-130, 154-155, 160-161, 176, 191-193, 201, 205, 252-257 rest/utils/__init__.py 93 30 67.74% 79-85, 105, 108-109, 128-130, 143, 150, 175-183, 190-211 rest/utils/cql_evaluate.py 48 5 89.58% 69, 76, 90, 97, 105 rest/utils/rfc3339.py 23 6 73.91% 41, 44-45, 49, 61, 63 types/__init__.py 114 39 65.79% 53, 66-70, 81-93, 120-122, 129-132, 172, 199, 209-225, 230, 232, 253, 258, 266, 276 types/bbox.py 43 19 55.81% 46-61, 72-74, 85-87, 99-101, 113-115, 123 types/download_args.py 9 0 100.00% types/queryables.py 81 0 100.00% types/search_args.py 70 18 74.29% 60-64, 71-88, 104 types/whoosh.py 15 0 100.00% utils/__init__.py 500 39 92.20% 85, 90, 194-195, 204-231, 234, 248, 330-334, 410-414, 435-437, 519, 534, 572-573, 969-972, 980-981, 1022-1023, 1056, 1205, 1381 utils/constraints.py 119 37 68.91% 94-103, 144, 149, 153, 164, 190-192, 202, 216-232, 241-252 utils/exceptions.py 35 1 97.14% 93 utils/import_system.py 28 19 32.14% 67-81, 93-103 utils/logging.py 29 1 96.55% 123 utils/notebook.py 44 23 47.73% 25-29, 36-41, 58-62, 72-78, 83-87 utils/repr.py 30 8 73.33% 36, 38, 42, 76, 94-101 utils/requests.py 55 11 80.00% 69, 96, 98, 100, 102, 104, 123, 131-133, 141 utils/rest.py 36 1 97.22% 57 utils/stac_reader.py 111 45 59.46% 56-57, 63-85, 95-97, 101, 143, 159-162, 215-224, 234-264 TOTAL 9553 2420 74.67% ```

Diff against develop

Filename      Stmts    Miss  Cover
----------  -------  ------  --------
TOTAL             0       0  +100.00%

Results for commit: 1d9d5b2a2b4151cf65e172cdc22f3f2313a1a528

Minimum allowed coverage is 70%

:recycle: This comment has been updated with latest results