Skip to content

Commit

Permalink
Merge branch 'main' into feature/http-language-support
Browse files Browse the repository at this point in the history
  • Loading branch information
koros committed Dec 4, 2024
2 parents 51c6e25 + f1efd74 commit cfb3024
Show file tree
Hide file tree
Showing 36 changed files with 1,525 additions and 419 deletions.
139 changes: 81 additions & 58 deletions .azure-pipelines/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,44 @@ extends:
artifactName: AppSettings
targetPath: "$(Build.ArtifactStagingDirectory)/AppSettings"

# upload the scripts directory as scripts artifact

- task: 1ES.PublishPipelineArtifact@1
displayName: "Publish Artifact: scripts"
inputs:
artifactName: scripts
targetPath: $(Build.SourcesDirectory)/scripts

# upload the csproj file as csproj artifact

- task: CopyFiles@2
displayName: Prepare staging folder for upload
inputs:
targetFolder: $(Build.ArtifactStagingDirectory)/csproj
sourceFolder: $(Build.SourcesDirectory)/src/kiota
Contents: "*.csproj"

- task: 1ES.PublishPipelineArtifact@1
displayName: "Publish Artifact: csproj"
inputs:
artifactName: csproj
targetPath: "$(Build.ArtifactStagingDirectory)/csproj"

# upload the changelog file as changelog artifact

- task: CopyFiles@2
displayName: Prepare staging folder for upload
inputs:
targetFolder: $(Build.ArtifactStagingDirectory)/changelog
sourceFolder: $(Build.SourcesDirectory)
Contents: "CHANGELOG.md"

- task: 1ES.PublishPipelineArtifact@1
displayName: "Publish Artifact: changelog"
inputs:
artifactName: changelog
targetPath: "$(Build.ArtifactStagingDirectory)/changelog"

- job: build
dependsOn: [update_appsettings]
pool:
Expand All @@ -128,17 +166,15 @@ extends:
baselineFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnbaselines
suppression:
suppressionFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnsuppress
inputs:
- input: pipelineArtifact
artifactName: AppSettings
targetPath: $(Build.ArtifactStagingDirectory)/AppSettings
steps:
- checkout: self
clean: true
submodules: true

- task: DownloadPipelineArtifact@2
inputs:
artifact: AppSettings
source: current
targetPath: $(Build.ArtifactStagingDirectory)/AppSettings

- pwsh: |
Copy-Item $(Build.ArtifactStagingDirectory)/AppSettings/appsettings.json $(Build.SourcesDirectory)/src/kiota/appsettings.json -Force -Verbose
displayName: Copy the appsettings.json
Expand Down Expand Up @@ -318,7 +354,7 @@ extends:
inputs:
targetFolder: $(Build.ArtifactStagingDirectory)/Nugets
sourceFolder: $(Build.ArtifactStagingDirectory)
content: "*.nupkg"
Contents: "*.*nupkg"

- task: 1ES.PublishPipelineArtifact@1
displayName: "Publish Artifact: Nugets"
Expand All @@ -341,6 +377,10 @@ extends:
baselineFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnbaselines
suppression:
suppressionFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnsuppress
inputs:
- input: pipelineArtifact
artifactName: AppSettings
targetPath: $(Build.ArtifactStagingDirectory)/AppSettings

steps:
- checkout: self
Expand All @@ -355,12 +395,6 @@ extends:
inputs:
version: 8.x

- task: DownloadPipelineArtifact@2
inputs:
artifact: AppSettings
source: current
targetPath: $(Build.ArtifactStagingDirectory)/AppSettings

- pwsh: |
Copy-Item $(Build.ArtifactStagingDirectory)/AppSettings/appsettings.json $(Build.SourcesDirectory)/src/kiota/appsettings.json -Force -Verbose
displayName: Copy the appsettings.json
Expand Down Expand Up @@ -554,20 +588,18 @@ extends:
baselineFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnbaselines
suppression:
suppressionFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnsuppress
inputs:
- ${{ each distribution in parameters.distributions }}:
- input: pipelineArtifact
artifactName: Binaries_${{ distribution.jobPrefix }}
targetPath: $(Build.ArtifactStagingDirectory)/Binaries
steps:
- checkout: self
clean: true
submodules: true
- task: NodeTool@0
inputs:
versionSpec: "18.x"
- ${{ each distribution in parameters.distributions }}:
- task: DownloadPipelineArtifact@2
displayName: Download ${{ distribution.jobPrefix }} binaries from artifacts
inputs:
artifact: Binaries_${{ distribution.jobPrefix }}
source: current
targetPath: $(Build.ArtifactStagingDirectory)/Binaries
- pwsh: $(Build.SourcesDirectory)/scripts/get-prerelease-version.ps1 -currentBranch $(Build.SourceBranch) -previewBranch ${{ parameters.previewBranch }}
displayName: "Set version suffix"
- pwsh: $(Build.SourcesDirectory)/scripts/get-version-from-csproj.ps1
Expand Down Expand Up @@ -656,27 +688,23 @@ extends:
os: linux
image: ubuntu-latest
templateContext:
sdl:
baseline:
baselineFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnbaselines
suppression:
suppressionFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnsuppress
type: releaseJob
isProduction: true
inputs:
- input: pipelineArtifact
artifactName: VSCode
targetPath: $(Pipeline.Workspace)/VSCode
- input: pipelineArtifact
artifactName: scripts
targetPath: "$(Pipeline.Workspace)/scripts"
dependsOn:
- github_release
steps:
- download: none
- checkout: self
clean: true
submodules: true
- task: DownloadPipelineArtifact@2
inputs:
artifact: VSCode
source: current
- task: NodeTool@0
inputs:
versionSpec: "18.x"
- pwsh: npm i -g @vscode/vsce
- pwsh: $(Build.SourcesDirectory)/scripts/get-prerelease-version.ps1 -currentBranch $(Build.SourceBranch) -previewBranch ${{ parameters.previewBranch }}
- pwsh: $(Pipeline.Workspace)/scripts/get-prerelease-version.ps1 -currentBranch $(Build.SourceBranch) -previewBranch ${{ parameters.previewBranch }}
displayName: "Set version suffix"
- task: AzureCLI@2
inputs:
Expand All @@ -685,7 +713,7 @@ extends:
scriptLocation: "inlineScript"
inlineScript: |
$aadToken = az account get-access-token --query accessToken --resource 499b84ac-1321-427f-aa17-267ca6975798 -o tsv
Get-ChildItem -Path $(Pipeline.Workspace) -Filter *.vsix -Recurse | ForEach-Object {
Get-ChildItem -Path $(Pipeline.Workspace)/VSCode -Filter *.vsix -Recurse | ForEach-Object {
$packagePath = $_.FullName
$manifestPath = $packagePath.Replace("vsix", "manifest")
$signaturePath = $packagePath.Replace("vsix", "signature.p7s")
Expand Down Expand Up @@ -716,35 +744,32 @@ extends:
- input: pipelineArtifact
artifactName: Nugets
targetPath: "$(Pipeline.Workspace)"
sdl:
baseline:
baselineFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnbaselines
suppression:
suppressionFile: $(Build.SourcesDirectory)/guardian/SDL/common/.gdnsuppress
- input: pipelineArtifact
artifactName: scripts
targetPath: "$(Pipeline.Workspace)/scripts"
- input: pipelineArtifact
artifactName: csproj
targetPath: "$(Pipeline.Workspace)/csproj"
- input: pipelineArtifact
artifactName: changelog
targetPath: "$(Pipeline.Workspace)/changelog"
- ${{ each distribution in parameters.distributions }}:
- input: pipelineArtifact
artifactName: Binaries_${{ distribution.jobPrefix }}
dependsOn: []
environment: kiota-github-releases
strategy:
runOnce:
deploy:
steps:
- download: none
- checkout: self
clean: true
submodules: true
- ${{ each distribution in parameters.distributions }}:
- task: DownloadPipelineArtifact@2
displayName: Download ${{ distribution.jobPrefix }} binaries from artifacts
inputs:
artifact: Binaries_${{ distribution.jobPrefix }}
source: current
- pwsh: $(Build.SourcesDirectory)/scripts/get-prerelease-version.ps1 -currentBranch $(Build.SourceBranch) -previewBranch ${{ parameters.previewBranch }}
- pwsh: $(Pipeline.Workspace)/scripts/get-prerelease-version.ps1 -currentBranch $(Build.SourceBranch) -previewBranch ${{ parameters.previewBranch }}
displayName: "Set version suffix"
- pwsh: $(Build.SourcesDirectory)/scripts/get-version-from-csproj.ps1
- pwsh: $(Pipeline.Workspace)/scripts/get-version-from-csproj.ps1 -csprojPath "$(Pipeline.Workspace)/csproj/kiota.csproj"
displayName: "Get Kiota's version-number from .csproj"
- pwsh: $(Build.SourcesDirectory)/scripts/get-release-notes.ps1 -version $(artifactVersion) -createNotes
- pwsh: $(Pipeline.Workspace)/scripts/get-release-notes.ps1 -version $(artifactVersion) -createNotes -changelogPath "$(Pipeline.Workspace)/changelog/CHANGELOG.md"
condition: eq(variables['isPrerelease'], 'false')
displayName: "Get release notes from CHANGELOG.md"
- pwsh: $(Build.SourcesDirectory)/scripts/get-release-notes.ps1 -version Unreleased -createNotes
- pwsh: $(Pipeline.Workspace)/scripts/get-release-notes.ps1 -version Unreleased -createNotes -changelogPath "$(Pipeline.Workspace)/changelog/CHANGELOG.md"
condition: eq(variables['isPrerelease'], 'true')
displayName: "Get release notes from CHANGELOG.md"
- task: GitHubRelease@1
Expand All @@ -755,7 +780,7 @@ extends:
tag: "v$(artifactVersion)"
title: "v$(artifactVersion)"
releaseNotesSource: filePath
releaseNotesFilePath: $(Build.SourcesDirectory)/release-notes.txt
releaseNotesFilePath: $(Pipeline.Workspace)/changelog/release-notes.txt
assets: |
$(Pipeline.Workspace)/*.zip
$(Pipeline.Workspace)/*.vsix
Expand All @@ -770,7 +795,7 @@ extends:
tag: "v$(artifactVersion)$(versionSuffix)"
title: "v$(artifactVersion)$(versionSuffix)"
releaseNotesSource: filePath
releaseNotesFilePath: $(Build.SourcesDirectory)/release-notes.txt
releaseNotesFilePath: $(Pipeline.Workspace)/changelog/release-notes.txt
assets: |
$(Pipeline.Workspace)/*.zip
$(Pipeline.Workspace)/*.vsix
Expand All @@ -797,7 +822,6 @@ extends:
runOnce:
deploy:
steps:
- download: none
- powershell: |
Remove-Item "$(Pipeline.Workspace)/Microsoft.OpenApi.Kiota.Builder.*.nupkg" -Verbose
displayName: remove other nupkgs to avoid duplication
Expand Down Expand Up @@ -827,7 +851,6 @@ extends:
runOnce:
deploy:
steps:
- download: none
- powershell: |
Remove-Item "$(Pipeline.Workspace)/Microsoft.OpenApi.Kiota.*.nupkg" -Verbose -Exclude "*.Builder.*"
displayName: remove other nupkgs to avoid duplication
Expand Down
32 changes: 32 additions & 0 deletions .github/workflows/check-translations.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Check Translations

on:
workflow_dispatch:
push:
branches: [main]
pull_request:

permissions:
contents: read

jobs:
check-translations:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22.x

- name: Run translation check
run: ./scripts/check-translations.ps1
shell: pwsh

- name: Upload untranslated strings
uses: actions/upload-artifact@v4
with:
name: untranslated-strings
path: ./untranslated_strings.html
6 changes: 4 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed

- Fixed python generation in scenarios with opening/closing tags for code comments. [#5636](https://github.com/microsoft/kiota/issues/5636)
- Fixed Python error when a class inherits from a base class and implements an interface. [5637](https://github.com/microsoft/kiota/issues/5637)
- Fix anyOf/oneOf generation in TypeScript. [5353](https://github.com/microsoft/kiota/issues/5353)
- Fixed Python error when a class inherits from a base class and implements an interface. [#5637](https://github.com/microsoft/kiota/issues/5637)
- Fixed a bug where one/any schemas with single schema entries would be missing properties. [#5808](https://github.com/microsoft/kiota/issues/5808)
- Fixed anyOf/oneOf generation in TypeScript. [5353](https://github.com/microsoft/kiota/issues/5353)
- Fixed invalid code in Php caused by "*/*/" in property description. [5635](https://github.com/microsoft/kiota/issues/5635)
- Fixed a bug where discriminator property name lookup could end up in an infinite loop. [#5771](https://github.com/microsoft/kiota/issues/5771)
- Fixed TypeScript generation error when generating usings from shaken serializers. [#5634](https://github.com/microsoft/kiota/issues/5634)
- Multiple fixed and improvements in OpenAPI description generation for plugins. [#5806](https://github.com/microsoft/kiota/issues/5806)

## [1.20.0] - 2024-11-07

Expand Down
26 changes: 13 additions & 13 deletions it/python/requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ platformdirs==4.3.6 ; python_version >= '3.7'

pluggy==1.5.0 ; python_version >= '3.7'

pylint==3.3.1
pylint==3.3.2

pytest==8.3.3
pytest==8.3.4

pytest-asyncio==0.24.0

Expand All @@ -66,7 +66,7 @@ yapf==0.43.0

zipp==3.21.0 ; python_version >= '3.7'

aiohttp==3.11.7 ; python_version >= '3.6'
aiohttp==3.11.9 ; python_version >= '3.6'

aiosignal==1.3.1 ; python_version >= '3.7'

Expand All @@ -82,7 +82,7 @@ azure-identity==1.19.0

cffi==1.17.1

cryptography==43.0.3 ; python_version >= '3.7'
cryptography==44.0.0 ; python_version >= '3.7'

frozenlist==1.5.0 ; python_version >= '3.7'

Expand All @@ -98,19 +98,19 @@ httpx[http2]==0.27.2

hyperframe==6.0.1 ; python_full_version >= '3.6.1'

microsoft-kiota-abstractions==1.6.2
microsoft-kiota-abstractions==1.6.3

microsoft-kiota-authentication-azure==1.6.2
microsoft-kiota-authentication-azure==1.6.3

microsoft-kiota-http==1.6.2
microsoft-kiota-http==1.6.3

microsoft-kiota-serialization-json==1.6.2
microsoft-kiota-serialization-json==1.6.3

microsoft-kiota-serialization-text==1.6.2
microsoft-kiota-serialization-text==1.6.3

microsoft-kiota-serialization-form==1.6.2
microsoft-kiota-serialization-form==1.6.3

microsoft-kiota-serialization-multipart==1.6.2
microsoft-kiota-serialization-multipart==1.6.3

msal==1.31.1

Expand All @@ -122,7 +122,7 @@ portalocker==3.0.0 ; python_version >= '3.5' and platform_system == 'Windows'

pycparser==2.22

pyjwt[crypto]==2.10.0 ; python_version >= '3.7'
pyjwt[crypto]==2.10.1 ; python_version >= '3.7'

python-dateutil==2.9.0.post0 ; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2'

Expand All @@ -136,5 +136,5 @@ sniffio==1.3.1 ; python_version >= '3.7'

uritemplate==4.1.1 ; python_version >= '3.6'

yarl==1.18.0 ; python_version >= '3.7'
yarl==1.18.3 ; python_version >= '3.7'

Loading

0 comments on commit cfb3024

Please sign in to comment.