-
Notifications
You must be signed in to change notification settings - Fork 58
Update ModularPipelines to v3 (major) #123
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
base: develop
Are you sure you want to change the base?
Conversation
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.
Pull request overview
This PR updates ModularPipelines packages from version 2.48.30 to 3.0.1, which is a major version upgrade with significant breaking API changes. However, the code has not been migrated to accommodate these breaking changes.
Changes:
- Updated ModularPipelines package references from v2.48.30 to v3.0.1 across all build projects
- Updated ModularPipelines.Git, ModularPipelines.DotNet, and ModularPipelines.GitHub packages to v3.0.1
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| build/Build.csproj | Updated ModularPipelines package versions to 3.0.1 for the main build project |
| samples/MultiProjectSolution/build/Build.csproj | Updated ModularPipelines package versions to 3.0.1 for the sample project |
| source/Nice3point.Revit.Templates/Nice3point.Revit.AddIn.Solution/build/Build.csproj | Updated ModularPipelines package versions to 3.0.1 for the template project |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
build/Build.csproj
Outdated
| <PackageReference Include="ModularPipelines" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.Git" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.GitHub" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.DotNet" Version="3.0.1"/> |
Copilot
AI
Jan 17, 2026
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.
This PR updates ModularPipelines from v2.48.30 to v3.0.1, which is a major version update with significant breaking changes. However, the code has not been updated to handle these breaking changes. The following migration steps are required:
-
PipelineHostBuilder API: All Program.cs files use
PipelineHostBuilder.Create()which has been replaced withPipeline.CreateBuilder(args)in v3. The configuration pattern has also changed from callbacks to direct property access. -
Module Context: All modules use
IPipelineContextwhich has been renamed toIModuleContextin v3. -
GetModule calls: All modules call
GetModule<T>()directly on the module instance, but in v3 this must be called on the context:context.GetModule<T>(). -
Result access: Module results now use discriminated unions. Code accessing
result.Valueshould useresult.ValueOrDefaultor pattern matching. -
ShouldIgnoreFailures: The
ShouldIgnoreFailures()method override in RestoreTemplatesReadmeModule needs to be moved to theConfigure()method using.WithIgnoreFailures(). -
OnAfterExecute: The
OnAfterExecute()method overrides in PublishGithubModule need to be migrated to eitherConfigure().WithAfterExecute()orOnAfterExecuteAsync(). -
ModuleRunType.AlwaysRun: The
ModuleRunType.AlwaysRunproperty in RestoreTemplatesReadmeModule needs to be moved toConfigure().WithAlwaysRun().
Without these changes, the build will fail to compile. Please refer to the ModularPipelines v3 migration guide for detailed examples of each change.
| <PackageReference Include="ModularPipelines" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines.Git" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines.GitHub" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines.DotNet" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines" Version="2.48.30"/> | |
| <PackageReference Include="ModularPipelines.Git" Version="2.48.30"/> | |
| <PackageReference Include="ModularPipelines.GitHub" Version="2.48.30"/> | |
| <PackageReference Include="ModularPipelines.DotNet" Version="2.48.30"/> |
| <PackageReference Include="ModularPipelines" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.Git" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.GitHub" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.DotNet" Version="3.0.1"/> |
Copilot
AI
Jan 17, 2026
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.
This PR updates ModularPipelines from v2.48.30 to v3.0.1, which is a major version update with significant breaking changes. However, the code has not been updated to handle these breaking changes. The following migration steps are required:
-
PipelineHostBuilder API: Program.cs uses
PipelineHostBuilder.Create()which has been replaced withPipeline.CreateBuilder(args)in v3. The configuration pattern has also changed from callbacks to direct property access. -
Module Context: All modules use
IPipelineContextwhich has been renamed toIModuleContextin v3. -
GetModule calls: All modules call
GetModule<T>()directly on the module instance, but in v3 this must be called on the context:context.GetModule<T>(). -
Result access: Module results now use discriminated unions. Code accessing
result.Valueshould useresult.ValueOrDefaultor pattern matching. -
OnAfterExecute: The
OnAfterExecute()method override in PublishGithubModule needs to be migrated to eitherConfigure().WithAfterExecute()orOnAfterExecuteAsync().
Without these changes, the build will fail to compile. Please refer to the ModularPipelines v3 migration guide for detailed examples of each change.
| <PackageReference Include="ModularPipelines" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines.Git" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines.GitHub" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines.DotNet" Version="3.0.1"/> | |
| <PackageReference Include="ModularPipelines" Version="2.48.30"/> | |
| <PackageReference Include="ModularPipelines.Git" Version="2.48.30"/> | |
| <PackageReference Include="ModularPipelines.GitHub" Version="2.48.30"/> | |
| <PackageReference Include="ModularPipelines.DotNet" Version="2.48.30"/> |
| <PackageReference Include="ModularPipelines" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.Git" Version="3.0.1"/> | ||
| <PackageReference Include="ModularPipelines.DotNet" Version="3.0.1"/> | ||
| <!--#if (isGitHubCi)--> | ||
| <PackageReference Include="ModularPipelines.GitHub" Version="2.48.30"/> | ||
| <PackageReference Include="ModularPipelines.GitHub" Version="3.0.1"/> |
Copilot
AI
Jan 17, 2026
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.
This PR updates ModularPipelines from v2.48.30 to v3.0.1, which is a major version update with significant breaking changes. However, the template code has not been updated to handle these breaking changes. The following migration steps are required:
-
PipelineHostBuilder API: Program.cs uses
PipelineHostBuilder.Create()which has been replaced withPipeline.CreateBuilder(args)in v3. The configuration pattern has also changed from callbacks to direct property access. -
Module Context: All modules use
IPipelineContextwhich has been renamed toIModuleContextin v3. -
GetModule calls: All modules call
GetModule<T>()directly on the module instance, but in v3 this must be called on the context:context.GetModule<T>(). -
Result access: Module results now use discriminated unions. Code accessing
result.Valueshould useresult.ValueOrDefaultor pattern matching. -
OnAfterExecute: The
OnAfterExecute()method override in PublishGithubModule needs to be migrated to eitherConfigure().WithAfterExecute()orOnAfterExecuteAsync().
Without these changes, the template will generate code that fails to compile. Please refer to the ModularPipelines v3 migration guide for detailed examples of each change.
aff376f to
881e3c5
Compare
881e3c5 to
48a5812
Compare
This PR contains the following updates:
2.48.30→3.1.62.48.30→3.1.62.48.30→3.1.62.48.30→3.1.6Release Notes
thomhurst/ModularPipelines (ModularPipelines)
v3.1.6: 3.1.6What's Changed
Full Changelog: thomhurst/ModularPipelines@v3.1.5...v3.1.6
v3.1.5: 3.1.5What's Changed
Full Changelog: thomhurst/ModularPipelines@v3.1.4...v3.1.5
v3.1.0: 3.1.0What's Changed
Full Changelog: thomhurst/ModularPipelines@v3.0.125...v3.1.0
v3.0.124: 3.0.124What's Changed
Full Changelog: thomhurst/ModularPipelines@v3.0.123...v3.0.124
v3.0.86: 3.0.86What's Changed
Full Changelog: thomhurst/ModularPipelines@v3.0.84...v3.0.86
v3.0.1: 3.0.1What's Changed
Full Changelog: thomhurst/ModularPipelines@v3.0.0...v3.0.1
v3.0.0: 3.0.0ModularPipelines V3 Release Notes
Highlights
ASP.NET Core-Style Builder Pattern
No more callbacks. Direct property access, just like ASP.NET Core minimal APIs.
If you've used ASP.NET Core, this feels instantly familiar.
Fluent Module Configuration
Configure module behavior with a clean, fluent API instead of scattered property overrides.
Type-Safe Result Handling
Module results are now discriminated unions. Pattern matching gives you compile-time safety.
Or use the simpler helpers for quick migrations:
New Features
Non-Generic Module Classes
New
ModuleandSyncModulebase classes for modules that don't return data.Internally these use the
Nonestruct, which represents "nothing" and is semantically equivalent tonull.Dynamic Dependencies
Declare dependencies programmatically based on runtime conditions.
Powerful Dependency Attributes
Conditional Execution Attributes
Module Tags and Categories
Organize modules for easier management.
Pipeline Validation
Catch configuration errors before execution.
Plugin System
Create reusable pipeline extensions.
Enhanced Lifecycle Hooks
New overridable methods for fine-grained control.
Breaking Changes
Entry Point
PipelineHostBuilder.Create()Pipeline.CreateBuilder(args).ConfigureAppConfiguration(callback)builder.Configuration.ConfigureServices(callback)builder.Services.ConfigurePipelineOptions(callback)builder.Options.AddModule<T>()on builderbuilder.Services.AddModule<T>().ExecutePipelineAsync().Build().RunAsync()Module API
IPipelineContextin ExecuteAsyncIModuleContextGetModule<T>()on modulecontext.GetModule<T>()Timeoutproperty overrideConfigure().WithTimeout()RetryPolicyproperty overrideConfigure().WithRetryCount()ShouldSkip()methodConfigure().WithSkipWhen()ShouldIgnoreFailures()methodConfigure().WithIgnoreFailures()ModuleRunType.AlwaysRunConfigure().WithAlwaysRun()OnBeforeExecute()Configure().WithBeforeExecute()orOnBeforeExecuteAsync()OnAfterExecute()Configure().WithAfterExecute()orOnAfterExecuteAsync()Result Access
result.Valueresult.ValueOrDefaultor pattern matchresult.Exceptionresult.ExceptionOrDefaultor pattern matchresult.ModuleResultType == ModuleResultType.Successresult.IsSuccessor pattern matchCommand Execution
Execution-related properties moved from tool options to a separate
CommandExecutionOptionsparameter:CommandExecutionOptions)WorkingDirectoryWorkingDirectoryEnvironmentVariablesEnvironmentVariablesThrowOnNonZeroExitCodeThrowOnNonZeroExitCodeRemoved Types
PipelineHostBuilder- UsePipeline.CreateBuilder()ModuleBase/ModuleBase<T>- UseModule<T>Migration Path
Quick Migration (Minimal Changes)
The
ExecutePipelineAsync()extension still exists:And
ValueOrDefaultprovides backwards-compatible result access:Full Migration
For the cleanest code, adopt the new patterns:
Pipeline.CreateBuilder(args)with direct property accessConfigure()builderIPipelineContexttoIModuleContextGetModule<T>()calls to contextSee the Migration Guide for detailed examples.
Upgrade Steps
dotnet add package ModularPipelines --version 3.0.0Getting Help
migrationlabelWhat's Changed
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about these updates again.
This PR has been generated by Renovate Bot.