Begin factoring out the protocol code#1165
Conversation
|
I think it's better to start using the |
|
@edolstra I agree in principle, but I am very afraid of making too many changes too quickly. With this approach, I can and preserve things like the fact the the hydra Long term, yes, I absolutely do want to use the store abstraction! But I want to get there very incrementally to avoid any regressions. |
ce36d10 to
c1fa2f9
Compare
c1fa2f9 to
621cc72
Compare
|
It's passing locally! (CI should soon catch up :)) |
|
|
||
| // Do not attempt to speak a newer version of the protocol | ||
| conn.remoteVersion = std::min(conn.remoteVersion, our_version); |
There was a problem hiding this comment.
I am shocked we got away with not having this...ever! If the two sides don't agree on a version, how can anything work?!
c07679b to
d972791
Compare
d972791 to
95841a7
Compare
- Use the type itself This lays the foundation for being able to dedup the protocol code. - Use `BasicConnection::handshake`, replacing ours. - Use `BasicConnection::queryValidPaths` - Use `BasicConnection::putBuildDerivationRequest`
95841a7 to
4ac31c8
Compare
After a few preparatory moves, this does
cmdQueryValidPathsSee each commit for details and easier reviewing.
Progress towards #1164
This targets
nix-nextnotmaster, so it is fine that this depends on an unreleased version of Nix. Only the Nix PR needs to be merged first.Depends on NixOS/nix#6134
Depends on #1324