From efac90ea9225fbcffd2b633cd14958f104073d89 Mon Sep 17 00:00:00 2001 From: Thomas Cortes Date: Mon, 2 Feb 2026 15:31:30 -0500 Subject: [PATCH 1/3] feat: Add explicit cast on GitLabCollectionResponse enumerables --- NGitLab/Impl/GitLabCollectionResponse.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/NGitLab/Impl/GitLabCollectionResponse.cs b/NGitLab/Impl/GitLabCollectionResponse.cs index fdf029f34..408db8c3f 100644 --- a/NGitLab/Impl/GitLabCollectionResponse.cs +++ b/NGitLab/Impl/GitLabCollectionResponse.cs @@ -11,4 +11,8 @@ public abstract class GitLabCollectionResponse : IEnumerable, IAsyncEnumer public abstract IEnumerator GetEnumerator(); IEnumerator IEnumerable.GetEnumerator() => GetEnumerator(); + + public IAsyncEnumerable AsAsyncEnumerable() => this; + + public IEnumerable AsEnumerable() => this; } From aeddb92826d291ecdcb4f986da98b9bb932c5ec9 Mon Sep 17 00:00:00 2001 From: Thomas Cortes Date: Mon, 2 Feb 2026 16:00:33 -0500 Subject: [PATCH 2/3] public api --- NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt | 2 ++ NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt | 2 ++ NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt | 2 ++ 3 files changed, 6 insertions(+) diff --git a/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt b/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt index cc6d35c9e..dea4ee9d0 100644 --- a/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt +++ b/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt @@ -108,6 +108,8 @@ NGitLab.GitLabClient.SystemHooks.get -> NGitLab.ISystemHookClient NGitLab.GitLabClient.Users.get -> NGitLab.IUserClient NGitLab.GitLabClient.Version.get -> NGitLab.IVersionClient NGitLab.GitLabCollectionResponse +NGitLab.GitLabCollectionResponse.AsAsyncEnumerable() -> System.Collections.Generic.IAsyncEnumerable +NGitLab.GitLabCollectionResponse.AsEnumerable() -> System.Collections.Generic.IEnumerable NGitLab.GitLabCollectionResponse.GitLabCollectionResponse() -> void NGitLab.GitLabException NGitLab.GitLabException.ErrorMessage.get -> string diff --git a/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt b/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt index c6e971cea..564fde70d 100644 --- a/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt +++ b/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt @@ -108,6 +108,8 @@ NGitLab.GitLabClient.SystemHooks.get -> NGitLab.ISystemHookClient NGitLab.GitLabClient.Users.get -> NGitLab.IUserClient NGitLab.GitLabClient.Version.get -> NGitLab.IVersionClient NGitLab.GitLabCollectionResponse +NGitLab.GitLabCollectionResponse.AsAsyncEnumerable() -> System.Collections.Generic.IAsyncEnumerable +NGitLab.GitLabCollectionResponse.AsEnumerable() -> System.Collections.Generic.IEnumerable NGitLab.GitLabCollectionResponse.GitLabCollectionResponse() -> void NGitLab.GitLabException NGitLab.GitLabException.ErrorMessage.get -> string diff --git a/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt b/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt index cc6d35c9e..dea4ee9d0 100644 --- a/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt +++ b/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt @@ -108,6 +108,8 @@ NGitLab.GitLabClient.SystemHooks.get -> NGitLab.ISystemHookClient NGitLab.GitLabClient.Users.get -> NGitLab.IUserClient NGitLab.GitLabClient.Version.get -> NGitLab.IVersionClient NGitLab.GitLabCollectionResponse +NGitLab.GitLabCollectionResponse.AsAsyncEnumerable() -> System.Collections.Generic.IAsyncEnumerable +NGitLab.GitLabCollectionResponse.AsEnumerable() -> System.Collections.Generic.IEnumerable NGitLab.GitLabCollectionResponse.GitLabCollectionResponse() -> void NGitLab.GitLabException NGitLab.GitLabException.ErrorMessage.get -> string From e1fd2af5d6855044c7a6f3977487e86d4262edad Mon Sep 17 00:00:00 2001 From: Thomas Cortes Date: Tue, 3 Feb 2026 10:08:20 -0500 Subject: [PATCH 3/3] remove as enumerable --- NGitLab/Impl/GitLabCollectionResponse.cs | 2 -- NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt | 1 - NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt | 1 - NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt | 1 - 4 files changed, 5 deletions(-) diff --git a/NGitLab/Impl/GitLabCollectionResponse.cs b/NGitLab/Impl/GitLabCollectionResponse.cs index 408db8c3f..3424d61b6 100644 --- a/NGitLab/Impl/GitLabCollectionResponse.cs +++ b/NGitLab/Impl/GitLabCollectionResponse.cs @@ -13,6 +13,4 @@ public abstract class GitLabCollectionResponse : IEnumerable, IAsyncEnumer IEnumerator IEnumerable.GetEnumerator() => GetEnumerator(); public IAsyncEnumerable AsAsyncEnumerable() => this; - - public IEnumerable AsEnumerable() => this; } diff --git a/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt b/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt index dea4ee9d0..bf8834736 100644 --- a/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt +++ b/NGitLab/PublicAPI/net472/PublicAPI.Unshipped.txt @@ -109,7 +109,6 @@ NGitLab.GitLabClient.Users.get -> NGitLab.IUserClient NGitLab.GitLabClient.Version.get -> NGitLab.IVersionClient NGitLab.GitLabCollectionResponse NGitLab.GitLabCollectionResponse.AsAsyncEnumerable() -> System.Collections.Generic.IAsyncEnumerable -NGitLab.GitLabCollectionResponse.AsEnumerable() -> System.Collections.Generic.IEnumerable NGitLab.GitLabCollectionResponse.GitLabCollectionResponse() -> void NGitLab.GitLabException NGitLab.GitLabException.ErrorMessage.get -> string diff --git a/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt b/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt index 564fde70d..78fea3cbb 100644 --- a/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt +++ b/NGitLab/PublicAPI/net8.0/PublicAPI.Unshipped.txt @@ -109,7 +109,6 @@ NGitLab.GitLabClient.Users.get -> NGitLab.IUserClient NGitLab.GitLabClient.Version.get -> NGitLab.IVersionClient NGitLab.GitLabCollectionResponse NGitLab.GitLabCollectionResponse.AsAsyncEnumerable() -> System.Collections.Generic.IAsyncEnumerable -NGitLab.GitLabCollectionResponse.AsEnumerable() -> System.Collections.Generic.IEnumerable NGitLab.GitLabCollectionResponse.GitLabCollectionResponse() -> void NGitLab.GitLabException NGitLab.GitLabException.ErrorMessage.get -> string diff --git a/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt b/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt index dea4ee9d0..bf8834736 100644 --- a/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt +++ b/NGitLab/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt @@ -109,7 +109,6 @@ NGitLab.GitLabClient.Users.get -> NGitLab.IUserClient NGitLab.GitLabClient.Version.get -> NGitLab.IVersionClient NGitLab.GitLabCollectionResponse NGitLab.GitLabCollectionResponse.AsAsyncEnumerable() -> System.Collections.Generic.IAsyncEnumerable -NGitLab.GitLabCollectionResponse.AsEnumerable() -> System.Collections.Generic.IEnumerable NGitLab.GitLabCollectionResponse.GitLabCollectionResponse() -> void NGitLab.GitLabException NGitLab.GitLabException.ErrorMessage.get -> string