Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing env feature to clap #2254

Merged
merged 1 commit into from
Aug 19, 2024
Merged

Add missing env feature to clap #2254

merged 1 commit into from
Aug 19, 2024

Conversation

capossele
Copy link
Contributor

With #2196 we introduced the env usage in clap without adding the relative env feature to it. This result in having issues when building cargo-risczero, specifically when building it with only some of its features e.g.,:

cargo build -p cargo-risczero --no-default-features --features "cuda"

or

cargo build -p cargo-risczero --no-default-features --features "metal"

returns:

error[E0599]: no method named `env` found for struct `Arg` in the current scope
  --> risc0/cargo-risczero/src/commands/datasheet/mod.rs:41:38
   |
41 |     #[arg(long, value_name = "PATH", env = "RISC0_SERVER_PATH")]
   |                                      ^^^ method not found in `Arg`

@capossele capossele requested a review from a team as a code owner August 19, 2024 22:04
Copy link

vercel bot commented Aug 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs-website ⬜️ Ignored (Inspect) Aug 19, 2024 10:04pm
reports-and-benchmarks ⬜️ Ignored (Inspect) Aug 19, 2024 10:04pm

@flaub flaub merged commit d2ac534 into main Aug 19, 2024
40 checks passed
@flaub flaub deleted the capossele/cargo-risczero-env branch August 19, 2024 23:44
SchmErik pushed a commit that referenced this pull request Aug 22, 2024
With #2196 we introduced the `env`
usage in `clap` without adding the relative `env` feature to it. This
result in having issues when building `cargo-risczero`, specifically
when building it with only some of its features e.g.,:

```bash
cargo build -p cargo-risczero --no-default-features --features "cuda"
```

or

```bash
cargo build -p cargo-risczero --no-default-features --features "metal"
```

returns:

```
error[E0599]: no method named `env` found for struct `Arg` in the current scope
  --> risc0/cargo-risczero/src/commands/datasheet/mod.rs:41:38
   |
41 |     #[arg(long, value_name = "PATH", env = "RISC0_SERVER_PATH")]
   |                                      ^^^ method not found in `Arg`
```
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.

2 participants