Skip to content

Conversation

@pablochacin
Copy link
Contributor

@pablochacin pablochacin commented Nov 19, 2025

What?

Introduces support for a dependencies manifest that specifies the default versions for dependencies that do not specify version constraints (using pragmas). The manifest is passed as a JSON in the K6_DEPENDENCIES_MANIFEST environment variable.

Why?

In some use cases (for example, when running in the k6 cloud), it is convenient to have a default for the dependencies that does not specify constraints, to make the tests reproducible without having to use pragmas.

Checklist

  • I have performed a self-review of my code.
  • I have commented on my code, particularly in hard-to-understand areas.
  • I have added tests for my changes.
  • [ X I have run linter and tests locally (make check) and all pass.

Checklist: Documentation (only for k6 maintainers and if relevant)

Please do not merge this PR until the following items are filled out.

  • I have added the correct milestone and labels to the PR.
  • I have updated the release notes: link
  • I have updated or added an issue to the k6-documentation: grafana/k6-docs#NUMBER if applicable
  • I have updated or added an issue to the TypeScript definitions: grafana/k6-DefinitelyTyped#NUMBER if applicable

Related PR(s)/Issue(s)

Closes #1590

This does include dependancies that might be needed for building a new
binary with auto extension resolution, but also all imports.

Similar to auto extension resolution, this does take into account only
imports not `require` calls.

Closes #5166
@pablochacin pablochacin temporarily deployed to azure-trusted-signing November 19, 2025 13:12 — with GitHub Actions Inactive
@pablochacin pablochacin temporarily deployed to azure-trusted-signing November 19, 2025 13:14 — with GitHub Actions Inactive
@pablochacin pablochacin force-pushed the support-dependencies-manifest branch from cc3bd9c to 447e6fc Compare November 19, 2025 13:21
@pablochacin pablochacin temporarily deployed to azure-trusted-signing November 19, 2025 13:27 — with GitHub Actions Inactive
@pablochacin pablochacin temporarily deployed to azure-trusted-signing November 19, 2025 13:29 — with GitHub Actions Inactive
Signed-off-by: Pablo Chacin <pablochacin@gmail.com>
@pablochacin pablochacin force-pushed the support-dependencies-manifest branch from 447e6fc to 7ee57dd Compare November 19, 2025 13:33
@pablochacin pablochacin temporarily deployed to azure-trusted-signing November 19, 2025 13:39 — with GitHub Actions Inactive
@pablochacin pablochacin temporarily deployed to azure-trusted-signing November 19, 2025 13:41 — with GitHub Actions Inactive
@pablochacin pablochacin added this to the v1.5.0 milestone Nov 19, 2025
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