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

Fix Issue in Roslyn MetadataReference Resolver #3367

Closed
jorgerangel-msft opened this issue May 15, 2024 · 1 comment · Fixed by #3519
Closed

Fix Issue in Roslyn MetadataReference Resolver #3367

jorgerangel-msft opened this issue May 15, 2024 · 1 comment · Fixed by #3519
Assignees
Labels
emitter:client:csharp Issue for the C# client emitter: @typespec/http-client-csharp

Comments

@jorgerangel-msft
Copy link
Contributor

jorgerangel-msft commented May 15, 2024

It seems that the custom metadata resolver that was added to the generator may not be working as expected. Some generated types are still not being resolved correctly, ie. https://github.com/microsoft/typespec/blob/main/packages/http-client-csharp/generator/TestProjects/Local/Unbranded-TypeSpec/src/Generated/Models/ModelWithFormat.cs#L15 (System.Uri) should just be generated Uri.

We should investigate if the resolver has a bug, or if it's not correct to use it for this scenario. If so, we will need an alternative to the resolver that doesn't add all the trusted assemblies on disk to the generated project.

@jorgerangel-msft jorgerangel-msft added the emitter:client:csharp Issue for the C# client emitter: @typespec/http-client-csharp label May 15, 2024
@jorgerangel-msft
Copy link
Contributor Author

We can close this issue if adding the reduce method resolves this problem: Azure/autorest.csharp#4530.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
emitter:client:csharp Issue for the C# client emitter: @typespec/http-client-csharp
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants