Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Microsoft.Kiota.Abstractions needs version bump on kiota info output #4825

Closed
n20amaral opened this issue Jun 13, 2024 · 2 comments · Fixed by #4826
Closed

Microsoft.Kiota.Abstractions needs version bump on kiota info output #4825

n20amaral opened this issue Jun 13, 2024 · 2 comments · Fixed by #4826
Assignees
Labels
Csharp Pull requests that update .net code type:bug A broken experience
Milestone

Comments

@n20amaral
Copy link

What are you generating using Kiota, clients or plugins?

API Client/SDK

In what context or format are you using Kiota?

Nuget tool

Client library/SDK language

Csharp

Describe the bug

When I run kiota info -d <my openapi url> -l Csharp I got this packages list in the output:

Package Name                             Version
Microsoft.Kiota.Abstractions             1.9.0
Microsoft.Kiota.Authentication.Azure     1.1.7
Microsoft.Kiota.Http.HttpClientLibrary   1.4.3
Microsoft.Kiota.Serialization.Form       1.2.4
Microsoft.Kiota.Serialization.Json       1.3.3
Microsoft.Kiota.Serialization.Multipart  1.1.5
Microsoft.Kiota.Serialization.Text       1.2.2

If I add these specific versions, my project will fail to restore nuget packages because some of them require a higher version of Microsoft.Kiota.Abstractions. This is the error list with Detected package downgrade: Microsoft.Kiota.Abstractions from 1.9.1 to 1.9.0:

Microsoft.Kiota.Authentication.Azure 1.1.7 -> Microsoft.Kiota.Abstractions (>= 1.9.1 && < 2.0.0)
Microsoft.Kiota.Serialization.Form 1.2.4 -> Microsoft.Kiota.Abstractions (>= 1.9.1 && < 2.0.0)
Microsoft.Kiota.Http.HttpClientLibrary 1.4.3 -> Microsoft.Kiota.Abstractions (>= 1.9.1 && < 2.0.0)
Microsoft.Kiota.Serialization.Json 1.3.3 -> Microsoft.Kiota.Abstractions (>= 1.9.1 && < 2.0.0)
Microsoft.Kiota.Serialization.Multipart 1.1.5 -> Microsoft.Kiota.Abstractions (>= 1.9.1 && < 2.0.0)
Microsoft.Kiota.Serialization.Text 1.2.2 -> Microsoft.Kiota.Abstractions (>= 1.9.1 && < 2.0.0)

I generating my api client on an automated task, therefore I rely on the kiota info command output.

Expected behavior

Get the correct version for Microsoft.Kiota.Abstractions nuget package when running kiota info

How to reproduce

Run kiota info -d <my openapi url> -l Csharp

Open API description file

No response

Kiota Version

1.15.0+b535a94064cd8c14a022aaba42964467d5db525a

Latest Kiota version known to work for scenario above?(Not required)

No response

Known Workarounds

Install packages manually without specifying a version

Configuration

Linux Ubuntu x64

Debug output

Click to expand log ```
</details>


### Other information

_No response_
@n20amaral n20amaral added status:waiting-for-triage An issue that is yet to be reviewed or assigned type:bug A broken experience labels Jun 13, 2024
@github-project-automation github-project-automation bot moved this to Needs Triage 🔍 in Kiota Jun 13, 2024
@andrueastman
Copy link
Member

Thanks for catching this @n20amaral

This looks to be a bug a in the one of the release scripts as it looks like we should be looking at the last item in the items collection.

$response.items[0].upper

@baywet I'll take a look an confirm this with the library release scripts as well.

@andrueastman andrueastman moved this from Needs Triage 🔍 to Todo 📃 in Kiota Jun 13, 2024
@andrueastman andrueastman removed the status:waiting-for-triage An issue that is yet to be reviewed or assigned label Jun 13, 2024
@andrueastman andrueastman modified the milestones: Kiota v1.17, Kiota v1.16 Jun 13, 2024
@github-project-automation github-project-automation bot moved this from Todo 📃 to Done ✔️ in Kiota Jun 13, 2024
@msgraph-bot msgraph-bot bot added the Csharp Pull requests that update .net code label Jun 19, 2024
@andrueastman andrueastman self-assigned this Jul 4, 2024
@johnholliday
Copy link

Runtime exception searching for Microsoft.Kiota.Abstractions v1.9.1
But kiota.info produces the following:

The language CSharp is currently in Stable maturity level.
After generating code for this language, you need to install the following packages:
Package Name                             Version
Microsoft.Kiota.Abstractions             1.9.7
Microsoft.Kiota.Authentication.Azure     1.1.7
Microsoft.Kiota.Http.HttpClientLibrary   1.4.3
Microsoft.Kiota.Serialization.Form       1.2.5
Microsoft.Kiota.Serialization.Json       1.3.3
Microsoft.Kiota.Serialization.Multipart  1.1.5
Microsoft.Kiota.Serialization.Text       1.2.2

Downgrading to v1.9.1 produces compiler error in GetAsync() method:

return collectionResult?.AsList(); <<< undefined

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Csharp Pull requests that update .net code type:bug A broken experience
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants