MobileNativeFoundation / rules_xcodeproj

Bazel rules for generating Xcode projects.
MIT License
521 stars 83 forks source link

Invalid Index Stores Warning #3031

Open ed-irl opened 4 months ago

ed-irl commented 4 months ago

Hello, I have a project where I frequently see the following (and similar) warnings:

warning: Previous run of "import_indexstores" had output:
warning: error: invalid index store directory /var/tmp/path/to/some/module.indexstore
warning: If you believe this is a bug, please file a report here: https://github.com/MobileNativeFoundation/rules_xcodeproj/issues/new?template=bug.md
Command PhaseScriptExecution emitted errors but did not return a nonzero exit code to indicate failure

When I inspect these directories, they are always empty.

The specific module affected by the warning is nondeterministic, however the target always seems to always be a swift_library. It does not appear when building via the command line using bazel build .... I was unable to create a minimal repro, which combined with the nondeterminism makes me suspect that the project perhaps needs to be of a certain size or complexity. I do not observe any negative side effects in actually building and running the app due to these messages.

I am using rules_xcodeproj version 2.3.1. I am using rules_swift_package_manager.

This is my bazelrc:

common --enable_bzlmod
common --color=yes
build --java_runtime_version=remotejdk_17
build --tool_java_language_version=17
build --tool_java_runtime_version=remotejdk_17
test --test_output=errors
test --test_verbose_timeout_warnings

build --repo_env=BAZEL_CXXOPTS="-std=c++14"
build --cxxopt='-std=c++14'
build --host_cxxopt='-std=c++14'

build:rules_xcodeproj --apple_generate_dsym
build:rules_xcodeproj --output_groups=+dsyms

I have not otherwise changed the rules_xcodeproj flags.

Thank you!

brentleyjones commented 4 months ago

A repro really will be needed in order to debug something like this.