errata-ai / vale-action

:octocat: The official GitHub Action for Vale -- install, manage, and run Vale with ease.
MIT License
201 stars 51 forks source link

Action installs dependencies at runtime #136

Closed ekohl closed 1 month ago

ekohl commented 1 month ago

Currently the action installs its dependencies at runtime: https://github.com/errata-ai/vale-action/blob/3a4769d4af5f9498e586fb41abc72bbca594b400/src/input.ts#L54-L58

Then it also installs Vale and Reviewdog in https://github.com/errata-ai/vale-action/blob/reviewdog/src/install.ts.

This makes the action slower than it needs to be and also causes issues like https://github.com/errata-ai/vale-action/issues/111 and https://github.com/errata-ai/vale-action/issues/128.

My suggestion would be to start using an image that contains all the required dependencies. https://docs.github.com/en/actions/sharing-automations/creating-actions/creating-a-docker-container-action describes this process. That's pretty much the opposite of https://github.com/errata-ai/vale-action/commit/87aaef6b88f88f84e428a8c8023b19d1c8f330df. Sadly there's no PR attached to that commit with any explanation why this new strategy was used.

jdkato commented 1 month ago

Vale and Reviewdog are runtime dependencies in so much as their versions are configurable.

Using Docker (even a pre-built image) for the other 2 is not faster.