Skip to content

Commit

Permalink
fix(core): skip eslint custom hasher when hashing tasks during runnin…
Browse files Browse the repository at this point in the history
…g commands
  • Loading branch information
jaysoo committed Oct 23, 2024
1 parent 0d2e02b commit b466f3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion packages/eslint/src/executors/lint/hasher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,15 @@ export default async function run(
hashes.push(res.details.nodes[d]);
}
}
return {
const hashResult = {
value: hashArray([command, selfSource, ...hashes, tags]),
details: {
command,
nodes: { [task.target.project]: selfSource, tags, ...nodes },
},
};
hashResult['name'] = 'eslint-hasher';
return hashResult;
}

function allDeps(
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/hasher/hash-task.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export async function hashTasksThatDoNotDependOnOutputsOfOtherTasks(
const tasksToHash = tasksWithHashers
.filter(({ task, customHasher }) => {
// If a task has a custom hasher, it might depend on the outputs of other tasks
if (customHasher) {
if (customHasher && customHasher.name !== 'eslint-hasher') {
return false;
}

Expand Down

0 comments on commit b466f3c

Please sign in to comment.