Skip to content

!!! Correct condition controlling public API analysis !!! #26797

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

Merged
merged 5 commits into from
Oct 12, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions eng/targets/CSharp.Common.targets
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,18 @@
<NoWarn Condition="'$(IsTestProject)' == 'true' OR '$(IsTestAssetProject)' == 'true' OR '$(ISBenchmarkProject)' == 'true' OR '$(IsSampleProject)' == 'true'">$(NoWarn);CA1416</NoWarn>
</PropertyGroup>

<ItemGroup Condition=" Exists('$(MSBuildProjectDirectory)\PublicAPI.*.txt') AND
'$(IsImplementationProject)' == 'true' AND
<ItemGroup Condition=" Exists('$(MSBuildProjectDirectory)\PublicAPI.Shipped.txt') AND
'$(DotNetBuildFromSource)' != 'true' AND
'$(IsImplementationProject)' == 'true' AND
! $(RepoRelativeProjectDir.Contains('Tools')) ">
<Reference Include="Microsoft.CodeAnalysis.PublicApiAnalyzers" ExcludeAssets="Compile" PrivateAssets="All" />
</ItemGroup>
<Target Name="_CheckIgnoredPublicApiFiles"
BeforeTargets="Build;Restore"
Condition=" Exists('$(MSBuildProjectDirectory)\PublicAPI.*.txt') AND
!('$(IsImplementationProject)' == 'true' AND
Condition=" Exists('$(MSBuildProjectDirectory)\PublicAPI.Shipped.txt') AND
'$(DotNetBuildFromSource)' != 'true' AND
! $(RepoRelativeProjectDir.Contains('Tools'))) ">
!('$(IsImplementationProject)' == 'true' AND
! $(RepoRelativeProjectDir.Contains('Tools'))) ">
<Warning Text="Public API baseline files ignored." />
</Target>

Expand Down
43 changes: 22 additions & 21 deletions src/Components/Components/src/PublicAPI.Unshipped.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#nullable enable
Microsoft.AspNetCore.Components.BindConverter
Microsoft.AspNetCore.Components.BindElementAttribute
Microsoft.AspNetCore.Components.BindElementAttribute.BindElementAttribute(string! element, string? suffix, string! valueAttribute, string! changeAttribute) -> void
Expand Down Expand Up @@ -46,12 +47,12 @@ Microsoft.AspNetCore.Components.EventCallback
Microsoft.AspNetCore.Components.EventCallback.EventCallback(Microsoft.AspNetCore.Components.IHandleEvent? receiver, System.MulticastDelegate? delegate) -> void
Microsoft.AspNetCore.Components.EventCallback.HasDelegate.get -> bool
Microsoft.AspNetCore.Components.EventCallback.InvokeAsync() -> System.Threading.Tasks.Task!
Microsoft.AspNetCore.Components.EventCallback.InvokeAsync(object! arg) -> System.Threading.Tasks.Task!
Microsoft.AspNetCore.Components.EventCallback.InvokeAsync(object? arg) -> System.Threading.Tasks.Task!
Microsoft.AspNetCore.Components.EventCallback<TValue>
Microsoft.AspNetCore.Components.EventCallback<TValue>.EventCallback(Microsoft.AspNetCore.Components.IHandleEvent? receiver, System.MulticastDelegate? delegate) -> void
Microsoft.AspNetCore.Components.EventCallback<TValue>.HasDelegate.get -> bool
Microsoft.AspNetCore.Components.EventCallback<TValue>.InvokeAsync() -> System.Threading.Tasks.Task!
Microsoft.AspNetCore.Components.EventCallback<TValue>.InvokeAsync(TValue arg) -> System.Threading.Tasks.Task!
Microsoft.AspNetCore.Components.EventCallback<TValue>.InvokeAsync(TValue? arg) -> System.Threading.Tasks.Task!
Microsoft.AspNetCore.Components.EventCallbackFactory
Microsoft.AspNetCore.Components.EventCallbackFactory.Create(object! receiver, Microsoft.AspNetCore.Components.EventCallback callback) -> Microsoft.AspNetCore.Components.EventCallback
Microsoft.AspNetCore.Components.EventCallbackFactory.Create(object! receiver, System.Action! callback) -> Microsoft.AspNetCore.Components.EventCallback
Expand Down Expand Up @@ -145,7 +146,7 @@ Microsoft.AspNetCore.Components.ParameterView.Enumerator
Microsoft.AspNetCore.Components.ParameterView.Enumerator.Current.get -> Microsoft.AspNetCore.Components.ParameterValue
Microsoft.AspNetCore.Components.ParameterView.Enumerator.MoveNext() -> bool
Microsoft.AspNetCore.Components.ParameterView.GetEnumerator() -> Microsoft.AspNetCore.Components.ParameterView.Enumerator
Microsoft.AspNetCore.Components.ParameterView.GetValueOrDefault<TValue>(string! parameterName) -> TValue
Microsoft.AspNetCore.Components.ParameterView.GetValueOrDefault<TValue>(string! parameterName) -> TValue?
Microsoft.AspNetCore.Components.ParameterView.GetValueOrDefault<TValue>(string! parameterName, TValue defaultValue) -> TValue
Microsoft.AspNetCore.Components.ParameterView.SetParameterProperties(object! target) -> void
Microsoft.AspNetCore.Components.ParameterView.ToDictionary() -> System.Collections.Generic.IReadOnlyDictionary<string!, object!>!
Expand Down Expand Up @@ -190,30 +191,13 @@ Microsoft.AspNetCore.Components.RenderTree.RenderTreeEditType.UpdateMarkup = 8 -
Microsoft.AspNetCore.Components.RenderTree.RenderTreeEditType.UpdateText = 5 -> Microsoft.AspNetCore.Components.RenderTree.RenderTreeEditType
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.AttributeEventHandlerId.get -> ulong
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddAttribute(int sequence, string! name, string? value) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddComponentReferenceCapture(int sequence, System.Action<object!>! componentReferenceCaptureAction) -> void
Microsoft.AspNetCore.Components.Routing.Router.OnNavigateAsync.get -> Microsoft.AspNetCore.Components.EventCallback<Microsoft.AspNetCore.Components.Routing.NavigationContext!>
Microsoft.AspNetCore.Components.Routing.Router.OnNavigateAsync.set -> void
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.AttributeEventUpdatesAttributeName.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.AttributeName.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.AttributeValue.get -> object
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.Component.get -> Microsoft.AspNetCore.Components.IComponent
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentId.get -> int
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentKey.get -> object
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentReferenceCaptureAction.get -> System.Action<object>
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentReferenceCaptureParentFrameIndex.get -> int
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentSubtreeLength.get -> int
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentType.get -> System.Type
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementKey.get -> object
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementName.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementReferenceCaptureAction.get -> System.Action<Microsoft.AspNetCore.Components.ElementReference>
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementReferenceCaptureId.get -> string
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementSubtreeLength.get -> int
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.FrameType.get -> Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrameType
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.MarkupContent.get -> string
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.RegionSubtreeLength.get -> int
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.Sequence.get -> int
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.TextContent.get -> string
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrameType
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrameType.Attribute = 3 -> Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrameType
Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrameType.Component = 4 -> Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrameType
Expand Down Expand Up @@ -243,7 +227,9 @@ Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddAttribute(int seq
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddAttribute(int sequence, string! name, System.MulticastDelegate? value) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddAttribute(int sequence, string! name, bool value) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddAttribute(int sequence, string! name, object? value) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddAttribute(int sequence, string! name, string? value) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddAttribute<TArgument>(int sequence, string! name, Microsoft.AspNetCore.Components.EventCallback<TArgument> value) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddComponentReferenceCapture(int sequence, System.Action<object!>! componentReferenceCaptureAction) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddContent(int sequence, Microsoft.AspNetCore.Components.MarkupString markupContent) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddContent(int sequence, Microsoft.AspNetCore.Components.RenderFragment? fragment) -> void
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddContent(int sequence, object? textContent) -> void
Expand Down Expand Up @@ -303,6 +289,8 @@ Microsoft.AspNetCore.Components.Routing.Router.Navigating.get -> Microsoft.AspNe
Microsoft.AspNetCore.Components.Routing.Router.Navigating.set -> void
Microsoft.AspNetCore.Components.Routing.Router.NotFound.get -> Microsoft.AspNetCore.Components.RenderFragment!
Microsoft.AspNetCore.Components.Routing.Router.NotFound.set -> void
Microsoft.AspNetCore.Components.Routing.Router.OnNavigateAsync.get -> Microsoft.AspNetCore.Components.EventCallback<Microsoft.AspNetCore.Components.Routing.NavigationContext!>
Microsoft.AspNetCore.Components.Routing.Router.OnNavigateAsync.set -> void
Microsoft.AspNetCore.Components.Routing.Router.Router() -> void
Microsoft.AspNetCore.Components.Routing.Router.SetParametersAsync(Microsoft.AspNetCore.Components.ParameterView parameters) -> System.Threading.Tasks.Task!
abstract Microsoft.AspNetCore.Components.Dispatcher.CheckAccess() -> bool
Expand All @@ -315,7 +303,6 @@ abstract Microsoft.AspNetCore.Components.RenderTree.Renderer.Dispatcher.get -> M
abstract Microsoft.AspNetCore.Components.RenderTree.Renderer.HandleException(System.Exception! exception) -> void
abstract Microsoft.AspNetCore.Components.RenderTree.Renderer.UpdateDisplayAsync(in Microsoft.AspNetCore.Components.RenderTree.RenderBatch renderBatch) -> System.Threading.Tasks.Task!
override Microsoft.AspNetCore.Components.MarkupString.ToString() -> string!
~override Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ToString() -> string
readonly Microsoft.AspNetCore.Components.RenderTree.ArrayRange<T>.Array -> T[]!
readonly Microsoft.AspNetCore.Components.RenderTree.ArrayRange<T>.Count -> int
readonly Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiff.ComponentId -> int
Expand Down Expand Up @@ -427,3 +414,17 @@ virtual Microsoft.AspNetCore.Components.RenderTree.Renderer.DispatchEventAsync(u
virtual Microsoft.AspNetCore.Components.RenderTree.Renderer.Dispose(bool disposing) -> void
virtual Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessPendingRender() -> void
virtual Microsoft.AspNetCore.Components.RouteView.Render(Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder! builder) -> void
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.AttributeEventUpdatesAttributeName.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.AttributeName.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.AttributeValue.get -> object
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.Component.get -> Microsoft.AspNetCore.Components.IComponent
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentKey.get -> object
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentReferenceCaptureAction.get -> System.Action<object>
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ComponentType.get -> System.Type
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementKey.get -> object
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementName.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementReferenceCaptureAction.get -> System.Action<Microsoft.AspNetCore.Components.ElementReference>
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ElementReferenceCaptureId.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.MarkupContent.get -> string
~Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.TextContent.get -> string
~override Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame.ToString() -> string
18 changes: 16 additions & 2 deletions src/Components/Server/src/PublicAPI.Unshipped.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Microsoft.AspNetCore.Builder.ComponentEndpointConventionBuilder
#nullable enable
Microsoft.AspNetCore.Builder.ComponentEndpointConventionBuilder
Microsoft.AspNetCore.Builder.ComponentEndpointConventionBuilder.Add(System.Action<Microsoft.AspNetCore.Builder.EndpointBuilder!>! convention) -> void
Microsoft.AspNetCore.Builder.ComponentEndpointRouteBuilderExtensions
Microsoft.AspNetCore.Components.Server.CircuitOptions
Expand All @@ -17,6 +18,19 @@ Microsoft.AspNetCore.Components.Server.Circuits.Circuit
Microsoft.AspNetCore.Components.Server.Circuits.Circuit.Id.get -> string!
Microsoft.AspNetCore.Components.Server.Circuits.CircuitHandler
Microsoft.AspNetCore.Components.Server.Circuits.CircuitHandler.CircuitHandler() -> void
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorage
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorage.DeleteAsync(string! key) -> System.Threading.Tasks.ValueTask
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorage.GetAsync<TValue>(string! key) -> System.Threading.Tasks.ValueTask<Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorageResult<TValue>>
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorage.GetAsync<TValue>(string! purpose, string! key) -> System.Threading.Tasks.ValueTask<Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorageResult<TValue>>
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorage.SetAsync(string! key, object! value) -> System.Threading.Tasks.ValueTask
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorage.SetAsync(string! purpose, string! key, object! value) -> System.Threading.Tasks.ValueTask
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorageResult<TValue>
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorageResult<TValue>.Success.get -> bool
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedBrowserStorageResult<TValue>.Value.get -> TValue?
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedLocalStorage
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedLocalStorage.ProtectedLocalStorage(Microsoft.JSInterop.IJSRuntime! jsRuntime, Microsoft.AspNetCore.DataProtection.IDataProtectionProvider! dataProtectionProvider) -> void
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedSessionStorage
Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage.ProtectedSessionStorage.ProtectedSessionStorage(Microsoft.JSInterop.IJSRuntime! jsRuntime, Microsoft.AspNetCore.DataProtection.IDataProtectionProvider! dataProtectionProvider) -> void
Microsoft.AspNetCore.Components.Server.RevalidatingServerAuthenticationStateProvider
Microsoft.AspNetCore.Components.Server.RevalidatingServerAuthenticationStateProvider.RevalidatingServerAuthenticationStateProvider(Microsoft.Extensions.Logging.ILoggerFactory! loggerFactory) -> void
Microsoft.AspNetCore.Components.Server.ServerAuthenticationStateProvider
Expand All @@ -41,4 +55,4 @@ virtual Microsoft.AspNetCore.Components.Server.Circuits.CircuitHandler.OnCircuit
virtual Microsoft.AspNetCore.Components.Server.Circuits.CircuitHandler.OnConnectionDownAsync(Microsoft.AspNetCore.Components.Server.Circuits.Circuit! circuit, System.Threading.CancellationToken cancellationToken) -> System.Threading.Tasks.Task!
virtual Microsoft.AspNetCore.Components.Server.Circuits.CircuitHandler.OnConnectionUpAsync(Microsoft.AspNetCore.Components.Server.Circuits.Circuit! circuit, System.Threading.CancellationToken cancellationToken) -> System.Threading.Tasks.Task!
virtual Microsoft.AspNetCore.Components.Server.Circuits.CircuitHandler.Order.get -> int
virtual Microsoft.AspNetCore.Components.Server.RevalidatingServerAuthenticationStateProvider.Dispose(bool disposing) -> void
virtual Microsoft.AspNetCore.Components.Server.RevalidatingServerAuthenticationStateProvider.Dispose(bool disposing) -> void
Loading