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

Gate experimental features in DerivationOutput::fromJSON #8231

Merged
merged 1 commit into from
Apr 18, 2023

Conversation

Ericson2314
Copy link
Member

Motivation

This is an entry point for outside data, so we need to check enabled experimental features here.

Context

I should have done this when nix derivation add was added in #7887, but I forgot. Sorry!

Checklist for maintainers

Maintainers: tick if completed or explain if not relevant

  • agreed on idea
  • agreed on implementation strategy
  • tests, as appropriate
    • functional tests - tests/**.sh
    • unit tests - src/*/tests
    • integration tests - tests/nixos/*
  • documentation in the manual
  • documentation in the internal API docs
  • code and comments are self-explanatory
  • commit message explains why the change was made
  • new feature or incompatible change: updated release notes

Priorities

Add 👍 to pull requests you find important.

@github-actions github-actions bot added the with-tests Issues related to testing. PRs with tests have some priority label Apr 17, 2023
@Ericson2314 Ericson2314 force-pushed the add-derivation-xp-gates branch from 1585ad2 to 3109914 Compare April 17, 2023 17:00
@Ericson2314 Ericson2314 force-pushed the add-derivation-xp-gates branch from 3109914 to 9aa9818 Compare April 17, 2023 21:34
This is an entry point for outside data, so we need to check enabled
experimental features here.
@@ -136,11 +136,15 @@ struct DerivationOutput : _DerivationOutputRaw
const Store & store,
std::string_view drvName,
std::string_view outputName) const;
/**
* @param xpSettings Stop-gap to avoid globals during unit tests.
Copy link
Member

Choose a reason for hiding this comment

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

Testability is important enough to warrant a parameter like this, but it is transitively a stop-gap, because experimental features are a stop-gap.

@github-actions
Copy link

Successfully created backport PR for 2.15-maintenance:

@Ericson2314 Ericson2314 deleted the add-derivation-xp-gates branch April 18, 2023 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
with-tests Issues related to testing. PRs with tests have some priority
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants