Skip to content

feat(tasks): modify usage spec parsing to return dummy strings#6723

Merged
jdx merged 3 commits intojdx:mainfrom
iamkroot:fix-spec-parsing
Oct 22, 2025
Merged

feat(tasks): modify usage spec parsing to return dummy strings#6723
jdx merged 3 commits intojdx:mainfrom
iamkroot:fix-spec-parsing

Conversation

@iamkroot
Copy link
Copy Markdown
Contributor

  • Updated return values in the task script parser to return empty
    strings instead of null to prevent type errors.

  • Overrode the "throw" function to no-op to ignore errors.

Fixes #6646

- Updated return values in the task script parser to return empty
  strings instead of null to prevent type errors.

- Overrode the "throw" function to no-op to ignore errors.

Fixes jdx#6646
Copilot AI review requested due to automatic review settings October 22, 2025 18:46
Copy link
Copy Markdown
Contributor

Copilot AI left a 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 modifies the task script parser to return empty strings instead of null values and disables error throwing during usage specification parsing. These changes prevent type errors when the parser processes template functions for collecting argument and flag specifications.

Key Changes:

  • Registers a no-op throw function that returns null instead of raising errors
  • Replaces tera::Value::Null return values with empty strings in arg, flag, and option template functions

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread src/task/task_script_parser.rs
@iamkroot
Copy link
Copy Markdown
Contributor Author

Why is e2e-linux CI getting skipped?

@jdx jdx merged commit 8433c24 into jdx:main Oct 22, 2025
24 checks passed
@jdx
Copy link
Copy Markdown
Owner

jdx commented Oct 22, 2025

that's just release tests

@iamkroot iamkroot deleted the fix-spec-parsing branch October 22, 2025 19:57
jdx pushed a commit that referenced this pull request Oct 23, 2025
### 🚀 Features

- **(tasks)** modify usage spec parsing to return dummy strings by
@iamkroot in [#6723](#6723)
- include resolved sources in task templating context by
@the-wondersmith in [#6180](#6180)
- Add Tera function `absolute` by @iamkroot in
[#6729](#6729)

### 🐛 Bug Fixes

- **(cli)** respect os filter during upgrade by @iamkroot in
[#6724](#6724)

### 📚 Documentation

- fix RUNTIME.osType values in example snippet by @ofalvai in
[#6732](#6732)
- migrate issue links to GitHub discussions by @jdx in
[#6740](#6740)
- document Lua version by @ofalvai in
[#6741](#6741)

### New Contributors

- @ofalvai made their first contribution in
[#6741](#6741)
- @iamkroot made their first contribution in
[#6729](#6729)
- @the-wondersmith made their first contribution in
[#6180](#6180)

## 📦 Aqua Registry Updates

#### New Packages (8)

- [`SUPERCILEX/fuc/cpz`](https://github.com/SUPERCILEX/fuc/cpz)
- [`SUPERCILEX/fuc/rmz`](https://github.com/SUPERCILEX/fuc/rmz)
- [`dinoDanic/diny`](https://github.com/dinoDanic/diny)
- [`eth-p/bat-extras`](https://github.com/eth-p/bat-extras)
- [`k1LoW/tailor-log`](https://github.com/k1LoW/tailor-log)
- [`mashiike/acrun`](https://github.com/mashiike/acrun)
- [`opengrep/opengrep`](https://github.com/opengrep/opengrep)
-
[`praetorian-inc/noseyparker`](https://github.com/praetorian-inc/noseyparker)

#### Updated Packages (2)

- [`bufbuild/buf`](https://github.com/bufbuild/buf)
-
[`bytecodealliance/wasm-tools`](https://github.com/bytecodealliance/wasm-tools)
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