Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding file level logging of input file glob hashes (Silly logging) #682

Merged
merged 10 commits into from
Jul 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "patch",
"comment": "Log file level input file hashes to silly logs",
"packageName": "@lage-run/hasher",
"email": "[email protected]",
"dependentChangeType": "patch"
}
2 changes: 1 addition & 1 deletion docs/docs/Reference/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Usage: `lage [run] <command1> [command2...commandN] [options] run commands`
--reset-cache resets the cache, filling it after a run
--skip-local-cache skips caching locally
--profile [profile] writes a run profile into a file that can be processed by Chromium devtool
--nodearg <nodeArg> arguments to be passed to node (e.g. --nodearg="--max_old_space_size=1234 --heap-prof" - set via "NODE_OPTIONS" environment variable
--nodearg <nodeArg> arguments to be passed to node (e.g. --nodearg="--max_old_space_size=1234 --heap-prof" - set via "NODE_OPTIONS" environment variable)
--continue continues the run even on error
-h, --help display help for command
```
Expand Down
3 changes: 3 additions & 0 deletions packages/hasher/src/TargetHasher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,9 @@ export class TargetHasher {
if (this.logger !== undefined) {
const globalInputsHash = hashStrings(Object.values(this.globalInputsHash ?? {}));
this.logger.verbose(`Global inputs hash: ${globalInputsHash}`);
// Log global input hashs to log file
const globalInputsHashJson = JSON.stringify(this.globalInputsHash, null, 2);
this.logger.silly(globalInputsHashJson);
}
}

Expand Down