Skip to content

Minor adjustments pre-v2.3#431

Merged
sl-at-ibm merged 4 commits into
mainfrom
SL-pre23-small-adjustments
Jun 30, 2026
Merged

Minor adjustments pre-v2.3#431
sl-at-ibm merged 4 commits into
mainfrom
SL-pre23-small-adjustments

Conversation

@sl-at-ibm

Copy link
Copy Markdown
Collaborator
  • (following Cédrick) Different errors if the PCU Group ID is outright nonexistent or belongs to a different cloud provider/region (+ specific tests)
  • the error raised is not ValueError anymore, rather DevOpsAPIException
  • more robust unmarshaling of pcu-related devops api responses (= everything that is not critical is made optional, no errors if fields missing from responses)

@sl-at-ibm sl-at-ibm requested a review from erichare June 28, 2026 11:04
Comment thread astrapy/admin/admin.py Outdated
)
else:
# is the matching group in the right cloud provider / region?
expected_cpr = (_definition.cloud_provider, _definition.region)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Going back to the whole "aws" vs "AWS" discussion... should this perhaps be a case-insensitive comparison? Or do we want to enforce a strict case sensitive match

@erichare erichare left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM @sl-at-ibm , one small question regarding case sensitivity but looks great otherwise

Comment thread astrapy/admin/admin.py Outdated
)
else:
# is the matching group in the right cloud provider / region?
expected_cpr = (_definition.cloud_provider, _definition.region)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Same question as up above, basically if this side of the comparison should also be case-normalized as well

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Thanks for spotting those! Fixed.

I will also bundle the bump to 2.3 in this PR and then proceed with releasing. (to lessen the business with getting the CI go green).

@github-actions

Copy link
Copy Markdown

Coverage report

for commit: 2de9bdc73c6e6f8341a315e1a2bd50f52240e93b.
download detailed report here.

                                                File   Stmts   Miss      Cover     Delta
----------------------------------------------------------------------------------------
                astrapy/event_observers/observers.py      30     17     43.33%   -53.33%
                 astrapy/utils/duration_std_utils.py      92     52     43.48%   -48.91%
         astrapy/event_observers/context_managers.py      24      9     62.50%   -37.50%
         astrapy/exceptions/devops_api_exceptions.py      79     34     56.96%   -35.44%
                     astrapy/utils/document_paths.py      46     15     67.39%   -32.61%
                 astrapy/data_types/data_api_date.py      89     34     61.80%   -31.46%
 astrapy/data/info/table_descriptor/type_altering.py      85     33     61.18%   -30.59%
                   astrapy/event_observers/events.py      50     14     72.00%   -28.00%
                 astrapy/data_types/data_api_time.py      98     33     66.33%   -26.53%
             astrapy/exceptions/error_descriptors.py      53     17     67.92%   -26.42%
                   astrapy/utils/duration_c_utils.py      66     17     74.24%   -22.73%
           astrapy/exceptions/data_api_exceptions.py      84     19     77.38%   -21.43%
                  astrapy/data_types/data_api_set.py      90     41     54.44%   -20.00%
            astrapy/data_types/data_api_timestamp.py      98     30     69.39%   -19.39%
                      astrapy/utils/api_commander.py     248     69     72.18%   -19.35%
                              astrapy/admin/admin.py     859    496     42.26%   -18.28%
                                   astrapy/client.py      68     23     66.18%   -17.65%
             astrapy/data_types/data_api_duration.py      55     14     74.55%   -16.36%
                         astrapy/utils/date_utils.py      80     15     81.25%   -16.25%
 astrapy/data/info/table_descriptor/type_creation.py      32      6     81.25%   -12.50%
          astrapy/data/info/collection_descriptor.py     222     60     72.97%   -12.16%
              astrapy/exceptions/table_exceptions.py      27     11     59.26%   -11.11%
                           astrapy/authentication.py     146     39     73.29%   -10.27%
             astrapy/data_types/data_api_dict_udt.py      10      2     80.00%   -10.00%
 astrapy/data/info/table_descriptor/table_indexes.py     230     48     79.13%    -9.57%
                  astrapy/data_types/data_api_map.py      59     13     77.97%    -8.47%
                          astrapy/admin/endpoints.py      36      5     86.11%    -8.33%
              astrapy/data/utils/table_converters.py     412     53     87.14%    -8.01%
astrapy/data/info/table_descriptor/table_altering.py     114     20     82.46%    -7.89%
               astrapy/data/utils/vector_coercion.py      13      1     92.31%    -7.69%
                  astrapy/data/info/database_info.py     187     44     76.47%    -7.31%
                               astrapy/utils/meta.py      42     19     54.76%    -7.14%
                           astrapy/utils/str_enum.py      32      3     90.62%    -6.25%
                               astrapy/data/table.py     738    105     85.77%    -5.42%
  astrapy/data/info/table_descriptor/type_listing.py      39      6     84.62%    -5.13%
           astrapy/data/utils/distinct_extractors.py     104      6     94.23%    -4.81%
astrapy/data/info/table_descriptor/table_creation.py      49      4     91.84%    -4.08%
                            astrapy/data/database.py     657    100     84.78%    -3.81%
                      astrapy/exceptions/__init__.py     108     23     78.70%    -3.70%
                      astrapy/utils/request_tools.py      32      1     96.88%    -3.12%
               astrapy/data_types/data_api_vector.py      44      8     81.82%    -2.27%
 astrapy/data/info/table_descriptor/table_listing.py      49      7     85.71%    -2.04%
 astrapy/data/info/table_descriptor/table_columns.py     204     19     90.69%    -0.98%
                      astrapy/data/info/reranking.py     122     19     84.43%    -0.82%
                      astrapy/data/info/vectorize.py     131     15     88.55%    -0.76%
                                     astrapy/repl.py      77     77      0.00%     0.00%
                                 astrapy/__init__.py      26     10     61.54%     0.00%
                                  astrapy/results.py      50     16     68.00%     0.00%
         astrapy/exceptions/collection_exceptions.py      40     11     72.50%     0.00%
                         astrapy/exceptions/utils.py      53     11     79.25%     0.00%
                  astrapy/data/cursors/pagination.py      21      4     80.95%     0.00%
                        astrapy/utils/user_agents.py      18      3     83.33%     0.00%
                            astrapy/utils/parsing.py       7      1     85.71%     0.00%
    astrapy/settings/definitions/definitions_data.py      38      4     89.47%     0.00%
                              astrapy/utils/unset.py      10      1     90.00%     0.00%
                        astrapy/utils/api_options.py     206     20     90.29%     0.00%
                          astrapy/data/collection.py     752     57     92.42%     0.00%
                astrapy/data/cursors/query_engine.py     214     16     92.52%     0.00%
         astrapy/data/utils/collection_converters.py      80      4     95.00%     0.00%
                 astrapy/data/cursors/find_cursor.py     647     30     95.36%     0.00%
                      astrapy/data/cursors/cursor.py      92      3     96.74%     0.00%
                 astrapy/data/cursors/farr_cursor.py     358     11     96.93%     0.00%
   astrapy/settings/definitions/definitions_admin.py      41      1     97.56%     0.00%
                           astrapy/admin/__init__.py       3      0    100.00%     0.00%
                              astrapy/api_options.py       3      0    100.00%     0.00%
                               astrapy/collection.py       2      0    100.00%     0.00%
                                astrapy/constants.py       5      0    100.00%     0.00%
                                  astrapy/cursors.py       7      0    100.00%     0.00%
                            astrapy/data/__init__.py       0      0    100.00%     0.00%
                    astrapy/data/cursors/__init__.py       1      0    100.00%     0.00%
             astrapy/data/cursors/reranked_result.py       8      0    100.00%     0.00%
                      astrapy/data/utils/__init__.py       0      0    100.00%     0.00%
      astrapy/data/utils/extended_json_converters.py      28      0    100.00%     0.00%
                   astrapy/data/utils/table_types.py      36      0    100.00%     0.00%
                      astrapy/data_types/__init__.py      10      0    100.00%     0.00%
                                 astrapy/database.py       2      0    100.00%     0.00%
                 astrapy/event_observers/__init__.py       5      0    100.00%     0.00%
                                      astrapy/ids.py       5      0    100.00%     0.00%
                                     astrapy/info.py      15      0    100.00%     0.00%
                        astrapy/settings/__init__.py       0      0    100.00%     0.00%
                        astrapy/settings/defaults.py      47      0    100.00%     0.00%
            astrapy/settings/definitions/__init__.py       0      0    100.00%     0.00%
   astrapy/settings/definitions/definitions_types.py      18      0    100.00%     0.00%
                  astrapy/settings/error_messages.py       2      0    100.00%     0.00%
                                    astrapy/table.py       2      0    100.00%     0.00%
                           astrapy/utils/__init__.py       0      0    100.00%     0.00%
                     astrapy/utils/python_version.py       5      0    100.00%     0.00%
----------------------------------------------------------------------------------------
                                              totals    9067   1899     79.06%    -8.38%

@github-actions

Copy link
Copy Markdown

Coverage report

for commit: 4138de697b3f7bcbf209d027902b43f390386674.
download detailed report here.

                                                File   Stmts   Miss      Cover     Delta
----------------------------------------------------------------------------------------
                      astrapy/exceptions/__init__.py     108     20     81.48%    -0.93%
                  astrapy/data/info/database_info.py     187     32     82.89%    -0.90%
                                     astrapy/repl.py      77     77      0.00%     0.00%
                                 astrapy/__init__.py      26     10     61.54%     0.00%
                               astrapy/utils/meta.py      42     16     61.90%     0.00%
                                  astrapy/results.py      50     16     68.00%     0.00%
              astrapy/exceptions/table_exceptions.py      27      8     70.37%     0.00%
         astrapy/exceptions/collection_exceptions.py      40     11     72.50%     0.00%
                  astrapy/data_types/data_api_set.py      90     23     74.44%     0.00%
                         astrapy/exceptions/utils.py      53     11     79.25%     0.00%
                  astrapy/data/cursors/pagination.py      21      4     80.95%     0.00%
                        astrapy/utils/user_agents.py      18      3     83.33%     0.00%
                           astrapy/authentication.py     146     24     83.56%     0.00%
                                   astrapy/client.py      68     11     83.82%     0.00%
               astrapy/data_types/data_api_vector.py      44      7     84.09%     0.00%
          astrapy/data/info/collection_descriptor.py     222     33     85.14%     0.00%
                      astrapy/data/info/reranking.py     122     18     85.25%     0.00%
                            astrapy/utils/parsing.py       7      1     85.71%     0.00%
                  astrapy/data_types/data_api_map.py      59      8     86.44%     0.00%
 astrapy/data/info/table_descriptor/table_listing.py      49      6     87.76%     0.00%
                            astrapy/data/database.py     657     75     88.58%     0.00%
 astrapy/data/info/table_descriptor/table_indexes.py     230     26     88.70%     0.00%
            astrapy/data_types/data_api_timestamp.py      98     11     88.78%     0.00%
                      astrapy/data/info/vectorize.py     131     14     89.31%     0.00%
    astrapy/settings/definitions/definitions_data.py      38      4     89.47%     0.00%
  astrapy/data/info/table_descriptor/type_listing.py      39      4     89.74%     0.00%
             astrapy/data_types/data_api_dict_udt.py      10      1     90.00%     0.00%
                              astrapy/utils/unset.py      10      1     90.00%     0.00%
                        astrapy/utils/api_options.py     206     20     90.29%     0.00%
astrapy/data/info/table_descriptor/table_altering.py     114     11     90.35%     0.00%
             astrapy/data_types/data_api_duration.py      55      5     90.91%     0.00%
                               astrapy/data/table.py     738     65     91.19%     0.00%
                      astrapy/utils/api_commander.py     248     21     91.53%     0.00%
 astrapy/data/info/table_descriptor/table_columns.py     204     17     91.67%     0.00%
 astrapy/data/info/table_descriptor/type_altering.py      85      7     91.76%     0.00%
                 astrapy/utils/duration_std_utils.py      92      7     92.39%     0.00%
         astrapy/exceptions/devops_api_exceptions.py      79      6     92.41%     0.00%
                          astrapy/data/collection.py     752     57     92.42%     0.00%
                astrapy/data/cursors/query_engine.py     214     16     92.52%     0.00%
                 astrapy/data_types/data_api_time.py      98      7     92.86%     0.00%
                 astrapy/data_types/data_api_date.py      89      6     93.26%     0.00%
 astrapy/data/info/table_descriptor/type_creation.py      32      2     93.75%     0.00%
             astrapy/exceptions/error_descriptors.py      53      3     94.34%     0.00%
                          astrapy/admin/endpoints.py      36      2     94.44%     0.00%
         astrapy/data/utils/collection_converters.py      80      4     95.00%     0.00%
              astrapy/data/utils/table_converters.py     412     20     95.15%     0.00%
                 astrapy/data/cursors/find_cursor.py     647     30     95.36%     0.00%
astrapy/data/info/table_descriptor/table_creation.py      49      2     95.92%     0.00%
                astrapy/event_observers/observers.py      30      1     96.67%     0.00%
                      astrapy/data/cursors/cursor.py      92      3     96.74%     0.00%
                           astrapy/utils/str_enum.py      32      1     96.88%     0.00%
                 astrapy/data/cursors/farr_cursor.py     358     11     96.93%     0.00%
                   astrapy/utils/duration_c_utils.py      66      2     96.97%     0.00%
                         astrapy/utils/date_utils.py      80      2     97.50%     0.00%
   astrapy/settings/definitions/definitions_admin.py      41      1     97.56%     0.00%
           astrapy/exceptions/data_api_exceptions.py      84      1     98.81%     0.00%
           astrapy/data/utils/distinct_extractors.py     104      1     99.04%     0.00%
                           astrapy/admin/__init__.py       3      0    100.00%     0.00%
                              astrapy/api_options.py       3      0    100.00%     0.00%
                               astrapy/collection.py       2      0    100.00%     0.00%
                                astrapy/constants.py       5      0    100.00%     0.00%
                                  astrapy/cursors.py       7      0    100.00%     0.00%
                            astrapy/data/__init__.py       0      0    100.00%     0.00%
                    astrapy/data/cursors/__init__.py       1      0    100.00%     0.00%
             astrapy/data/cursors/reranked_result.py       8      0    100.00%     0.00%
                      astrapy/data/utils/__init__.py       0      0    100.00%     0.00%
      astrapy/data/utils/extended_json_converters.py      28      0    100.00%     0.00%
                   astrapy/data/utils/table_types.py      36      0    100.00%     0.00%
               astrapy/data/utils/vector_coercion.py      13      0    100.00%     0.00%
                      astrapy/data_types/__init__.py      10      0    100.00%     0.00%
                                 astrapy/database.py       2      0    100.00%     0.00%
                 astrapy/event_observers/__init__.py       5      0    100.00%     0.00%
         astrapy/event_observers/context_managers.py      24      0    100.00%     0.00%
                   astrapy/event_observers/events.py      50      0    100.00%     0.00%
                                      astrapy/ids.py       5      0    100.00%     0.00%
                                     astrapy/info.py      15      0    100.00%     0.00%
                        astrapy/settings/__init__.py       0      0    100.00%     0.00%
                        astrapy/settings/defaults.py      47      0    100.00%     0.00%
            astrapy/settings/definitions/__init__.py       0      0    100.00%     0.00%
   astrapy/settings/definitions/definitions_types.py      18      0    100.00%     0.00%
                  astrapy/settings/error_messages.py       2      0    100.00%     0.00%
                                    astrapy/table.py       2      0    100.00%     0.00%
                           astrapy/utils/__init__.py       0      0    100.00%     0.00%
                     astrapy/utils/document_paths.py      46      0    100.00%     0.00%
                     astrapy/utils/python_version.py       5      0    100.00%     0.00%
                      astrapy/utils/request_tools.py      32      0    100.00%     0.00%
                              astrapy/admin/admin.py     859    335     61.00%     0.46%
----------------------------------------------------------------------------------------
                                              totals    9067   1141     87.42%    -0.02%

@sl-at-ibm sl-at-ibm merged commit 3570473 into main Jun 30, 2026
10 checks passed
@sl-at-ibm sl-at-ibm deleted the SL-pre23-small-adjustments branch June 30, 2026 11:07
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.

2 participants