Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions scripts/ci/azdev_linter_style.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,9 @@ def azdev_on_external_extension(index_json, azdev_type):
# azdev test support external extension
# azdev_extension.style()

logger.info('Checking service name for external extensions')
service_name.check()
logger.info('Checking service name for external extensions: %s', name)
Copy link

Copilot AI Oct 29, 2025

Choose a reason for hiding this comment

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

The conditional skip of service name check lacks an explanation of why 'deploy-to-azure' requires special handling. Add a comment explaining the reason for this exception to help future maintainers understand the decision.

Suggested change
logger.info('Checking service name for external extensions: %s', name)
logger.info('Checking service name for external extensions: %s', name)
# 'deploy-to-azure' is a meta-extension used for deployment and does not require a service name check.

Copilot uses AI. Check for mistakes.
if name != 'deploy-to-azure':
service_name.check()
Comment on lines +208 to +209
Copy link

Copilot AI Oct 29, 2025

Choose a reason for hiding this comment

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

The hardcoded extension name 'deploy-to-azure' creates a special case that reduces maintainability. Consider using a configuration-based approach such as a list/set of excluded extensions (e.g., SKIP_SERVICE_NAME_CHECK = {'deploy-to-azure'}) defined as a constant at module level, making it easier to manage multiple exceptions in the future.

Copilot uses AI. Check for mistakes.

az_extension.remove()

Expand Down Expand Up @@ -245,7 +246,7 @@ def azdev_on_internal_extension(modified_files, azdev_type):
logger.error(statement_msg)
exit(1)

logger.info('Checking service name for internal extensions')
logger.info('Checking service name for internal extensions: %s', name)
service_name.check()

azdev_extension.remove()
Expand Down
Loading