Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
4 changes: 3 additions & 1 deletion doc/eng_sys_checks.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ This is the most useful skip, but the following skip variables are also supporte
- Omit checking that a package's dependencies are on PyPI before releasing.
- `Skip.KeywordCheck`
- Omit checking that a package's keywords are correctly formulated before releasing.
- `Skip.Black`
- Omit checking `black` in the `analyze` job.

## The pyproject.toml

Expand Down Expand Up @@ -172,7 +174,7 @@ You can enable test logging in a pipeline by setting the queue time variable `PY

`PYTEST_LOG_LEVEL=INFO`

This also works locally with tox by setting the `PYTEST_LOG_LEVEL` environment variable.
This also works locally with tox by setting the `PYTEST_LOG_LEVEL` environment variable.

Note that if you want DEBUG level logging with sensitive information unredacted in the test logs, then you still must pass `logging_enable=True` into the client(s) being used in tests.

Expand Down
9 changes: 3 additions & 6 deletions eng/pipelines/templates/steps/analyze.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ parameters:
Artifacts: []
TestPipeline: false
VerifyAutorest: false
ValidateFormatting: false
GenerateApiReviewForManualOnly: false

# Please use `$(TargetingString)` to refer to the python packages glob string. This variable is set from resolve-package-targeting.yml.
Expand Down Expand Up @@ -110,11 +109,9 @@ steps:
ServiceDirectory: ${{ parameters.ServiceDirectory }}
AdditionalTestArgs: ${{ parameters.AdditionalTestArgs }}

- ${{ if parameters.ValidateFormatting }}:
- template: run_black.yml
parameters:
ServiceDirectory: ${{ parameters.ServiceDirectory }}
ValidateFormatting: ${{ parameters.ValidateFormatting }}
- template: run_black.yml
parameters:
ServiceDirectory: ${{ parameters.ServiceDirectory }}

- task: PythonScript@0
displayName: 'Run Keyword Validation Check'
Expand Down
12 changes: 8 additions & 4 deletions eng/pipelines/templates/steps/run_black.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,14 @@ steps:
- task: PythonScript@0
displayName: 'Run Black'
inputs:
scriptPath: 'scripts/devops_tasks/validate_formatting.py'
scriptPath: 'scripts/devops_tasks/dispatch_tox.py'
arguments: >-
"$(TargetingString)"
--service_directory="${{ parameters.ServiceDirectory }}"
--validate="${{ parameters.ValidateFormatting }}"
--mark_arg="${{ parameters.TestMarkArgument }}"
--service="${{ parameters.ServiceDirectory }}"
--toxenv="black"
--disablecov
--filter-type="Omit_management"
${{ parameters.AdditionalTestArgs }}
env: ${{ parameters.EnvVars }}
condition: and(succeededOrFailed(), ne(variables['Skip.Pylint'],'true'))
condition: and(succeededOrFailed(), ne(variables['Skip.Black'],'true'))
2 changes: 1 addition & 1 deletion eng/pipelines/templates/steps/run_pylint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ steps:
--filter-type="Omit_management"
${{ parameters.AdditionalTestArgs }}
env: ${{ parameters.EnvVars }}
condition: and(succeededOrFailed(), ne(variables['Skip.Pylint'],'true'))
condition: and(succeededOrFailed(), ne(variables['Skip.Black'],'true'))
107 changes: 0 additions & 107 deletions scripts/devops_tasks/validate_formatting.py

This file was deleted.

1 change: 0 additions & 1 deletion sdk/core/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ extends:
parameters:
ServiceDirectory: core
BuildTargetingString: "*"
ValidateFormatting: true
TestProxy: false
TestTimeoutInMinutes: 120
Artifacts:
Expand Down
1 change: 0 additions & 1 deletion sdk/evaluation/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ extends:
template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml
parameters:
ServiceDirectory: evaluation
ValidateFormatting: true
TestProxy: true
# This custom matrix config should be dropped once:
# * Once azure-ai-ml supports 3.13 (currently crashes due to type annotation)
Expand Down
1 change: 0 additions & 1 deletion sdk/pullrequest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,5 @@ extends:
parameters:
ServiceDirectory: ${{ parameters.Service }}
BuildTargetingString: "*"
ValidateFormatting: true
TestProxy: true
TestTimeOutInMinutes: 180
1 change: 0 additions & 1 deletion sdk/tables/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ extends:
parameters:
TestProxy: true
ServiceDirectory: tables
ValidateFormatting: true
Artifacts:
- name: azure-data-tables
safeName: azuredatatables
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ extends:
parameters:
ServiceDirectory: core
BuildTargetingString: "*"
ValidateFormatting: true
TestProxy: false
TestTimeoutInMinutes: 120
Artifacts:
Expand Down