-
-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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
[Reverted] Module-builtin assertions, disabling assertions and submodule assertions #97023
Merged
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
0b61ed7
lib/options: Don't show internal suboption in the manual
infinisil df5ba82
lib/modules: Implement module-builtin assertions
infinisil 9523df7
nixos/assertions: Use module-builtin assertion implementation
infinisil 2013134
lib/modules: Use module-builtin assertions for mkRemovedOptionModule …
infinisil 1e6a84b
nixos/modules: Allow options to be coerced to a string for convenience
infinisil 3759a77
nixos/modules: Expose the internal module in the top-level documentation
infinisil c4fb54e
nixos/docs: Update assertion docs for new module-builtin ones
infinisil 900c4a5
lib/tests: Implement generalized checkConfigCodeOutErr for module tests
infinisil 3e39d6e
lib/tests: Add tests for module-builtin assertions
infinisil c9cc896
lib/modules: Rename _module.assertions to _module.checks
infinisil 8dea4df
lib/modules: Remove _module.checks.*.triggerPath as it's not necessary
infinisil 991dfcc
lib/modules: _module.check should always be internal
infinisil 767d800
lib/modules: Introduce _module.checks.*.check
infinisil a6a70d1
lib/modules: Prefix mkRemovedOptionModule & co. check names
infinisil File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
|
||
_module.checks.test = { | ||
check = true; | ||
message = "Assertion failed"; | ||
}; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
|
||
_module.checks.test = { | ||
enable = false; | ||
check = false; | ||
message = "Assertion failed"; | ||
}; | ||
|
||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"lint"
would be a nice additional type: like warnings, but not shown by default, because they are low priority and may be wrong.The user would have to enable lint visibility with an option to turn them into trace messages (warnings?), or use a tool like
nix repl
to find the lint messages.