Add a dummy Store::buildPaths() method
This default implementation of buildPaths() does nothing if all
requested paths are already valid, and throws an "unsupported
operation" error otherwise. This fixes a regression introduced by
c30330df6f in binary cache and legacy
SSH stores.
			
			
This commit is contained in:
		
							parent
							
								
									b0b81b7500
								
							
						
					
					
						commit
						0dddcf867a
					
				
					 5 changed files with 36 additions and 38 deletions
				
			
		| 
						 | 
				
			
			@ -148,12 +148,6 @@ struct LegacySSHStore : public Store
 | 
			
		|||
        sink(*savedNAR.data);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /* Unsupported methods. */
 | 
			
		||||
    [[noreturn]] void unsupported()
 | 
			
		||||
    {
 | 
			
		||||
        throw Error("operation not supported on SSH stores");
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    PathSet queryAllValidPaths() override { unsupported(); }
 | 
			
		||||
 | 
			
		||||
    void queryReferrers(const Path & path, PathSet & referrers) override
 | 
			
		||||
| 
						 | 
				
			
			@ -177,9 +171,6 @@ struct LegacySSHStore : public Store
 | 
			
		|||
        const PathSet & references, bool repair) override
 | 
			
		||||
    { unsupported(); }
 | 
			
		||||
 | 
			
		||||
    void buildPaths(const PathSet & paths, BuildMode buildMode) override
 | 
			
		||||
    { unsupported(); }
 | 
			
		||||
 | 
			
		||||
    BuildResult buildDerivation(const Path & drvPath, const BasicDerivation & drv,
 | 
			
		||||
        BuildMode buildMode) override
 | 
			
		||||
    { unsupported(); }
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue