Adds v0.3.0 files to v0 module (#20) #21
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR reinstates v0 of the GoStep library within the v0 sub module, to ensure backwards compatibility.
This pull request introduces significant changes to the
go-steps
library, including updates to the documentation and the addition of new examples, functions, and types for better functionality and error handling. The most important changes include updates to theREADME.md
, new examples demonstrating the use of the library, and the introduction of new types and constants.Documentation Updates:
README.md
: Updated the note about breaking changes ingo-steps
v1 and provided guidance on how to continue using v0. Removed the "Help" section. [1] [2]New Examples:
example/v0/dynamic-steps-example/main.go
: Added a new example demonstrating dynamic step chaining and execution.example/v0/multistep-example/main.go
: Added a new example demonstrating multi-step execution with conditional next steps and error handling.New Functions and Types:
v0/go_step_types.go
: Introduced new types (StepName
,StepFn
,PossibleNextSteps
,Step
,stepArgChainingType
) to define steps and their configurations.v0/go_steps_constants.go
: Added constants and variables for default and maximum step attempts, and argument chaining types.Step Execution and Error Handling:
v0/go_steps.go
: Implemented theExecute
method for theStep
type, including logic for step execution, argument resolution, and error handling with retries.v0/go_steps_errors.go
: Added error messages for unresolved steps.Testing:
v0/go_steps_test.go
: Added tests for step argument resolution, next step resolution, and retry logic.