Merged
Conversation
…sion Disabling this flag prevents warp from depending on files in the GHC distribution and may lead to a smaller runtime dependency closure.
Vlix
approved these changes
Aug 31, 2025
Contributor
Vlix
left a comment
There was a problem hiding this comment.
I think this is acceptable. I can also imagine some people would not want to broadcast the warp version for security reasons, so this would kill two birds with one stone 👍 .
If all the CI runs correctly and you add the default to the flag, this can be merged :)
| sendResponse, | ||
| sanitizeHeaderValue, -- for testing | ||
| -- Provided here for backwards compatibility. | ||
| warpVersion, |
There was a problem hiding this comment.
Question for the maintainers: should we deprecate this and remove it in a future version?
{-# DEPRECATED warpVersion "some message" #-}
warpVersion = Network.Wai.Handler.Warp.Settings.warpVersion
Contributor
There was a problem hiding this comment.
I don't have a strong opinion.
Contributor
There was a problem hiding this comment.
I don't feel like it's worth it, but thanks for the suggestion 👍
Contributor
|
I'll try to merge and publish this change this weekend. |
Contributor
|
Published as warp-3.4.9 |
lf-
added a commit
to lf-/nixpkgs
that referenced
this pull request
Jan 23, 2026
This was made possible to disable, which we should really probably just do. It might make some HTTP servers not return their version in a header, but that feels like an antipattern anyhow. See: yesodweb/wai#1044 See: https://github.com/NixOS/nixpkgs/blob/ecdb2e3a81213177cde9ce769e5f086ff24387b6/pkgs/development/haskell-modules/configuration-darwin.nix#L363-L372
13 tasks
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Presented as a backward-compatible alternative to #1042.
Use of
Paths_warpcauses a large dependency closure when building with nix. See NixOS/nixpkgs#264434 for example. Building our application against this branch with the new flag disabled drastically reduces the closure size of our application by virtue of not including GHC and GCC as runtime dependencies.I have made some minor refactors as requested by @Vlix in #1042.
Before submitting your PR, check that you've:
@sincedeclarations to the HaddockAfter submitting your PR:
Closes #1042.