@@ -308,7 +308,10 @@ final: prev: {
308308 assert isNull sha256;
309309 builtins.fetchGit
310310 ({ inherit url rev; } //
311− final.buildPackages.lib.optionalAttrs (ref != null) { inherit ref; }
311+ (if ref != null
312+ then { inherit ref; }
313+ # Don't fail if rev not in default branch:
314+ else { allRefs = true; })
312315 )
313316 else
314317 # Non-private repos must have sha256 set.
@@ -402,7 +405,10 @@ final: prev: {
402405 then
403406 builtins.fetchGit
404407 ({ inherit url rev; } //
405− final.buildPackages.lib.optionalAttrs (ref != null) { inherit ref; }
408+ (if ref != null
409+ then { inherit ref; }
410+ # don't fail if rev not in default branch:
411+ else { allRefs = true; })
406412 )
407413 else
408414 final.evalPackages.fetchgit { inherit url rev sha256; };
@@ -725,6 +731,9 @@ final: prev: {
725731 ++ final.lib.mapAttrsToList (n: v:
726732 { name = "${prefix}${packageName}:test:${n}"; value = v; })
727733 (package.components.tests)
734+ ++ final.lib.mapAttrsToList (n: v:
735+ { name = "${prefix}${packageName}:benchmarks:${n}"; value = v; })
736+ (package.components.benchmarks)
728737 ) (packageNames project);
729738 checksForProject = prefix: project:
730739 final.lib.concatMap (packageName: