Skip to content

feat(core): change to execute all plugins before throwing on failed - #275

Merged
MishaSeredenkoPushBased merged 8 commits into
mainfrom
exec-all-plugins-before-throw
Nov 22, 2023
Merged

MishaSeredenkoPushBased merged 8 commits into
mainfrom
exec-all-plugins-before-throw

Conversation

@MishaSeredenkoPushBased

Copy link
Copy Markdown
Contributor

Changed executePlugins() logic to run all plugins, even if one or more plugins have failed. Then console.error the failed plugin errors, and throw.
Closes #159

Comment thread packages/core/src/lib/implementation/execute-plugin.spec.ts Outdated
matejchalk
matejchalk previously approved these changes Nov 16, 2023

@BioPhoton BioPhoton left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could use already existing helper logic.

Comment thread packages/core/src/lib/implementation/execute-plugin.spec.ts
Comment thread packages/core/src/lib/implementation/execute-plugin.ts Outdated
Comment thread packages/core/src/lib/implementation/execute-plugin.ts Outdated
Comment thread packages/core/src/lib/implementation/execute-plugin.ts Outdated

@BioPhoton BioPhoton left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

left comments mostly nit picking

@BioPhoton BioPhoton left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi! I guess we have a bit of a confusion here with generic vs specific functions and how to reuse generic logic.

Please have a look at my comments

Comment thread packages/utils/src/lib/log-results.ts Outdated
Comment thread packages/utils/src/lib/file-system.ts Outdated
Comment thread packages/utils/src/lib/log-results.ts Outdated
Comment thread packages/utils/src/lib/log-results.ts Outdated
Comment thread packages/utils/src/lib/log-results.ts Outdated
Comment thread packages/utils/src/lib/log-results.ts Outdated
Comment thread packages/utils/src/lib/log-results.ts Outdated
Comment thread packages/core/src/lib/implementation/execute-plugin.ts Outdated
@MishaSeredenkoPushBased

Copy link
Copy Markdown
Contributor Author

The comments are fixed, as well as the code was improved for better readability and support.
@BioPhoton @matejchalk your comments were very useful and helpful, thanks!

Comment thread packages/utils/package.json Outdated
Comment thread packages/utils/src/lib/log-results.unit.spec.ts Outdated
@MishaSeredenkoPushBased
MishaSeredenkoPushBased merged commit 32a6ef5 into main Nov 22, 2023
@MishaSeredenkoPushBased
MishaSeredenkoPushBased deleted the exec-all-plugins-before-throw branch November 22, 2023 15:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

➕ enhancement new feature or request 💡 good first issue good for newcomers 🤓 UX UX improvement for CLI users

Projects

None yet

Development

Successfully merging this pull request may close these issues.

plugin execution should be a graceful exit and run all registered plugins before throwing

5 participants