Skip to content

Conversation

@simonkurtz-MSFT
Copy link
Member

@simonkurtz-MSFT simonkurtz-MSFT commented Dec 12, 2025

This is a sizable PR to refactor Python:

  • Break up utils.py meaningfully as it has grown entirely too large. New files are azure_resources.py, json_utils.py, and console.py.
  • Address Pylint issues
  • Add ~60 new unit tests
  • Parallelize resource cleanup in the same resource group (previously only across resource groups)
  • Add Python and Bicep specific Copilot instructions files
  • Normalize line endings to LF

@simonkurtz-MSFT simonkurtz-MSFT self-assigned this Dec 12, 2025
@simonkurtz-MSFT simonkurtz-MSFT added the enhancement New feature or request label Dec 12, 2025
@github-actions
Copy link

github-actions bot commented Dec 12, 2025

Python 3.13 Test Results

401 tests  +65   401 ✅ +65   4s ⏱️ -1s
  1 suites ± 0     0 💤 ± 0 
  1 files   ± 0     0 ❌ ± 0 

Results for commit 157fbd9. ± Comparison against base commit 503fdfd.

This pull request removes 81 and adds 146 tests. Note that renamed tests count towards both.
test_apimtypes ‑ test_get_project_root_functionality
test_utils ‑ test_check_apim_blob_permissions_failure
test_utils ‑ test_check_apim_blob_permissions_success
test_utils ‑ test_cleanup_edge_cases_comprehensive
test_utils ‑ test_cleanup_functions_comprehensive
test_utils ‑ test_cleanup_infra_deployment_single
test_utils ‑ test_cleanup_infra_deployments_all_infrastructure_types
test_utils ‑ test_cleanup_infra_deployments_index_scenarios
test_utils ‑ test_cleanup_infra_deployments_max_workers_limit
test_utils ‑ test_cleanup_infra_deployments_parallel_mode
…
test_apimtypes ‑ testget_project_root_functionality
test_azure_resources ‑ test_does_resource_group_exist_false
test_azure_resources ‑ test_does_resource_group_exist_true
test_azure_resources ‑ test_get_account_info_failure
test_azure_resources ‑ test_get_account_info_no_json
test_azure_resources ‑ test_get_account_info_success
test_azure_resources ‑ test_get_apim_url_failure
test_azure_resources ‑ test_get_apim_url_no_gateway
test_azure_resources ‑ test_get_apim_url_success
test_azure_resources ‑ test_get_appgw_endpoint_no_gateway
…

♻️ This comment has been updated with latest results.

@github-actions
Copy link

github-actions bot commented Dec 12, 2025

Python 3.14 Test Results

401 tests  +65   401 ✅ +65   3s ⏱️ -2s
  1 suites ± 0     0 💤 ± 0 
  1 files   ± 0     0 ❌ ± 0 

Results for commit 157fbd9. ± Comparison against base commit 503fdfd.

This pull request removes 81 and adds 146 tests. Note that renamed tests count towards both.
test_apimtypes ‑ test_get_project_root_functionality
test_utils ‑ test_check_apim_blob_permissions_failure
test_utils ‑ test_check_apim_blob_permissions_success
test_utils ‑ test_cleanup_edge_cases_comprehensive
test_utils ‑ test_cleanup_functions_comprehensive
test_utils ‑ test_cleanup_infra_deployment_single
test_utils ‑ test_cleanup_infra_deployments_all_infrastructure_types
test_utils ‑ test_cleanup_infra_deployments_index_scenarios
test_utils ‑ test_cleanup_infra_deployments_max_workers_limit
test_utils ‑ test_cleanup_infra_deployments_parallel_mode
…
test_apimtypes ‑ testget_project_root_functionality
test_azure_resources ‑ test_does_resource_group_exist_false
test_azure_resources ‑ test_does_resource_group_exist_true
test_azure_resources ‑ test_get_account_info_failure
test_azure_resources ‑ test_get_account_info_no_json
test_azure_resources ‑ test_get_account_info_success
test_azure_resources ‑ test_get_apim_url_failure
test_azure_resources ‑ test_get_apim_url_no_gateway
test_azure_resources ‑ test_get_apim_url_success
test_azure_resources ‑ test_get_appgw_endpoint_no_gateway
…

♻️ This comment has been updated with latest results.

@github-actions
Copy link

github-actions bot commented Dec 12, 2025

Python 3.12 Test Results

401 tests  +65   401 ✅ +65   5s ⏱️ ±0s
  1 suites ± 0     0 💤 ± 0 
  1 files   ± 0     0 ❌ ± 0 

Results for commit 157fbd9. ± Comparison against base commit 503fdfd.

This pull request removes 81 and adds 146 tests. Note that renamed tests count towards both.
test_apimtypes ‑ test_get_project_root_functionality
test_utils ‑ test_check_apim_blob_permissions_failure
test_utils ‑ test_check_apim_blob_permissions_success
test_utils ‑ test_cleanup_edge_cases_comprehensive
test_utils ‑ test_cleanup_functions_comprehensive
test_utils ‑ test_cleanup_infra_deployment_single
test_utils ‑ test_cleanup_infra_deployments_all_infrastructure_types
test_utils ‑ test_cleanup_infra_deployments_index_scenarios
test_utils ‑ test_cleanup_infra_deployments_max_workers_limit
test_utils ‑ test_cleanup_infra_deployments_parallel_mode
…
test_apimtypes ‑ testget_project_root_functionality
test_azure_resources ‑ test_does_resource_group_exist_false
test_azure_resources ‑ test_does_resource_group_exist_true
test_azure_resources ‑ test_get_account_info_failure
test_azure_resources ‑ test_get_account_info_no_json
test_azure_resources ‑ test_get_account_info_success
test_azure_resources ‑ test_get_apim_url_failure
test_azure_resources ‑ test_get_apim_url_no_gateway
test_azure_resources ‑ test_get_apim_url_success
test_azure_resources ‑ test_get_appgw_endpoint_no_gateway
…

♻️ This comment has been updated with latest results.

@simonkurtz-MSFT simonkurtz-MSFT merged commit 72c4e8e into main Dec 12, 2025
9 checks passed
@simonkurtz-MSFT simonkurtz-MSFT deleted the feature/python-refactoring branch December 12, 2025 20:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants