You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
.DS_Store is a file sometimes added to a directory on MacOS by the operating system (it has to do with file system indexing I think). Sometimes these .DS_Store sneak themselves into npm package repositories (generated by rules_js) then copied with this action here:
I’m some debugging remote cache misses on MacOS and when I look at the execution log, I’m seeing .DS_Store appearing in the diff. Example from one of the execution log diffs I generated following “Debugging Remote Cache Hits for Remote Execution”:
How could I configure copy_directory() to ignore .DS_Store files if they’re present to prevent remote caching misses? Ideally I think copy_directory() should probably ignore .DS_Store files automatically since it’s very unlikely they’re contributing to the build.
I haven’t proven this is the incompatibility between the two MacOS machines which is causing the remote cache miss but figured it may be worth addressing whether or not it’s the incompatibility causing my remote caching misses.
Version
Development (host) and target OS/architectures: MacOS arm64
Interesting one. It does look like that .DS_Store file snuck into that the external repository directory external/npm__phosphor-react__1.4.1__-440667795/package/ as it is not found in the package archive: https://unpkg.com/browse/[email protected]/
I could see some blanket ignores in the copy_directory rule to avoid copying files such as .DS_Store that are automatically injected by the OS... In the latest rules_js this should be less of an issue since most npm packages should be extracted directly into the output tree from the download tar unless they have a patch applied or have a lifecycle hook.
What happened?
.DS_Store
is a file sometimes added to a directory on MacOS by the operating system (it has to do with file system indexing I think). Sometimes these.DS_Store
sneak themselves into npm package repositories (generated byrules_js
) then copied with this action here:https://github.com/aspect-build/rules_js/blob/d0ff155c73e3c7fee5d72485e00775bca1fde10a/npm/private/npm_package_store.bzl#L222-L232
I’m some debugging remote cache misses on MacOS and when I look at the execution log, I’m seeing
.DS_Store
appearing in the diff. Example from one of the execution log diffs I generated following “Debugging Remote Cache Hits for Remote Execution”:I know this is
copy_directory
related since when I go to the log file this is from and look for the command I see this snippet:How could I configure
copy_directory()
to ignore.DS_Store
files if they’re present to prevent remote caching misses? Ideally I thinkcopy_directory()
should probably ignore.DS_Store
files automatically since it’s very unlikely they’re contributing to the build.I haven’t proven this is the incompatibility between the two MacOS machines which is causing the remote cache miss but figured it may be worth addressing whether or not it’s the incompatibility causing my remote caching misses.
Version
Development (host) and target OS/architectures: MacOS arm64
Output of
bazel --version
:Version of the Aspect rules, or other relevant rules from your
WORKSPACE
orMODULE.bazel
file:aspect_bazel_lib
v1.42.3rules_nodejs
v5.8.4aspect_rules_js
v1.42.3Language(s) and/or frameworks involved: Node.js, JavaScript, pnpm
The text was updated successfully, but these errors were encountered: