Skip to content

chore(vdev): add --features flag and FEATURES env var support to build/check/test commands#25688

Merged
pront merged 5 commits into
masterfrom
pront/vdev-features-flag
Jun 30, 2026
Merged

chore(vdev): add --features flag and FEATURES env var support to build/check/test commands#25688
pront merged 5 commits into
masterfrom
pront/vdev-features-flag

Conversation

@pront

@pront pront commented Jun 26, 2026

Copy link
Copy Markdown
Member

Summary

All vdev commands that shell out to cargo with a feature set (check rust, build, test, crate_versions) previously accepted features as positional arguments or used an inconsistent --feature (singular) flag. This makes them non-obvious and inconsistent with cargo's own interface.

This PR:

  • Replaces the positional features argument in check rust with a named --features flag (short: -F, comma-separated)
  • Renames --feature--features in build vector and crate_versions
  • Adds an explicit --features flag to test (replacing the implicit passthrough hack)
  • Adds --no-default-features to check rust and test
  • Wires env = "FEATURES" on all --features flags so FEATURES=x,y make check-clippy now works

Before:

cargo vdev check rust default rdkafka-dynamic   # positional, non-obvious
FEATURES=x,y make check-clippy                  # silently ignored

After:

cargo vdev check rust --features default,rdkafka-dynamic
FEATURES=default,rdkafka-dynamic make check-clippy  # works

Vector configuration

N/A — vdev tooling change only.

How did you test this PR?

  • Verified cargo build -p vdev compiles cleanly
  • Pre-push hook ran cargo vdev check rust --all-features successfully
  • Manually verified --help output on check rust, build, test

Change Type

  • Bug fix
  • New feature
  • Dependencies
  • Non-functional (chore, refactoring, docs)
  • Performance

Is this a breaking change?

  • Yes
  • No

cargo vdev check rust <feature> <feature> (positional) no longer works. Replacement: cargo vdev check rust --features feat1,feat2.

Does this PR include user facing changes?

  • Yes. Please add a changelog fragment based on our guidelines.
  • No. A maintainer will apply the no-changelog label to this PR.

References

@github-actions github-actions Bot added the domain: vdev Anything related to the vdev tooling label Jun 26, 2026
@datadog-vectordotdev

datadog-vectordotdev Bot commented Jun 26, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 33945ff | Docs | Give us feedback!

@pront pront added the no-changelog Changes in this PR do not need user-facing explanations in the release changelog label Jun 26, 2026
@pront pront marked this pull request as ready for review June 26, 2026 21:38
@pront pront requested a review from a team as a code owner June 26, 2026 21:38

@chatgpt-codex-connector chatgpt-codex-connector Bot 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6d0febc2b2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread vdev/src/commands/check/rust.rs Outdated
Comment thread vdev/src/commands/test.rs Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 94bf42ceea

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread vdev/src/commands/check/rust.rs Outdated
Comment thread Makefile Outdated
@thomasqueirozb thomasqueirozb enabled auto-merge June 29, 2026 14:01
@pront pront disabled auto-merge June 29, 2026 14:17
@pront

pront commented Jun 29, 2026

Copy link
Copy Markdown
Member Author

Let's wait for #25690 which should simplify this PR.

@pront pront force-pushed the pront/vdev-features-flag branch from 07c329c to 3bdbdc0 Compare June 29, 2026 21:45
@pront pront force-pushed the pront/vdev-features-flag branch from 3bdbdc0 to 8fc5af0 Compare June 29, 2026 23:18
@github-actions github-actions Bot added the domain: ci Anything related to Vector's CI environment label Jun 29, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 41e6976b95

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread vdev/src/testing/runner.rs
Comment thread vdev/src/commands/test.rs
@pront pront added this pull request to the merge queue Jun 30, 2026
Merged via the queue into master with commit b4d7350 Jun 30, 2026
61 checks passed
@pront pront deleted the pront/vdev-features-flag branch June 30, 2026 02:09
@github-actions github-actions Bot locked and limited conversation to collaborators Jun 30, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

domain: ci Anything related to Vector's CI environment domain: vdev Anything related to the vdev tooling no-changelog Changes in this PR do not need user-facing explanations in the release changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chore(vdev): add --features flag to all vdev commands that invoke cargo

2 participants