File tree 4 files changed +13
-10
lines changed
v-next/hardhat/src/internal/builtin-plugins
4 files changed +13
-10
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ " hardhat " : patch
3
+ ---
4
+
5
+ Moved the calls to shouldMergeCompilationJobs from the task actions to the build system and made its' result the default fallback to use in absence of the mergeCompilationJobs option.
Original file line number Diff line number Diff line change @@ -14,7 +14,6 @@ import { resolveFromRoot } from "@nomicfoundation/hardhat-utils/path";
14
14
import { createNonClosingWriter } from "@nomicfoundation/hardhat-utils/stream" ;
15
15
import chalk from "chalk" ;
16
16
17
- import { shouldMergeCompilationJobs } from "../solidity/build-profiles.js" ;
18
17
import {
19
18
getArtifacts ,
20
19
getBuildInfos ,
@@ -75,9 +74,6 @@ const runSolidityTests: NewTaskActionFunction<TestActionArguments> = async (
75
74
const buildOptions : BuildOptions = {
76
75
force : false ,
77
76
buildProfile : hre . globalOptions . buildProfile ,
78
- mergeCompilationJobs : shouldMergeCompilationJobs (
79
- hre . globalOptions . buildProfile ,
80
- ) ,
81
77
quiet : true ,
82
78
} ;
83
79
Original file line number Diff line number Diff line change @@ -36,7 +36,10 @@ import debug from "debug";
36
36
import pMap from "p-map" ;
37
37
38
38
import { FileBuildResultType } from "../../../../types/solidity/build-system.js" ;
39
- import { DEFAULT_BUILD_PROFILE } from "../build-profiles.js" ;
39
+ import {
40
+ DEFAULT_BUILD_PROFILE ,
41
+ shouldMergeCompilationJobs ,
42
+ } from "../build-profiles.js" ;
40
43
41
44
import {
42
45
getArtifactsDeclarationFile ,
@@ -334,7 +337,10 @@ export class SolidityBuildSystemImplementation implements SolidityBuildSystem {
334
337
subgraphsWithConfig . push ( [ configOrError , subgraph ] ) ;
335
338
}
336
339
337
- if ( options ?. mergeCompilationJobs === true ) {
340
+ if (
341
+ options ?. mergeCompilationJobs ??
342
+ shouldMergeCompilationJobs ( buildProfileName )
343
+ ) {
338
344
log ( `Merging compilation jobs` ) ;
339
345
340
346
const mergedSubgraphsByConfig : Map <
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ import type { NewTaskActionFunction } from "../../../../types/tasks.js";
2
2
3
3
import { resolveFromRoot } from "@nomicfoundation/hardhat-utils/path" ;
4
4
5
- import { shouldMergeCompilationJobs } from "../build-profiles.js" ;
6
5
import { throwIfSolidityBuildFailed } from "../build-results.js" ;
7
6
import { isNpmRootPath } from "../build-system/root-paths-utils.js" ;
8
7
@@ -30,9 +29,6 @@ const compileAction: NewTaskActionFunction<CompileActionArguments> = async (
30
29
const results = await solidity . build ( rootPaths , {
31
30
force,
32
31
buildProfile : globalOptions . buildProfile ,
33
- mergeCompilationJobs : shouldMergeCompilationJobs (
34
- globalOptions . buildProfile ,
35
- ) ,
36
32
quiet,
37
33
} ) ;
38
34
You can’t perform that action at this time.
0 commit comments