-
Notifications
You must be signed in to change notification settings - Fork 184
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
Multi-Output Binding Analyzer #2440
Conversation
/// <summary> | ||
/// CodeAction implementation which adds the HttpResultAttribute on the return type of a function using the multi-output bindings pattern. | ||
/// </summary> | ||
private sealed class AddHttpResultAttribute : CodeAction |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Debating on the necessity of a code-fix as we want the user to add the attribute where they want it, but we can assume that this case (use of IActionResult
in multi-output binding scenario) will be pretty common.
var newPropertyNode = propertyNode | ||
.AddAttributeLists(SyntaxFactory.AttributeList(SyntaxFactory.SingletonSeparatedList(attribute))); | ||
|
||
var newRoot = root.ReplaceNode(propertyNode, newPropertyNode); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still working on getting the formatting correct for the fix (ideally using Roslyn Formatter). The PR is failing the test I have for this due to the indentation issue.
} | ||
} | ||
|
||
private static bool IsCustomType(ISymbol symbol) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would like reviews/ideas on how to approach determining whether or not a return type is a POCO.
new PackageIdentity("Microsoft.Azure.Functions.Worker.Extensions.Abstractions", "5.0.0"), | ||
new PackageIdentity("Microsoft.AspNetCore.Mvc.Core", "2.2.5"), | ||
new PackageIdentity("Microsoft.Extensions.Hosting.Abstractions", "6.0.0"), | ||
new PackageIdentity("Microsoft.Azure.Functions.Worker.Extensions.Http", "3.2.0-local"))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs to be updated once the actual package is released.
* Fix SignalR extensions DI issue * Make it idempotent `AddHostedService` with implementation type as `IHostedService` is forbidden.
The `_FunctionsPreBuild` msbuild target is currently being redefined.
* Adding context propagation for ActivityTraceFlags and TraceState.
* Fix incorrect build message * update release_notes.md * Refactor AzureFunctionVersion default and error checks * Add warning for v3 out of support * Address PR comments
…tedLinuxPlaceholder profile. FNH 1.0.10 (#2629) Removing WEBSITE_CONTAINER_READY=0 env variable check for DotnetIsolatedLinuxPlaceholder profile. Bumped version to 1.0.10
…ctionsNetHost Linux artifact (#2653) - Bumping patch version. New version is 1.0.11
…make the catch/rethrow effective
Issue describing the changes in this PR
resolves #2352
Pull request checklist
release_notes.md
Additional information
Tests need to be updated to use released packages following the release of the http extension (depends on host 4.34).