Skip to content

Support user-specified runtime via args.runtime parameter - #16

Merged
lowkeyrd merged 7 commits into
devsapp:v3from
DevDengChao:feat/args-runtime
Feb 11, 2026
Merged

Support user-specified runtime via args.runtime parameter#16
lowkeyrd merged 7 commits into
devsapp:v3from
DevDengChao:feat/args-runtime

Conversation

@DevDengChao

@DevDengChao DevDengChao commented Feb 10, 2026

Copy link
Copy Markdown
Contributor

This pull request introduces support for customizing the function runtime, improves error handling, and updates tests and documentation to reflect these changes.
Now, users can specify a custom runtime via the runtime parameter, and the code will throw an explicit error if the required code property is missing. The tests and documentation have been updated accordingly.

Custom Runtime Support

  • Added support for a runtime parameter, allowing users to specify a custom function runtime (e.g., custom.debian11) instead of the default custom runtime in src/index.js. The plugin now prioritizes the user-provided runtime if specified.
  • Updated documentation (readme.md) to explain the new runtime parameter and provide usage examples. [1] [2]

Error Handling Improvements

  • Changed behavior to throw an explicit error if props.code is missing, improving clarity for users.

Testing Enhancements

  • Updated and expanded tests in test/index.spec.js to cover the new error handling and custom runtime logic. This includes a new test to verify that the user-provided runtime is prioritized. [1] [2]

Development Dependencies

  • Added type definitions for fs-extra, jest, and node to package.json to improve type safety and developer experience.

* Initial plan

* feat: prioritize args.runtime when provided by user

Co-authored-by: DevDengChao <16363180+DevDengChao@users.noreply.github.com>

* docs: update runtime example to custom.debian11

Co-authored-by: DevDengChao <16363180+DevDengChao@users.noreply.github.com>

* test: improve test name clarity for runtime priority test

Co-authored-by: DevDengChao <16363180+DevDengChao@users.noreply.github.com>

* revert: restore $index placeholder in src/code/index.js

Co-authored-by: DevDengChao <16363180+DevDengChao@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: DevDengChao <16363180+DevDengChao@users.noreply.github.com>
@DevDengChao
DevDengChao changed the base branch from master to v3 February 10, 2026 03:29
Signed-off-by: DevDengChao <2325690622@qq.com>
Signed-off-by: DevDengChao <2325690622@qq.com>
Signed-off-by: DevDengChao <2325690622@qq.com>
@DevDengChao

Copy link
Copy Markdown
Contributor Author

fix: #12

Signed-off-by: DevDengChao <2325690622@qq.com>
@DevDengChao

Copy link
Copy Markdown
Contributor Author

fix: #13

@lowkeyrd lowkeyrd left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM

@lowkeyrd
lowkeyrd merged commit c206e80 into devsapp:v3 Feb 11, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants