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

docs: plugins and utils documention update #1297

Merged
merged 25 commits into from
Oct 21, 2024

Conversation

jlahovnik
Copy link
Collaborator

@jlahovnik jlahovnik commented Aug 14, 2024

  • docstrings for the configuration parameters have been added for all plugins
  • in case documentation was already existing it was standardized and updated
  • eodag.utils functions included in documentation

NOTE: for currently unused plugins (such as CSWSearch or S3RestDownload) the documentation might be incomplete due to missing examples; it should be updated when they are used again

@jlahovnik jlahovnik linked an issue Aug 14, 2024 that may be closed by this pull request
35 tasks
@jlahovnik jlahovnik self-assigned this Aug 14, 2024
Copy link
Contributor

github-actions bot commented Aug 14, 2024

Test Results

    4 files  ±0      4 suites  ±0   5m 43s ⏱️ +3s
  568 tests ±0    565 ✅ ±0   3 💤 ±0  0 ❌ ±0 
2 272 runs  ±0  2 176 ✅ ±0  96 💤 ±0  0 ❌ ±0 

Results for commit c7cd7ed. ± Comparison against base commit e482098.

♻️ This comment has been updated with latest results.

Copy link
Contributor

github-actions bot commented Aug 14, 2024

badge

Code Coverage (Ubuntu)

Filename                                     Stmts    Miss  Cover    Missing
-----------------------------------------  -------  ------  -------  ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
__init__.py                                      8       0  100.00%
cli.py                                         314      59  81.21%   657-716, 818-869, 873
config.py                                      416      27  93.51%   83-85, 94, 102, 106-108, 179, 190, 661-663, 776-779, 822-823, 832-833, 938, 1001-1006, 1008
crunch.py                                        5       5  0.00%    20-24
api/__init__.py                                  0       0  100.00%
api/core.py                                    763      69  90.96%   360, 650, 694-697, 735, 779, 813, 858-863, 889, 980, 1048, 1186, 1271-1283, 1319, 1321, 1349, 1353-1364, 1377-1383, 1466-1469, 1502-1522, 1574, 1591-1595, 1607-1610, 1962, 1986-1992, 2243, 2247-2251, 2260-2262, 2294
api/search_result.py                            59       4  93.22%   83, 92, 99, 113
api/product/__init__.py                          6       0  100.00%
api/product/_assets.py                          48       5  89.58%   75, 147, 155, 158-162
api/product/_product.py                        187      20  89.30%   70-72, 237-238, 313, 342, 399, 413-416, 429, 453-456, 499-505
api/product/metadata_mapping.py                680      68  90.00%   130-132, 227, 259-260, 306-307, 317-329, 331, 342, 348-360, 405-406, 443, 464-467, 490, 498-499, 575-576, 600-601, 607-610, 625-626, 775, 821, 992-997, 1124, 1138-1158, 1178, 1183, 1312, 1326, 1397, 1449, 1489-1493, 1508
api/product/drivers/__init__.py                  6       0  100.00%
api/product/drivers/base.py                      6       1  83.33%   38
plugins/__init__.py                              0       0  100.00%
plugins/base.py                                 21       2  90.48%   48, 55
plugins/manager.py                             173      15  91.33%   116-121, 171, 209, 231, 235, 259, 281, 388-391, 403-404
plugins/apis/__init__.py                         0       0  100.00%
plugins/apis/base.py                             4       0  100.00%
plugins/apis/ecmwf.py                           91       8  91.21%   159-161, 208-209, 235-237
plugins/apis/usgs.py                           180      31  82.78%   154, 256, 290, 325-327, 332, 358-359, 364, 394-401, 412-417, 439-445, 447-453, 476
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%   43, 56
plugins/authentication/generic.py               14       2  85.71%   51, 61
plugins/authentication/header.py                19       0  100.00%
plugins/authentication/keycloak.py              48       4  91.67%   153, 179-184
plugins/authentication/oauth.py                 13       7  46.15%   41-43, 47-50
plugins/authentication/openid_connect.py       187      17  90.91%   117, 131-157, 165, 298-301, 327
plugins/authentication/qsauth.py                34       1  97.06%   91
plugins/authentication/sas_auth.py              47       1  97.87%   76
plugins/authentication/token.py                 89      16  82.02%   101, 130, 132, 155-168, 224-228
plugins/authentication/token_exchange.py        36      20  44.44%   72-78, 90-120
plugins/crunch/__init__.py                       0       0  100.00%
plugins/crunch/base.py                          10       1  90.00%   43
plugins/crunch/filter_date.py                   59      14  76.27%   51-56, 68, 77, 86, 89, 101-103, 112-114, 121
plugins/crunch/filter_latest_intersect.py       47       8  82.98%   52-53, 69, 78-81, 83, 90-93
plugins/crunch/filter_latest_tpl_name.py        31       1  96.77%   85
plugins/crunch/filter_overlap.py                66      18  72.73%   28-30, 73-76, 83-86, 92, 100, 111-127
plugins/crunch/filter_property.py               30       7  76.67%   56-61, 64-65, 81-85
plugins/download/__init__.py                     0       0  100.00%
plugins/download/aws.py                        491     163  66.80%   282, 295, 362-365, 379-383, 425-427, 431, 463-464, 470-474, 503, 535, 539, 546, 576-584, 588, 620-628, 639-641, 672-746, 764-824, 835-840, 852-865, 890, 905-907, 910, 920-928, 936-949, 959-990, 997-1009, 1047, 1073, 1118-1120, 1340
plugins/download/base.py                       253      51  79.84%   136, 164, 296-297, 314-320, 351-355, 361-362, 404, 407-421, 433, 437, 501-505, 535-536, 544-561, 568-576, 578-582, 625, 647, 669, 677
plugins/download/creodias_s3.py                 17       9  47.06%   53-67
plugins/download/http.py                       534     127  76.22%   225-237, 239-240, 336-339, 341-342, 349-354, 372-387, 404-406, 418, 466, 473-479, 497, 511, 525, 533-535, 551-556, 567, 585, 627-631, 653, 693, 738, 752-758, 787-851, 869, 899-908, 930-931, 958-963, 969, 972, 988, 1005-1006, 1036-1037, 1044, 1105-1111, 1166-1167, 1173, 1183, 1219, 1255, 1273-1286, 1312-1314
plugins/download/s3rest.py                     116      24  79.31%   117, 153, 160, 195, 222-229, 232-234, 238, 249-255, 263-264, 267-271, 294, 315-318
plugins/search/__init__.py                      22       0  100.00%
plugins/search/base.py                         132      13  90.15%   104, 108, 119, 278, 298, 354-355, 375, 378-386
plugins/search/build_search_result.py          189      24  87.30%   91, 132-133, 139, 150, 283-286, 315, 350-367, 416, 445, 448, 458, 475, 503, 505
plugins/search/cop_marine.py                   236      50  78.81%   55, 63-65, 75-76, 81, 86-87, 103, 105, 108, 155-157, 169-170, 212, 218, 222, 226, 239, 250-251, 259, 287, 291, 306, 310, 314, 318, 322-326, 332-335, 338-352, 369, 418-422, 427, 439
plugins/search/creodias_s3.py                   55       3  94.55%   58, 76, 110
plugins/search/csw.py                          105      81  22.86%   98-99, 103-104, 112-160, 166-179, 187-219, 237-278
plugins/search/data_request_search.py          202      69  65.84%   188-191, 207, 218, 222-223, 234, 239, 244, 251, 264-267, 321-322, 326, 336-342, 347, 373-376, 384-395, 412, 414, 421-424, 426-427, 445-449, 482, 492, 503, 516, 522-537, 542
plugins/search/qssearch.py                     731     100  86.32%   447, 461, 465-471, 492-496, 588-600, 644, 660, 670, 689-704, 741-744, 815-816, 864, 883, 890, 902, 959, 980, 983-984, 993-994, 1003-1004, 1013-1014, 1041, 1112-1117, 1121-1130, 1164, 1186, 1246, 1336, 1423, 1426-1427, 1509-1513, 1575, 1578, 1584-1585, 1606, 1633-1645, 1652, 1684-1686, 1696-1702, 1732, 1755, 1770, 1786, 1871-1874, 1879-1882, 1891, 1911-1912, 1921-1925, 1931
plugins/search/static_stac_search.py            75      13  82.67%   98-124, 140, 153
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                                6       0  100.00%
rest/core.py                                   251      64  74.50%   216-217, 273, 281, 298-316, 331-369, 460, 502-533, 680, 687-735
rest/errors.py                                  67       5  92.54%   106, 116, 127, 140-141
rest/server.py                                 188      24  87.23%   89, 112-114, 277-282, 310, 495-497, 514-519, 548, 550, 554-555, 559-560
rest/stac.py                                   319      63  80.25%   306, 328, 380-383, 410-437, 468-470, 493, 525-526, 608-648, 670-686, 778-782, 789, 843-844, 905, 995-997
rest/types/__init__.py                           0       0  100.00%
rest/types/collections_search.py                13      13  0.00%    18-44
rest/types/eodag_search.py                     176       5  97.16%   225-229, 282, 285, 353
rest/types/queryables.py                        56       1  98.21%   164
rest/types/stac_search.py                      126       7  94.44%   129, 175, 190-192, 200, 204
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%   48, 60, 62
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, 103
types/whoosh.py                                 15       0  100.00%
utils/__init__.py                              502      37  92.63%   85, 90, 194-195, 204-231, 234, 248, 328-332, 406-410, 429-431, 510, 525, 561-562, 926-929, 937-938, 976-977, 1148
utils/constraints.py                           119      38  68.07%   62, 89-98, 139, 144, 148, 159, 182-184, 194, 208-224, 233-244
utils/exceptions.py                             40       2  95.00%   98-99
utils/import_system.py                          28      19  32.14%   64-78, 89-99
utils/logging.py                                28       1  96.43%   41
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%   64, 86, 88, 90, 92, 94, 110, 118-120, 128
utils/rest.py                                   36       1  97.22%   55
utils/stac_reader.py                           111      45  59.46%   56-57, 63-85, 95-97, 101, 137, 153-156, 203-212, 222-252
TOTAL                                         9651    1608  83.34%

Diff against develop

Filename                                Stmts    Miss  Cover
------------------------------------  -------  ------  -------
config.py                                 +32       0  +0.54%
plugins/search/qssearch.py                +13      +6  -0.59%
plugins/search/static_stac_search.py       +3      +3  -3.44%
TOTAL                                     +48      +9  -0.01%

Results for commit: 6bb304e

Minimum allowed coverage is 70%

♻️ This comment has been updated with latest results

Copy link
Contributor

github-actions bot commented Aug 14, 2024

badge

Code Coverage (Windows)

Filename                                     Stmts    Miss  Cover    Missing
-----------------------------------------  -------  ------  -------  -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
__init__.py                                      8       0  100.00%
cli.py                                         314      59  81.21%   657-716, 818-869, 873
config.py                                      416      28  93.27%   83-85, 94, 102, 106-108, 179, 190, 661-663, 776-779, 822-823, 832-833, 938, 969, 1001-1006, 1008
crunch.py                                        5       5  0.00%    20-24
api/__init__.py                                  0       0  100.00%
api/core.py                                    763      69  90.96%   360, 650, 694-697, 735, 779, 813, 858-863, 889, 980, 1048, 1186, 1271-1283, 1319, 1321, 1349, 1353-1364, 1377-1383, 1466-1469, 1502-1522, 1574, 1591-1595, 1607-1610, 1962, 1986-1992, 2243, 2247-2251, 2260-2262, 2294
api/search_result.py                            59       4  93.22%   83, 92, 99, 113
api/product/__init__.py                          6       0  100.00%
api/product/_assets.py                          48       5  89.58%   75, 147, 155, 158-162
api/product/_product.py                        187      20  89.30%   70-72, 237-238, 313, 342, 399, 413-416, 429, 453-456, 499-505
api/product/metadata_mapping.py                680      68  90.00%   130-132, 227, 259-260, 306-307, 317-329, 331, 342, 348-360, 405-406, 443, 464-467, 490, 498-499, 575-576, 600-601, 607-610, 625-626, 775, 821, 992-997, 1124, 1138-1158, 1178, 1183, 1312, 1326, 1397, 1449, 1489-1493, 1508
api/product/drivers/__init__.py                  6       0  100.00%
api/product/drivers/base.py                      6       1  83.33%   38
plugins/__init__.py                              0       0  100.00%
plugins/base.py                                 21       3  85.71%   48, 55, 68
plugins/manager.py                             173      15  91.33%   116-121, 171, 209, 231, 235, 259, 281, 388-391, 403-404
plugins/apis/__init__.py                         0       0  100.00%
plugins/apis/base.py                             4       0  100.00%
plugins/apis/ecmwf.py                           91       8  91.21%   159-161, 208-209, 235-237
plugins/apis/usgs.py                           180      31  82.78%   154, 256, 290, 325-327, 332, 358-359, 364, 394-401, 412-417, 439-445, 447-453, 476
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%   43, 56
plugins/authentication/generic.py               14       2  85.71%   51, 61
plugins/authentication/header.py                19       0  100.00%
plugins/authentication/keycloak.py              48       4  91.67%   153, 179-184
plugins/authentication/oauth.py                 13       7  46.15%   41-43, 47-50
plugins/authentication/openid_connect.py       187      17  90.91%   117, 131-157, 165, 298-301, 327
plugins/authentication/qsauth.py                34       1  97.06%   91
plugins/authentication/sas_auth.py              47       1  97.87%   76
plugins/authentication/token.py                 89      16  82.02%   101, 130, 132, 155-168, 224-228
plugins/authentication/token_exchange.py        36      20  44.44%   72-78, 90-120
plugins/crunch/__init__.py                       0       0  100.00%
plugins/crunch/base.py                          10       1  90.00%   43
plugins/crunch/filter_date.py                   59      14  76.27%   51-56, 68, 77, 86, 89, 101-103, 112-114, 121
plugins/crunch/filter_latest_intersect.py       47      33  29.79%   49-54, 67-112
plugins/crunch/filter_latest_tpl_name.py        31       1  96.77%   85
plugins/crunch/filter_overlap.py                66      18  72.73%   28-30, 73-76, 83-86, 92, 100, 111-127
plugins/crunch/filter_property.py               30       7  76.67%   56-61, 64-65, 81-85
plugins/download/__init__.py                     0       0  100.00%
plugins/download/aws.py                        491     163  66.80%   282, 295, 362-365, 379-383, 425-427, 431, 463-464, 470-474, 503, 535, 539, 546, 576-584, 588, 620-628, 639-641, 672-746, 764-824, 835-840, 852-865, 890, 905-907, 910, 920-928, 936-949, 959-990, 997-1009, 1047, 1073, 1118-1120, 1340
plugins/download/base.py                       253      53  79.05%   136, 164, 231-233, 296-297, 314-320, 351-355, 361-362, 404, 407-421, 433, 437, 501-505, 535-536, 544-561, 568-576, 578-582, 625, 647, 669, 677
plugins/download/creodias_s3.py                 17       9  47.06%   53-67
plugins/download/http.py                       534     128  76.03%   225-237, 239-240, 336-339, 341-342, 349-354, 372-387, 404-406, 418, 466, 473-479, 497, 511, 525, 533-535, 551-556, 567, 585, 627-631, 653, 693, 738, 752-758, 787-851, 869, 899-908, 930-931, 958-963, 969, 972, 988, 1005-1006, 1019, 1036-1037, 1044, 1105-1111, 1166-1167, 1173, 1183, 1219, 1255, 1273-1286, 1312-1314
plugins/download/s3rest.py                     116      24  79.31%   117, 153, 160, 195, 222-229, 232-234, 238, 249-255, 263-264, 267-271, 294, 315-318
plugins/search/__init__.py                      22       0  100.00%
plugins/search/base.py                         132      14  89.39%   104, 108, 119, 278, 298, 354-355, 375, 378-386, 388
plugins/search/build_search_result.py          189      31  83.60%   91, 132-133, 139, 150, 283-286, 315, 350-367, 416, 445, 448, 458, 475, 495-510
plugins/search/cop_marine.py                   236      50  78.81%   55, 63-65, 75-76, 81, 86-87, 103, 105, 108, 155-157, 169-170, 212, 218, 222, 226, 239, 250-251, 259, 287, 291, 306, 310, 314, 318, 322-326, 332-335, 338-352, 369, 418-422, 427, 439
plugins/search/creodias_s3.py                   55       3  94.55%   58, 76, 110
plugins/search/csw.py                          105      81  22.86%   98-99, 103-104, 112-160, 166-179, 187-219, 237-278
plugins/search/data_request_search.py          202      69  65.84%   188-191, 207, 218, 222-223, 234, 239, 244, 251, 264-267, 321-322, 326, 336-342, 347, 373-376, 384-395, 412, 414, 421-424, 426-427, 445-449, 482, 492, 503, 516, 522-537, 542
plugins/search/qssearch.py                     731     132  81.94%   447, 461, 465-471, 492-496, 588-600, 644, 647, 660, 670, 689-704, 741-744, 815-816, 864, 883, 890, 902, 959, 980, 983-984, 993-994, 1003-1004, 1013-1014, 1041, 1112-1117, 1121-1130, 1164, 1186, 1246, 1336, 1423, 1426-1427, 1509-1513, 1575, 1578, 1584-1585, 1606, 1633-1645, 1652, 1684-1686, 1696-1702, 1732, 1755, 1770, 1786, 1854-1960
plugins/search/static_stac_search.py            75      13  82.67%   98-124, 140, 153
rest/__init__.py                                 4       2  50.00%   21-22
rest/cache.py                                   33      22  33.33%   35-37, 44-70
rest/config.py                                  26       1  96.15%   36
rest/constants.py                                6       0  100.00%
rest/core.py                                   251     139  44.62%   162, 164, 166, 169-170, 184-194, 206-207, 209-210, 216-217, 220, 223, 264-318, 331-369, 400-434, 449-465, 481-490, 502-533, 550, 592-641, 680, 687-735
rest/errors.py                                  67      47  29.85%   60, 65-100, 105-108, 115-118, 126-144, 152-157, 172-178
rest/server.py                                 188     188  0.00%    18-573
rest/stac.py                                   319      68  78.68%   240, 306, 328, 380-383, 410-437, 468-470, 493, 525-526, 608-648, 670-686, 713, 778-782, 789, 843-844, 850, 905, 943, 976, 995-997
rest/types/__init__.py                           0       0  100.00%
rest/types/collections_search.py                13      13  0.00%    18-44
rest/types/eodag_search.py                     176      16  90.91%   225-229, 262-264, 282, 285, 291, 295, 353, 370-380
rest/types/queryables.py                        56      13  76.79%   51-52, 59-60, 67-68, 94-99, 108-109, 164
rest/types/stac_search.py                      126      11  91.27%   127-129, 175, 190-192, 200, 204, 252, 255
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       5  78.26%   43-44, 48, 60, 62
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, 103
types/whoosh.py                                 15       0  100.00%
utils/__init__.py                              502      37  92.63%   85, 90, 194-195, 204-231, 234, 248, 328-332, 406-410, 429-431, 510, 525, 561-562, 926-929, 937-938, 976-977, 1148
utils/constraints.py                           119      38  68.07%   62, 89-98, 139, 144, 148, 159, 182-184, 194, 208-224, 233-244
utils/exceptions.py                             40       2  95.00%   98-99
utils/import_system.py                          28      19  32.14%   64-78, 89-99
utils/logging.py                                28       1  96.43%   41
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%   64, 86, 88, 90, 92, 94, 110, 118-120, 128
utils/rest.py                                   36       1  97.22%   55
utils/stac_reader.py                           111      45  59.46%   56-57, 63-85, 95-97, 101, 137, 153-156, 203-212, 222-252
TOTAL                                         9651    2052  78.74%

Diff against develop

Filename                                Stmts    Miss  Cover
------------------------------------  -------  ------  -------
config.py                                 +32       0  +0.56%
plugins/search/qssearch.py                +13      +9  -0.93%
plugins/search/static_stac_search.py       +3      +3  -3.44%
TOTAL                                     +48     +12  -0.02%

Results for commit: 6bb304e

Minimum allowed coverage is 70%

♻️ This comment has been updated with latest results

eodag/plugins/search/data_request_search.py Outdated Show resolved Hide resolved
eodag/plugins/search/qssearch.py Outdated Show resolved Hide resolved
@dalpasso dalpasso marked this pull request as draft August 20, 2024 14:09
@jlahovnik jlahovnik marked this pull request as ready for review August 20, 2024 15:51
@dalpasso dalpasso requested a review from sbrunato August 21, 2024 06:20
@sbrunato sbrunato force-pushed the 1286-document-config-parameters-in-plugins branch from 4215f14 to d6fc761 Compare September 27, 2024 14:33
Copy link
Collaborator

@sbrunato sbrunato left a comment

Choose a reason for hiding this comment

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

Please edit docstrings layout, following HttpDownload, QueryStringSearch and ODataV4Search models:

  • describe config parameters inside config parameter description
  • link parameters to their PluginConfig class variable
  • if PluginConfig class variable (attribute ou TypedDict) is missing, add it

@sbrunato sbrunato marked this pull request as draft September 27, 2024 15:56
@jlahovnik
Copy link
Collaborator Author

format of documentation for config parameters changed to sphinx style

@jlahovnik jlahovnik marked this pull request as ready for review October 2, 2024 07:14
eodag/plugins/search/qssearch.py Outdated Show resolved Hide resolved
eodag/plugins/search/qssearch.py Outdated Show resolved Hide resolved
eodag/plugins/search/qssearch.py Outdated Show resolved Hide resolved
eodag/plugins/search/qssearch.py Outdated Show resolved Hide resolved
eodag/plugins/search/qssearch.py Outdated Show resolved Hide resolved
eodag/plugins/search/csw.py Outdated Show resolved Hide resolved
eodag/plugins/authentication/generic.py Show resolved Hide resolved
eodag/plugins/authentication/generic.py Outdated Show resolved Hide resolved
eodag/plugins/authentication/token.py Show resolved Hide resolved
eodag/plugins/authentication/header.py Show resolved Hide resolved
@sbrunato sbrunato marked this pull request as draft October 2, 2024 10:14
Copy link
Collaborator

@sbrunato sbrunato left a comment

Choose a reason for hiding this comment

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

  • Also fix rst formatting in api/base

eodag/plugins/authentication/aws_auth.py Outdated Show resolved Hide resolved
eodag/plugins/authentication/oauth.py Outdated Show resolved Hide resolved
eodag/plugins/authentication/openid_connect.py Outdated Show resolved Hide resolved
eodag/plugins/download/s3rest.py Show resolved Hide resolved
eodag/plugins/download/s3rest.py Outdated Show resolved Hide resolved
eodag/plugins/download/s3rest.py Outdated Show resolved Hide resolved
eodag/plugins/download/creodias_s3.py Outdated Show resolved Hide resolved
eodag/plugins/apis/usgs.py Outdated Show resolved Hide resolved
@jlahovnik jlahovnik force-pushed the 1286-document-config-parameters-in-plugins branch from f7322b1 to 5ee5d15 Compare October 3, 2024 09:03
@jlahovnik
Copy link
Collaborator Author

First part of comments is implemented, I will check the rest later.

Copy link
Contributor

github-actions bot commented Oct 16, 2024

badge

Code Coverage (Ubuntu)

Filename                                     Stmts    Miss  Cover    Missing
-----------------------------------------  -------  ------  -------  ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
__init__.py                                      8       0  100.00%
cli.py                                         314      59  81.21%   657-716, 818-869, 873
config.py                                      421      27  93.59%   83-85, 94, 102, 106-108, 179, 190, 676-678, 791-794, 837-838, 847-848, 953, 1016-1021, 1023
crunch.py                                        5       5  0.00%    20-24
api/__init__.py                                  0       0  100.00%
api/core.py                                    767      69  91.00%   374, 664, 708-711, 749, 793, 827, 872-877, 903, 994, 1062, 1200, 1285-1297, 1333, 1335, 1363, 1367-1378, 1391-1397, 1480-1483, 1516-1536, 1588, 1605-1609, 1621-1624, 1980, 2004-2010, 2261, 2265-2269, 2278-2280, 2312
api/search_result.py                            58       4  93.10%   92, 101, 108, 122
api/product/__init__.py                          6       0  100.00%
api/product/_assets.py                          48       5  89.58%   75, 147, 155, 158-162
api/product/_product.py                        187      20  89.30%   70-72, 237-238, 313, 342, 399, 413-416, 429, 453-456, 499-505
api/product/metadata_mapping.py                680      68  90.00%   130-132, 227, 259-260, 306-307, 317-329, 331, 342, 348-360, 405-406, 443, 464-467, 490, 498-499, 575-576, 600-601, 607-610, 625-626, 775, 821, 992-997, 1124, 1138-1158, 1178, 1183, 1312, 1326, 1397, 1449, 1489-1493, 1508
api/product/drivers/__init__.py                  6       0  100.00%
api/product/drivers/base.py                      6       1  83.33%   38
plugins/__init__.py                              0       0  100.00%
plugins/base.py                                 21       2  90.48%   48, 55
plugins/manager.py                             172      15  91.28%   116-121, 171, 209, 231, 235, 259, 281, 399-402, 414-415
plugins/apis/__init__.py                         0       0  100.00%
plugins/apis/base.py                             4       0  100.00%
plugins/apis/ecmwf.py                           91       8  91.21%   159-161, 208-209, 235-237
plugins/apis/usgs.py                           180      31  82.78%   155, 257, 291, 326-328, 333, 359-360, 365, 395-402, 413-418, 440-446, 448-454, 477
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%   43, 56
plugins/authentication/generic.py               14       2  85.71%   51, 61
plugins/authentication/header.py                19       0  100.00%
plugins/authentication/keycloak.py              48       4  91.67%   153, 179-184
plugins/authentication/oauth.py                 13       7  46.15%   42-44, 48-51
plugins/authentication/openid_connect.py       187      17  90.91%   118, 132-158, 166, 300-303, 329
plugins/authentication/qsauth.py                34       1  97.06%   91
plugins/authentication/sas_auth.py              47       1  97.87%   76
plugins/authentication/token.py                 89      16  82.02%   101, 130, 132, 155-168, 224-228
plugins/authentication/token_exchange.py        36      20  44.44%   72-78, 90-120
plugins/crunch/__init__.py                       0       0  100.00%
plugins/crunch/base.py                          10       1  90.00%   43
plugins/crunch/filter_date.py                   59      14  76.27%   52-57, 69, 78, 87, 90, 102-104, 113-115, 122
plugins/crunch/filter_latest_intersect.py       47       8  82.98%   52-53, 69, 78-81, 83, 90-93
plugins/crunch/filter_latest_tpl_name.py        31       1  96.77%   83
plugins/crunch/filter_overlap.py                66      18  72.73%   28-30, 66-69, 76-79, 85, 93, 104-120
plugins/crunch/filter_property.py               30       7  76.67%   55-60, 63-64, 80-84
plugins/download/__init__.py                     0       0  100.00%
plugins/download/aws.py                        491     163  66.80%   282, 295, 362-365, 379-383, 425-427, 431, 463-464, 470-474, 503, 535, 539, 546, 576-584, 588, 620-628, 639-641, 672-746, 764-824, 835-840, 852-865, 890, 905-907, 910, 920-928, 936-949, 959-990, 997-1009, 1047, 1073, 1118-1120, 1340
plugins/download/base.py                       253      51  79.84%   136, 164, 296-297, 314-320, 351-355, 361-362, 404, 407-421, 433, 437, 501-505, 535-536, 544-561, 568-576, 578-582, 625, 647, 669, 677
plugins/download/creodias_s3.py                 17       9  47.06%   53-67
plugins/download/http.py                       533     120  77.49%   234, 330-333, 335-336, 343-348, 366-381, 398-400, 412, 460, 467-473, 491, 505, 519, 527-529, 545-550, 561, 579, 621-625, 647, 687, 732, 746-752, 781-845, 863, 893-902, 924-925, 952-957, 963, 966, 982, 999-1000, 1030-1031, 1038, 1099-1105, 1160-1161, 1167, 1177, 1213, 1249, 1267-1280, 1306-1308
plugins/download/s3rest.py                     116      24  79.31%   118, 154, 161, 196, 223-230, 233-235, 239, 250-256, 264-265, 268-272, 295, 316-319
plugins/search/__init__.py                      22       0  100.00%
plugins/search/base.py                         132      13  90.15%   100, 104, 115, 274, 294, 350-351, 371, 374-382
plugins/search/build_search_result.py          188      24  87.23%   100, 141-142, 148, 159, 292-295, 324, 359-376, 425, 454, 457, 467, 484, 512, 514
plugins/search/cop_marine.py                   236      50  78.81%   55, 63-65, 75-76, 81, 86-87, 103, 105, 108, 155-157, 169-170, 212, 218, 222, 226, 239, 250-251, 259, 287, 291, 306, 310, 314, 318, 322-326, 332-335, 338-352, 369, 418-422, 427, 439
plugins/search/creodias_s3.py                   55       3  94.55%   58, 76, 110
plugins/search/csw.py                          105      81  22.86%   98-99, 103-104, 112-160, 166-179, 187-219, 237-278
plugins/search/data_request_search.py          202      69  65.84%   188-191, 207, 218, 222-223, 234, 239, 244, 251, 264-267, 321-322, 326, 336-342, 347, 373-376, 384-395, 412, 414, 421-424, 426-427, 445-449, 482, 492, 503, 516, 522-537, 542
plugins/search/qssearch.py                     731     100  86.32%   447, 461, 465-471, 492-496, 588-600, 644, 660, 670, 689-704, 741-744, 815-816, 864, 883, 890, 902, 959, 980, 983-984, 993-994, 1003-1004, 1013-1014, 1041, 1112-1117, 1121-1130, 1164, 1186, 1246, 1336, 1423, 1426-1427, 1509-1513, 1575, 1578, 1584-1585, 1606, 1633-1645, 1652, 1684-1686, 1696-1702, 1732, 1755, 1770, 1786, 1871-1874, 1879-1882, 1891, 1911-1912, 1921-1925, 1931
plugins/search/static_stac_search.py            75      13  82.67%   98-124, 140, 153
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                                  25       0  100.00%
rest/constants.py                                6       0  100.00%
rest/core.py                                   251      63  74.90%   216-217, 273, 281, 299-316, 331-369, 460, 502-533, 680, 687-735
rest/errors.py                                  69       5  92.75%   106, 116, 127, 143-144
rest/server.py                                 188      24  87.23%   89, 112-114, 277-282, 310, 495-497, 514-519, 548, 550, 554-555, 559-560
rest/stac.py                                   319      63  80.25%   306, 328, 380-383, 410-437, 468-470, 493, 525-526, 608-648, 670-686, 778-782, 789, 843-844, 905, 995-997
rest/types/__init__.py                           0       0  100.00%
rest/types/collections_search.py                13      13  0.00%    18-44
rest/types/eodag_search.py                     176       5  97.16%   225-229, 282, 285, 353
rest/types/queryables.py                        55       1  98.18%   163
rest/types/stac_search.py                      125       7  94.40%   138, 184, 199-201, 209, 213
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%   48, 60, 62
types/__init__.py                              114      14  87.72%   65, 82, 141-144, 211, 225-234, 244, 265, 278
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                             80       0  100.00%
types/search_args.py                            70      18  74.29%   60-64, 71-88, 103
types/whoosh.py                                 15       0  100.00%
utils/__init__.py                              499      36  92.79%   85, 189-190, 199-226, 229, 244, 324-328, 401-405, 424-426, 505, 520, 560-561, 925-928, 936-937, 975-976, 1147
utils/constraints.py                           119      38  68.07%   62, 89-98, 139, 144, 148, 159, 182-184, 194, 208-224, 233-244
utils/exceptions.py                             41       0  100.00%
utils/import_system.py                          28      19  32.14%   64-78, 89-99
utils/logging.py                                28       1  96.43%   41
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%   64, 86, 88, 90, 92, 94, 110, 118-120, 128
utils/rest.py                                   36       1  97.22%   55
utils/stac_reader.py                           111      45  59.46%   56-57, 63-85, 95-97, 101, 137, 153-156, 203-212, 222-252
TOTAL                                         9652    1597  83.45%

Diff against develop

Filename                                Stmts    Miss  Cover
------------------------------------  -------  ------  -------
config.py                                 +37       0  +0.62%
plugins/search/qssearch.py                +13      +6  -0.59%
plugins/search/static_stac_search.py       +3      +3  -3.44%
TOTAL                                     +53      +9  -0.01%

Results for commit: c7cd7ed

Minimum allowed coverage is 70%

♻️ This comment has been updated with latest results

Copy link
Contributor

github-actions bot commented Oct 16, 2024

badge

Code Coverage (Windows)

Filename                                     Stmts    Miss  Cover    Missing
-----------------------------------------  -------  ------  -------  -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
__init__.py                                      8       0  100.00%
cli.py                                         314      59  81.21%   657-716, 818-869, 873
config.py                                      421      28  93.35%   83-85, 94, 102, 106-108, 179, 190, 676-678, 791-794, 837-838, 847-848, 953, 984, 1016-1021, 1023
crunch.py                                        5       5  0.00%    20-24
api/__init__.py                                  0       0  100.00%
api/core.py                                    767      69  91.00%   374, 664, 708-711, 749, 793, 827, 872-877, 903, 994, 1062, 1200, 1285-1297, 1333, 1335, 1363, 1367-1378, 1391-1397, 1480-1483, 1516-1536, 1588, 1605-1609, 1621-1624, 1980, 2004-2010, 2261, 2265-2269, 2278-2280, 2312
api/search_result.py                            58       4  93.10%   92, 101, 108, 122
api/product/__init__.py                          6       0  100.00%
api/product/_assets.py                          48       5  89.58%   75, 147, 155, 158-162
api/product/_product.py                        187      20  89.30%   70-72, 237-238, 313, 342, 399, 413-416, 429, 453-456, 499-505
api/product/metadata_mapping.py                680      68  90.00%   130-132, 227, 259-260, 306-307, 317-329, 331, 342, 348-360, 405-406, 443, 464-467, 490, 498-499, 575-576, 600-601, 607-610, 625-626, 775, 821, 992-997, 1124, 1138-1158, 1178, 1183, 1312, 1326, 1397, 1449, 1489-1493, 1508
api/product/drivers/__init__.py                  6       0  100.00%
api/product/drivers/base.py                      6       1  83.33%   38
plugins/__init__.py                              0       0  100.00%
plugins/base.py                                 21       3  85.71%   48, 55, 68
plugins/manager.py                             172      15  91.28%   116-121, 171, 209, 231, 235, 259, 281, 399-402, 414-415
plugins/apis/__init__.py                         0       0  100.00%
plugins/apis/base.py                             4       0  100.00%
plugins/apis/ecmwf.py                           91       8  91.21%   159-161, 208-209, 235-237
plugins/apis/usgs.py                           180      31  82.78%   155, 257, 291, 326-328, 333, 359-360, 365, 395-402, 413-418, 440-446, 448-454, 477
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%   43, 56
plugins/authentication/generic.py               14       2  85.71%   51, 61
plugins/authentication/header.py                19       0  100.00%
plugins/authentication/keycloak.py              48       4  91.67%   153, 179-184
plugins/authentication/oauth.py                 13       7  46.15%   42-44, 48-51
plugins/authentication/openid_connect.py       187      17  90.91%   118, 132-158, 166, 300-303, 329
plugins/authentication/qsauth.py                34       1  97.06%   91
plugins/authentication/sas_auth.py              47       1  97.87%   76
plugins/authentication/token.py                 89      16  82.02%   101, 130, 132, 155-168, 224-228
plugins/authentication/token_exchange.py        36      20  44.44%   72-78, 90-120
plugins/crunch/__init__.py                       0       0  100.00%
plugins/crunch/base.py                          10       1  90.00%   43
plugins/crunch/filter_date.py                   59      14  76.27%   52-57, 69, 78, 87, 90, 102-104, 113-115, 122
plugins/crunch/filter_latest_intersect.py       47      33  29.79%   49-54, 67-112
plugins/crunch/filter_latest_tpl_name.py        31       1  96.77%   83
plugins/crunch/filter_overlap.py                66      18  72.73%   28-30, 66-69, 76-79, 85, 93, 104-120
plugins/crunch/filter_property.py               30       7  76.67%   55-60, 63-64, 80-84
plugins/download/__init__.py                     0       0  100.00%
plugins/download/aws.py                        491     163  66.80%   282, 295, 362-365, 379-383, 425-427, 431, 463-464, 470-474, 503, 535, 539, 546, 576-584, 588, 620-628, 639-641, 672-746, 764-824, 835-840, 852-865, 890, 905-907, 910, 920-928, 936-949, 959-990, 997-1009, 1047, 1073, 1118-1120, 1340
plugins/download/base.py                       253      53  79.05%   136, 164, 231-233, 296-297, 314-320, 351-355, 361-362, 404, 407-421, 433, 437, 501-505, 535-536, 544-561, 568-576, 578-582, 625, 647, 669, 677
plugins/download/creodias_s3.py                 17       9  47.06%   53-67
plugins/download/http.py                       533     121  77.30%   234, 330-333, 335-336, 343-348, 366-381, 398-400, 412, 460, 467-473, 491, 505, 519, 527-529, 545-550, 561, 579, 621-625, 647, 687, 732, 746-752, 781-845, 863, 893-902, 924-925, 952-957, 963, 966, 982, 999-1000, 1013, 1030-1031, 1038, 1099-1105, 1160-1161, 1167, 1177, 1213, 1249, 1267-1280, 1306-1308
plugins/download/s3rest.py                     116      24  79.31%   118, 154, 161, 196, 223-230, 233-235, 239, 250-256, 264-265, 268-272, 295, 316-319
plugins/search/__init__.py                      22       0  100.00%
plugins/search/base.py                         132      14  89.39%   100, 104, 115, 274, 294, 350-351, 371, 374-382, 384
plugins/search/build_search_result.py          188      31  83.51%   100, 141-142, 148, 159, 292-295, 324, 359-376, 425, 454, 457, 467, 484, 504-519
plugins/search/cop_marine.py                   236      50  78.81%   55, 63-65, 75-76, 81, 86-87, 103, 105, 108, 155-157, 169-170, 212, 218, 222, 226, 239, 250-251, 259, 287, 291, 306, 310, 314, 318, 322-326, 332-335, 338-352, 369, 418-422, 427, 439
plugins/search/creodias_s3.py                   55       3  94.55%   58, 76, 110
plugins/search/csw.py                          105      81  22.86%   98-99, 103-104, 112-160, 166-179, 187-219, 237-278
plugins/search/data_request_search.py          202      69  65.84%   188-191, 207, 218, 222-223, 234, 239, 244, 251, 264-267, 321-322, 326, 336-342, 347, 373-376, 384-395, 412, 414, 421-424, 426-427, 445-449, 482, 492, 503, 516, 522-537, 542
plugins/search/qssearch.py                     731     132  81.94%   447, 461, 465-471, 492-496, 588-600, 644, 647, 660, 670, 689-704, 741-744, 815-816, 864, 883, 890, 902, 959, 980, 983-984, 993-994, 1003-1004, 1013-1014, 1041, 1112-1117, 1121-1130, 1164, 1186, 1246, 1336, 1423, 1426-1427, 1509-1513, 1575, 1578, 1584-1585, 1606, 1633-1645, 1652, 1684-1686, 1696-1702, 1732, 1755, 1770, 1786, 1854-1960
plugins/search/static_stac_search.py            75      13  82.67%   98-124, 140, 153
rest/__init__.py                                 4       2  50.00%   21-22
rest/cache.py                                   33      22  33.33%   35-37, 44-70
rest/config.py                                  25       1  96.00%   35
rest/constants.py                                6       0  100.00%
rest/core.py                                   251     139  44.62%   162, 164, 166, 169-170, 184-194, 206-207, 209-210, 216-217, 220, 223, 264-318, 331-369, 400-434, 449-465, 481-490, 502-533, 550, 592-641, 680, 687-735
rest/errors.py                                  69      49  28.99%   60, 65-100, 105-108, 115-118, 126-147, 155-160, 175-181
rest/server.py                                 188     188  0.00%    18-573
rest/stac.py                                   319      68  78.68%   240, 306, 328, 380-383, 410-437, 468-470, 493, 525-526, 608-648, 670-686, 713, 778-782, 789, 843-844, 850, 905, 943, 976, 995-997
rest/types/__init__.py                           0       0  100.00%
rest/types/collections_search.py                13      13  0.00%    18-44
rest/types/eodag_search.py                     176      16  90.91%   225-229, 262-264, 282, 285, 291, 295, 353, 370-380
rest/types/queryables.py                        55      13  76.36%   50-51, 58-59, 66-67, 93-98, 107-108, 163
rest/types/stac_search.py                      125      11  91.20%   136-138, 184, 199-201, 209, 213, 261, 264
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       5  78.26%   43-44, 48, 60, 62
types/__init__.py                              114      39  65.79%   65, 78-82, 93-105, 132-134, 141-144, 184, 211, 221-237, 242, 244, 265, 270, 278, 288
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                             80       0  100.00%
types/search_args.py                            70      18  74.29%   60-64, 71-88, 103
types/whoosh.py                                 15       0  100.00%
utils/__init__.py                              499      36  92.79%   85, 189-190, 199-226, 229, 244, 324-328, 401-405, 424-426, 505, 520, 560-561, 925-928, 936-937, 975-976, 1147
utils/constraints.py                           119      38  68.07%   62, 89-98, 139, 144, 148, 159, 182-184, 194, 208-224, 233-244
utils/exceptions.py                             41       0  100.00%
utils/import_system.py                          28      19  32.14%   64-78, 89-99
utils/logging.py                                28       1  96.43%   41
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%   64, 86, 88, 90, 92, 94, 110, 118-120, 128
utils/rest.py                                   36       1  97.22%   55
utils/stac_reader.py                           111      45  59.46%   56-57, 63-85, 95-97, 101, 137, 153-156, 203-212, 222-252
TOTAL                                         9652    2044  78.82%

Diff against develop

Filename                                Stmts    Miss  Cover
------------------------------------  -------  ------  -------
config.py                                 +37       0  +0.64%
plugins/search/qssearch.py                +13      +9  -0.93%
plugins/search/static_stac_search.py       +3      +3  -3.44%
TOTAL                                     +53     +12  -0.01%

Results for commit: c7cd7ed

Minimum allowed coverage is 70%

♻️ This comment has been updated with latest results

@jlahovnik jlahovnik marked this pull request as ready for review October 16, 2024 10:12
eodag/plugins/search/qssearch.py Outdated Show resolved Hide resolved
eodag/plugins/authentication/openid_connect.py Outdated Show resolved Hide resolved
eodag/plugins/authentication/openid_connect.py Outdated Show resolved Hide resolved
@sbrunato sbrunato marked this pull request as draft October 18, 2024 16:23
@sbrunato sbrunato force-pushed the 1286-document-config-parameters-in-plugins branch 2 times, most recently from b457532 to 75a6aa7 Compare October 21, 2024 13:45
@sbrunato sbrunato force-pushed the 1286-document-config-parameters-in-plugins branch from 75a6aa7 to c7cd7ed Compare October 21, 2024 13:55
@sbrunato sbrunato marked this pull request as ready for review October 21, 2024 14:01
@sbrunato sbrunato changed the title 1286 document config parameters in plugins docs: plugins and utils documention update Oct 21, 2024
@sbrunato sbrunato merged commit cdee784 into develop Oct 21, 2024
10 checks passed
@sbrunato sbrunato deleted the 1286-document-config-parameters-in-plugins branch October 21, 2024 14:05
@sbrunato sbrunato added this to the 3.0.1.dev milestone Oct 22, 2024
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.

Document config parameters in plugins
3 participants