Skip to content

Commit

Permalink
Annotate Azure.Security.KeyVault.Secrets for trim/AOT compat (#46613)
Browse files Browse the repository at this point in the history
* Annotate Azure.Security.KeyVault.Secrets for trim/AOT compat

* Remove ExpectedWarningsFilepath
  • Loading branch information
sbomer authored Oct 30, 2024
1 parent 5386869 commit 765f6ad
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
// Licensed under the MIT License.

using System;
using System.Diagnostics.CodeAnalysis;
using Azure.Core.Extensions;
using Azure.Security.KeyVault.Secrets;

Expand All @@ -24,6 +25,8 @@ public static IAzureClientBuilder<SecretClient, SecretClientOptions> AddSecretCl
/// <summary>
/// Registers a <see cref="SecretClient"/> instance with connection options loaded from the provided <paramref name="configuration"/> instance.
/// </summary>
[RequiresUnreferencedCode("Binding strongly typed objects to configuration values is not supported with trimming. Use the Configuration Binder Source Generator (EnableConfigurationBindingGenerator=true) instead.")]
[RequiresDynamicCode("Binding strongly typed objects to configuration values requires generating dynamic code at runtime, for example instantiating generic types. Use the Configuration Binder Source Generator (EnableConfigurationBindingGenerator=true) instead.")]
public static IAzureClientBuilder<SecretClient, SecretClientOptions> AddSecretClient<TBuilder, TConfiguration>(this TBuilder builder, TConfiguration configuration)
where TBuilder : IAzureClientFactoryBuilderWithConfiguration<TConfiguration>
{
Expand Down

This file was deleted.

2 changes: 1 addition & 1 deletion sdk/keyvault/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@ extends:
CheckAOTCompat: true
AOTTestInputs:
- ArtifactName: Azure.Security.KeyVault.Secrets
ExpectedWarningsFilepath: /Azure.Security.KeyVault.Secrets/tests/compatibility/ExpectedAotWarnings.txt
ExpectedWarningsFilepath: None

0 comments on commit 765f6ad

Please sign in to comment.