Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds initial implementation of the Wolfgang.Extensions.IAsyncEnumerable library, including a ChunkAsync extension method for splitting async enumerables into chunks. The implementation supports multiple .NET Framework versions (4.6.2-4.8.1) and .NET Core/5+ versions (5.0-10.0).
Changes:
- Implements
ChunkAsyncextension method with comprehensive test coverage and benchmarks - Adds multi-framework support across .NET Framework 4.6.2-4.8.1 and .NET 5.0-10.0
- Introduces separate build validation workflow for tagged builds with full multi-platform testing
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/Wolfgang.Extensions.IAsyncEnumerable/Wolfgang.Extensions.IAsyncEnumerable.csproj | Configures multi-framework targeting and package metadata for the library |
| src/Wolfgang.Extensions.IAsyncEnumerable/IAsyncEnumerableExtensions.cs | Implements the ChunkAsync extension method with cancellation support |
| tests/Wolfgang.Extensions.IAsyncEnumerable.Tests.Unit/Wolfgang.Extensions.IAsyncEnumerable.Tests.Unit.csproj | Configures test project with framework-specific package versions |
| tests/Wolfgang.Extensions.IAsyncEnumerable.Tests.Unit/ChunkAsyncTests.cs | Provides comprehensive test coverage for ChunkAsync method |
| benchmarks/Wolfgang.Extensions.IAsyncEnumerable.Benchmarks/Wolfgang.Extensions.IAsyncEnumerable.Benchmarks.csproj | Sets up benchmark project configuration |
| benchmarks/Wolfgang.Extensions.IAsyncEnumerable.Benchmarks/Program.cs | Initializes benchmark runner |
| benchmarks/Wolfgang.Extensions.IAsyncEnumerable.Benchmarks/ChunkAsyncBenchmarks.cs | Implements performance benchmarks for ChunkAsync |
| .github/workflows/release.yaml | Updates release workflow with improved validation, logging, and error handling |
| .github/workflows/pr.yaml | Simplifies PR workflow to Linux-only testing with coverage validation |
| .github/workflows/build.yaml | Adds comprehensive build validation workflow for all platforms |
| Solution.slnx | Adds project references to solution |
| tests/.gitkeep | Removes placeholder file |
| benchmarks/.gitkeep | Removes placeholder file |
Fix CodeQL workflow build failure by using solution file instead of grep filtering
Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
…flow-file Fix find command syntax in CodeQL workflow
- Update .editorconfig with comprehensive C# formatting rules - Add format.ps1 PowerShell script for local formatting - Add README-FORMATTING.md documentation - Update pr.yaml workflow to check formatting - Apply formatting to existing code (2 files formatted) Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
- Add indent_size = 4 to global [*] section for consistency - Add end_of_line = lf to global [*] section to ensure LF line endings for all files - Addresses code review feedback Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
…g-enforcement Add automated code formatting enforcement
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
Add dotnet-format installation to PR workflow
…d CRLF line endings Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
…rmat-script [WIP] Fix parse error in format.ps1 for Windows PowerShell
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 5 out of 7 changed files in this pull request and generated 4 comments.
Comments suppressed due to low confidence (2)
.editorconfig:149
- The .editorconfig is missing the suppression for analyzer rule CA1707, which flags underscores in identifiers. This is needed because the test methods throughout the codebase use underscores in their names (e.g.,
ChunkAsync_WithExactMultipleChunkSize_ReturnsExpectedChunkson line 6).
Without this suppression (dotnet_diagnostic.CA1707.severity = none), code analysis will produce warnings or errors for all test method names, causing builds to fail or creating noise in the developer experience.
# Naming conventions
dotnet_naming_rule.interface_should_be_begins_with_i.severity = suggestion
dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface
dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i
dotnet_naming_rule.types_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.types_should_be_pascal_case.symbols = types
dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case
dotnet_naming_rule.non_field_members_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members
dotnet_naming_rule.non_field_members_should_be_pascal_case.style = pascal_case
# Symbol specifications
dotnet_naming_symbols.interface.applicable_kinds = interface
dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum
dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method
dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
# Naming styles
dotnet_naming_style.pascal_case.capitalization = pascal_case
dotnet_naming_style.begins_with_i.required_prefix = I
dotnet_naming_style.begins_with_i.capitalization = pascal_case
.editorconfig:149
- The simplified .editorconfig is missing critical C# code style rules that were present in the original configuration. Specifically:
-
File-scoped namespace rule (
csharp_style_namespace_declarations = file_scoped) - The codebase uses file-scoped namespaces (see src/Wolfgang.Extensions.IAsyncEnumerable/IAsyncEnumerableExtensions.cs:9), but this rule was removed. -
Var preferences (
csharp_style_var_*rules) - These rules were completely removed, leaving no guidance on when to use var vs explicit types. -
Expression-bodied members - Rules for when to use expression bodies were removed.
-
Modifier ordering (
csharp_preferred_modifier_order) - This ensures consistent ordering of modifiers like public, static, async, etc.
These omissions mean the code formatter will not enforce important conventions that the repository was previously following. This could lead to inconsistent code style in future contributions.
root = true
# All files
[*]
charset = utf-8
end_of_line = lf
indent_style = space
indent_size = 4
insert_final_newline = true
trim_trailing_whitespace = true
# XML project files
[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}]
indent_size = 2
# XML config files
[*.{props,targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}]
indent_size = 2
# JSON files
[*.json]
indent_size = 2
# YAML files
[*.{yml,yaml}]
indent_size = 2
# Shell scripts
[*.sh]
end_of_line = lf
# PowerShell files
[*.ps1]
indent_size = 4
end_of_line = crlf
# C# files
[*.cs]
indent_size = 4
end_of_line = lf
# New line preferences
csharp_new_line_before_open_brace = all
csharp_new_line_before_else = true
csharp_new_line_before_catch = true
csharp_new_line_before_finally = true
csharp_new_line_before_members_in_object_initializers = true
csharp_new_line_before_members_in_anonymous_types = true
csharp_new_line_between_query_expression_clauses = true
# Indentation preferences
csharp_indent_case_contents = true
csharp_indent_switch_labels = true
csharp_indent_labels = one_less_than_current
csharp_indent_block_contents = true
csharp_indent_braces = false
csharp_indent_case_contents_when_block = false
# Space preferences
csharp_space_after_cast = false
csharp_space_after_keywords_in_control_flow_statements = true
csharp_space_between_parentheses = false
csharp_space_before_colon_in_inheritance_clause = true
csharp_space_after_colon_in_inheritance_clause = true
csharp_space_around_binary_operators = before_and_after
csharp_space_between_method_declaration_parameter_list_parentheses = false
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
csharp_space_between_method_declaration_name_and_open_parenthesis = false
csharp_space_between_method_call_parameter_list_parentheses = false
csharp_space_between_method_call_empty_parameter_list_parentheses = false
csharp_space_between_method_call_name_and_opening_parenthesis = false
csharp_space_after_comma = true
csharp_space_before_comma = false
csharp_space_after_dot = false
csharp_space_before_dot = false
csharp_space_after_semicolon_in_for_statement = true
csharp_space_before_semicolon_in_for_statement = false
csharp_space_around_declaration_statements = false
csharp_space_before_open_square_brackets = false
csharp_space_between_empty_square_brackets = false
csharp_space_between_square_brackets = false
# Organize usings
dotnet_sort_system_directives_first = true
dotnet_separate_import_directive_groups = false
# Code style rules
dotnet_style_qualification_for_field = false:suggestion
dotnet_style_qualification_for_property = false:suggestion
dotnet_style_qualification_for_method = false:suggestion
dotnet_style_qualification_for_event = false:suggestion
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
dotnet_style_predefined_type_for_member_access = true:suggestion
dotnet_style_require_accessibility_modifiers = for_non_interface_members:suggestion
dotnet_style_readonly_field = true:suggestion
csharp_prefer_braces = true:suggestion
csharp_prefer_simple_using_statement = true:suggestion
# Expression preferences
dotnet_style_prefer_auto_properties = true:suggestion
dotnet_style_prefer_conditional_expression_over_assignment = true:silent
dotnet_style_prefer_conditional_expression_over_return = true:silent
dotnet_style_prefer_inferred_tuple_names = true:suggestion
dotnet_style_prefer_inferred_anonymous_type_member_names = true:suggestion
csharp_prefer_simple_default_expression = true:suggestion
# Pattern matching
csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion
csharp_style_pattern_matching_over_as_with_null_check = true:suggestion
# Null checking preferences
csharp_style_throw_expression = true:suggestion
csharp_style_conditional_delegate_call = true:suggestion
dotnet_style_coalesce_expression = true:suggestion
dotnet_style_null_propagation = true:suggestion
# Wrapping preferences
csharp_preserve_single_line_statements = false
csharp_preserve_single_line_blocks = true
# Naming conventions
dotnet_naming_rule.interface_should_be_begins_with_i.severity = suggestion
dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface
dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i
dotnet_naming_rule.types_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.types_should_be_pascal_case.symbols = types
dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case
dotnet_naming_rule.non_field_members_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members
dotnet_naming_rule.non_field_members_should_be_pascal_case.style = pascal_case
# Symbol specifications
dotnet_naming_symbols.interface.applicable_kinds = interface
dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum
dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method
dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
# Naming styles
dotnet_naming_style.pascal_case.capitalization = pascal_case
dotnet_naming_style.begins_with_i.required_prefix = I
dotnet_naming_style.begins_with_i.capitalization = pascal_case
Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
…se-error Fix Windows PowerShell compatibility via UTF-8 BOM encoding
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
@Chris-Wolfgang I've opened a new pull request, #47, to work on those changes. Once the pull request is ready, I'll request review from you. |
Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
Remove ConfigureAwait from test code to align with .editorconfig
Remove ConfigureAwait from test code for consistency
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Correct analyzer count and remove StyleCop from CONTRIBUTING.md
Remove global .editorconfig documentation rules, use per-folder configuration
|
@Chris-Wolfgang I've opened a new pull request, #48, to work on those changes. Once the pull request is ready, I'll request review from you. |
Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
Update all license references from MPL-2.0 to MIT
Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
…reawait-warning Disable ConfigureAwait analyzer warnings in library code
Co-authored-by: Chris-Wolfgang <210299580+Chris-Wolfgang@users.noreply.github.com>
…nfig-for-var Fix IDE0008 warning by configuring var preferences in .editorconfig
Description
Fixes/Complete # (issue)
Type of change
Please delete options that are not relevant.
How Has This Been Tested?
Checklist
Screenshots (if applicable)
Additional context