Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…into get_testserver_working

* 'master' of https://github.com/Azure/azure-sdk-for-python: (55 commits)
  [AppConfig] mypy fixes (Azure#18858)
  [translation] renames (Azure#19285)
  [Key Vault] Update metadata for release (Azure#19286)
  [AppConfig] enable samples (Azure#18857)
  KeyVaultBackupOperation -> KeyVaultBackupResult (Azure#19284)
  renaming (Azure#19280)
  [Key Vault] Custom polling method for admin backup client (Azure#19204)
  [textanalytics] add ARM template + run samples in CI (Azure#19270)
  removed example from description (Azure#18781)
  [Key Vault] Update READMEs with RBAC information (Azure#19275)
  Sync eng/common directory with azure-sdk-tools for PR 1688 (Azure#19272)
  update all ubuntu vmImage to 20.04 (Azure#19227)
  add base class for feedback (Azure#19265)
  Enable tests for integration samples (Azure#18531)
  docs: fix a few simple typos (Azure#19127)
  Increment package version after release of azure-eventgrid (Azure#19197)
  Increment package version after release of azure-monitor-query (Azure#19208)
  earliest versions of communication identity tests are set up improperly. skip 1.0.0 in regression testing (Azure#19258)
  Run mypy in azure-keyvault-administration CI (Azure#19246)
  [text analytics] change return type of analyze actions to list of list (Azure#18994)
  ...
  • Loading branch information
iscai-msft committed Jun 17, 2021
2 parents 405d5e8 + 22cc32f commit fb692df
Show file tree
Hide file tree
Showing 976 changed files with 50,002 additions and 542,818 deletions.
3 changes: 3 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@
# PRLabel: %Monitor - Exporter
/sdk/monitor/azure-monitor-opentelemetry-exporter @rakshith91 @lmazuel @lzchen

# PRLabel: %Monitor - Log
/sdk/monitor/azure-monitor-query @rakshith91

# PRLabel: %Consumption
/sdk/consumption/ @sandeepnl

Expand Down
2 changes: 1 addition & 1 deletion doc/dev/mgmt/generation.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ autorest readme.md --python --use="@microsoft.azure/autorest.python@~4.0.71" --p

Which means "Generate the Python code for the Swagger mentioned in this readme, using autorest for Pyton v4.0.71 or above (but not v5), do not generate async files, generate multiapi if supported (if not ignore), and assume the package was already generated and it's an update"

In pratical terms, this is not necessary since the Python SDK has the necessary tooling to simplify to just specify the readme.md:
In practical terms, this is not necessary since the Python SDK has the necessary tooling to simplify to just specify the readme.md:

- Checkout the branch
- Checkout the RestAPI specs repo
Expand Down
1 change: 1 addition & 0 deletions eng/.docsettings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ known_content_issues:
- ['sdk/core/azure-servicemanagement-legacy/README.md', '#4554']
- ['sdk/eventgrid/azure-eventgrid/README.md', '#4554']
- ['sdk/monitor/azure-monitor-query/README.md', '#4554']
- ['sdk/monitor/azure-monitor-query/samples/README.md', '#4554']
- ['sdk/graphrbac/azure-graphrbac/README.md', '#4554']
- ['sdk/loganalytics/azure-loganalytics/README.md', '#4554']
- ['sdk/servicebus/azure-servicebus/README.md', '#4554']
Expand Down
54 changes: 48 additions & 6 deletions eng/common/scripts/ChangeLog-Operations.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -37,30 +37,45 @@ function Get-ChangeLogEntriesFromContent {
return $null
}

$changelogEntry = $null
$sectionName = $null
$changeLogEntries = [Ordered]@{}
try {
# walk the document, finding where the version specifiers are and creating lists
$changeLogEntry = $null
foreach ($line in $changeLogContent) {
if ($line -match $RELEASE_TITLE_REGEX) {
$changeLogEntry = [pscustomobject]@{
$changeLogEntry = [pscustomobject]@{
ReleaseVersion = $matches["version"]
ReleaseStatus = $matches["releaseStatus"]
ReleaseTitle = "## {0} {1}" -f $matches["version"], $matches["releaseStatus"]
ReleaseContent = @()
Sections = @{}
}
$changeLogEntries[$changeLogEntry.ReleaseVersion] = $changeLogEntry
}
else {
if ($changeLogEntry) {
if ($line.Trim() -match "^###\s(?<sectionName>.*)")
{
$sectionName = $matches["sectionName"].Trim()
$changeLogEntry.Sections[$sectionName] = @()
$changeLogEntry.ReleaseContent += $line
continue
}

if ($sectionName)
{
$changeLogEntry.Sections[$sectionName] += $line
}

$changeLogEntry.ReleaseContent += $line
}
}
}
}
catch {
Write-Host "Error parsing Changelog."
Write-Host $_.Exception.Message
Write-Error "Error parsing Changelog."
Write-Error $_
}
return $changeLogEntries
}
Expand Down Expand Up @@ -160,6 +175,21 @@ function Confirm-ChangeLogEntry {
LogError "Entry has no content. Please ensure to provide some content of what changed in this version."
return $false
}

$emptySections = @()
foreach ($key in $changeLogEntry.Sections.Keys)
{
$sectionContent = $changeLogEntry.Sections[$key]
if ([System.String]::IsNullOrWhiteSpace(($sectionContent | Out-String)))
{
$emptySections += $key
}
}
if ($emptySections.Count -gt 0)
{
LogError "The changelog entry has the following sections with no content ($($emptySections -join ', ')). Please ensure to either remove the empty sections or add content to the section."
return $false
}
}
return $true
}
Expand Down Expand Up @@ -195,9 +225,21 @@ function New-ChangeLogEntry {
return $null
}

if (!$Content) { $Content = @() }
if (!$Content) {
$Content = @()
$Content += ""
$Content += "### Features Added"
$Content += ""
$Content += "### Breaking Changes"
$Content += ""
$Content += "### Key Bugs Fixed"
$Content += ""
$Content += "### Fixed"
$Content += ""
$Content += ""
}

$newChangeLogEntry = [pscustomobject]@{
$newChangeLogEntry = [pscustomobject]@{
ReleaseVersion = $Version
ReleaseStatus = $Status
ReleaseTitle = "## $Version $Status"
Expand Down
9 changes: 5 additions & 4 deletions eng/common/scripts/Update-ChangeLog.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ param (
[String]$ChangelogPath,
[String]$ReleaseDate
)
Set-StrictMode -Version 3

. (Join-Path $PSScriptRoot common.ps1)

Expand All @@ -39,11 +40,11 @@ if ($ReleaseDate)
exit 1
}
}
elseif ($Unreleased)
elseif ($Unreleased)
{
$ReleaseStatus = $CHANGELOG_UNRELEASED_STATUS
}
else
else
{
$ReleaseStatus = "$(Get-Date -Format $CHANGELOG_DATE_FORMAT)"
$ReleaseStatus = "($ReleaseStatus)"
Expand All @@ -61,7 +62,7 @@ if ([string]::IsNullOrEmpty($ChangelogPath))
$ChangelogPath = $pkgProperties.ChangeLogPath
}

if (!(Test-Path $ChangelogPath))
if (!(Test-Path $ChangelogPath))
{
LogError "Changelog path [$ChangelogPath] is invalid."
exit 1
Expand Down Expand Up @@ -103,7 +104,7 @@ if ($LatestsSorted[0] -ne $Version) {
LogWarning "Version [$Version] is older than the latestversion [$LatestVersion] in the changelog. Consider using a more recent version."
}

if ($ReplaceLatestEntryTitle)
if ($ReplaceLatestEntryTitle)
{
$newChangeLogEntry = New-ChangeLogEntry -Version $Version -Status $ReleaseStatus -Content $ChangeLogEntries[$LatestVersion].ReleaseContent
LogDebug "Resetting latest entry title to [$($newChangeLogEntry.ReleaseTitle)]"
Expand Down
3 changes: 2 additions & 1 deletion eng/common/scripts/Verify-ChangeLog.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,12 @@ param (
[string]$ServiceDirectory,
[boolean]$ForRelease = $False
)
Set-StrictMode -Version 3

. (Join-Path $PSScriptRoot common.ps1)

$validChangeLog = $false
if ($ChangeLogLocation -and $VersionString)
if ($ChangeLogLocation -and $VersionString)
{
$validChangeLog = Confirm-ChangeLogEntry -ChangeLogLocation $ChangeLogLocation -VersionString $VersionString -ForRelease $ForRelease
}
Expand Down
2 changes: 1 addition & 1 deletion eng/pipelines/autorest_checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
displayName: 'Run AutoRest'

pool:
vmImage: 'ubuntu-18.04'
vmImage: 'ubuntu-20.04'

steps:
- task: NodeTool@0
Expand Down
2 changes: 1 addition & 1 deletion eng/pipelines/generate-all-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
timeoutInMinutes: 120

pool:
vmImage: 'ubuntu-18.04'
vmImage: 'ubuntu-20.04'

steps:
- task: UsePythonVersion@0
Expand Down
10 changes: 10 additions & 0 deletions eng/pipelines/templates/jobs/ci.tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ parameters:
- name: TestMarkArgument
type: string
default: ''
- name: BeforeTestSteps
type: object
default: []
- name: AfterTestSteps
type: object
default: []
- name: BuildTargetingString
type: string
default: 'azure-*'
Expand Down Expand Up @@ -110,3 +116,7 @@ jobs:
parameters:
ServiceDirectory: ${{ parameters.ServiceDirectory }}
BuildTargetingString: ${{ parameters.BuildTargetingString }}

- ${{ each step in parameters.BeforeTestSteps }}:
- ${{ step }}
AfterTestSteps: ${{ parameters.AfterTestSteps }}
20 changes: 14 additions & 6 deletions eng/pipelines/templates/jobs/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ parameters:
- name: TestMarkArgument
type: string
default: ''
- name: BeforeTestSteps
type: object
default: []
- name: AfterTestSteps
type: object
default: []
- name: BuildTargetingString
type: string
default: 'azure-*'
Expand Down Expand Up @@ -54,8 +60,8 @@ jobs:
- template: ../variables/globals.yml

pool:
name: azsdk-pool-mms-ubuntu-1804-general
vmImage: MMSUbuntu18.04
name: azsdk-pool-mms-ubuntu-2004-general
vmImage: MMSUbuntu20.04

steps:
- template: ../steps/build-artifacts.yml
Expand All @@ -82,8 +88,8 @@ jobs:
- 'Build'

pool:
name: azsdk-pool-mms-ubuntu-1804-general
vmImage: MMSUbuntu18.04
name: azsdk-pool-mms-ubuntu-2004-general
vmImage: MMSUbuntu20.04

steps:
- template: /eng/common/pipelines/templates/steps/check-spelling.yml
Expand Down Expand Up @@ -121,6 +127,8 @@ jobs:
ServiceDirectory: ${{ parameters.ServiceDirectory }}
TestPipeline: ${{ parameters.TestPipeline }}
TestMarkArgument: ${{ parameters.TestMarkArgument }}
BeforeTestSteps: ${{ parameters.BeforeTestSteps }}
AfterTestSteps: ${{ parameters.AfterTestSteps }}
BuildTargetingString: ${{ parameters.BuildTargetingString }}
TestTimeoutInMinutes: ${{ parameters.TestTimeoutInMinutes }}
ToxEnvParallel: ${{ parameters.ToxEnvParallel }}
Expand Down Expand Up @@ -160,8 +168,8 @@ jobs:
- 'Build'

pool:
name: azsdk-pool-mms-ubuntu-1804-general
vmImage: MMSUbuntu18.04
name: azsdk-pool-mms-ubuntu-2004-general
vmImage: MMSUbuntu20.04

steps:
- template: ../steps/test_regression.yml
Expand Down
4 changes: 2 additions & 2 deletions eng/pipelines/templates/jobs/publish-coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ parameters:
jobs:
- job: Publish_Code_Coverage
pool:
name: azsdk-pool-mms-ubuntu-1804-general
vmImage: MMSUbuntu18.04
name: azsdk-pool-mms-ubuntu-2004-general
vmImage: MMSUbuntu20.04

steps:
- task: UsePythonVersion@0
Expand Down
36 changes: 18 additions & 18 deletions eng/pipelines/templates/jobs/smoke.tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,26 +43,26 @@ jobs:
Python_27_Linux (AzureCloud):
PythonVersion: '2.7'
SkipAsyncInstall: true
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-azure-cloud-test-resources)
ArmTemplateParameters: $(azureCloudArmParameters)
Python_37_Linux (AzureCloud):
PythonVersion: '3.7'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-azure-cloud-test-resources)
ArmTemplateParameters: $(azureCloudArmParameters)
Python_38_Linux (AzureCloud):
PythonVersion: '3.8'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-azure-cloud-test-resources)
ArmTemplateParameters: $(azureCloudArmParameters)
Python_38_Linux (AzureCloud Canary):
PythonVersion: '3.8'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-azure-cloud-test-resources-preview)
ArmTemplateParameters: $(azureCloudArmParameters)
Location: 'eastus2euap'
Expand All @@ -74,8 +74,8 @@ jobs:
ArmTemplateParameters: $(azureCloudArmParameters)
Python_38_Windows (AzureCloud):
PythonVersion: '3.8'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-azure-cloud-test-resources)
ArmTemplateParameters: $(azureCloudArmParameters)
Python_37_Mac (AzureCloud):
Expand All @@ -92,27 +92,27 @@ jobs:
ArmTemplateParameters: $(azureCloudArmParameters)
Python_38_Linux (AzureUSGovernment):
PythonVersion: '3.8'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu120.04"
SubscriptionConfiguration: $(sub-config-gov-test-resources)
ArmTemplateParameters: $(azureUSGovernmentArmParameters)
Python_37_Windows (AzureUSGovernment):
PythonVersion: '3.7'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-gov-test-resources)
ArmTemplateParameters: $(azureUSGovernmentArmParameters)
Python_38_Linux (AzureChinaCloud):
PythonVersion: '3.8'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-cn-test-resources)
Location: 'chinanorth'
ArmTemplateParameters: $(azureChinaCloudArmParameters)
Python_37_Windows (AzureChinaCloud):
PythonVersion: '3.7'
Pool: "azsdk-pool-mms-ubuntu-1804-general"
OSVmImage: "MMSUbuntu18.04"
Pool: "azsdk-pool-mms-ubuntu-2004-general"
OSVmImage: "MMSUbuntu20.04"
SubscriptionConfiguration: $(sub-config-cn-test-resources)
Location: 'chinanorth'
ArmTemplateParameters: $(azureChinaCloudArmParameters)
Expand Down
2 changes: 1 addition & 1 deletion eng/pipelines/templates/jobs/tests-nightly-python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
timeoutInMinutes: 90

pool:
vmImage: 'ubuntu-18.04'
vmImage: 'ubuntu-20.04'

steps:
- task: UsePythonVersion@0
Expand Down
4 changes: 2 additions & 2 deletions eng/pipelines/templates/stages/archetype-conda-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ stages:
environment: pypi

pool:
name: azsdk-pool-mms-ubuntu-1804-general
vmImage: MMSUbuntu18.04
name: azsdk-pool-mms-ubuntu-2004-general
vmImage: MMSUbuntu20.04

strategy:
runOnce:
Expand Down
Loading

0 comments on commit fb692df

Please sign in to comment.