# Error while using build cache for Xcode

**URL:** https://discuss.bitrise.io/t/error-while-using-build-cache-for-xcode/25743
**Category:** iOS
**Tags:** build-cache, xcode
**Created:** [January 15, 2026, 7:40pm UTC](https://discuss.bitrise.io/t/error-while-using-build-cache-for-xcode/25743 "2026-01-15T19:40:04Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![jonathan.cuendet](https://avatars.discourse-cdn.com/v4/letter/j/50afbb/32.png) [@jonathan.cuendet](https://discuss.bitrise.io/u/jonathan.cuendet)
#### Post date: [January 15, 2026, 7:40pm UTC](https://discuss.bitrise.io/t/error-while-using-build-cache-for-xcode/25743/1 "2026-01-15T19:40:04Z")

</div>

I’m trying to activate build cache for Xcode step in my bitrise.yaml file, if it’s “off”, my pipeline works without any issues, but if I turn it on, I hit the bellow error.

I tried several solutions from updating fastlane and ruby, but with no avail, need some help regarding this. I’ve found several mentions that it might be related to the -json flag. but it’s vague.

any help is much appreciated. thanks in Advance  
Jonathan

> **Error log (relevant bits)**
>
> [Bitrise Analytics] Run stats: {StartTime:2026-01-15 18:58:18.162436 +0000 GMT m=+0.016612793 Success:true Error: ExitCode:0 DurationMS:314 XcodeVersion:26.0.1 XcodeBuildNumber:17A400}
> 
> [Bitrise Analytics] Proxy stats: uploaded bytes: 0 B, downloaded bytes: 0 B, hits: 0, misses: 0
> 
> [Bitrise Analytics] Short command found: -showsdks
> 
> [Bitrise Analytics] Sending invocation data to: [https://xcode-analytics.services.bitrise.io/invocations/77f81e37-47e2-45af-a39c-c591849a696f](https://xcode-analytics.services.bitrise.io/invocations/77f81e37-47e2-45af-a39c-c591849a696f)
> 
> [Bitrise Analytics] Payload: { [REDACTED] }
> 
> [Bitrise Analytics] [DEBUG] PUT [https://xcode-analytics.services.bitrise.io/invocations/](https://xcode-analytics.services.bitrise.io/invocations/)…
> 
> [Bitrise Analytics] [18:58:18] Invocation saved. Visit 👉 [https://app.bitrise.io/build-cache/invocations/xcode/](https://app.bitrise.io/build-cache/invocations/xcode/)…
> 
> [18:58:18]: expected ‘,’ or ‘]’ after array value at line 1 column 4
> 
> [18:58:18]: xcodebuild CLI broken, please run `xcodebuild` and make sure it works

---

<div class="post-metadata">

### Author: ![viktorbenei](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/viktorbenei/32/18_2.png) [@viktorbenei](https://discuss.bitrise.io/u/viktorbenei)
#### Post date: [January 20, 2026, 1:42pm UTC](https://discuss.bitrise.io/t/error-while-using-build-cache-for-xcode/25743/2 "2026-01-20T13:42:40Z")

</div>

Hi @jonathan.cuendet !

The error you’re seeing is likely caused by the `Build Cache for Xcode` step adding debug logging information to the `xcodebuild` output. When certain fastlane actions (or other tools) attempts to parse `xcodebuild`’s JSON output with the `-json` flag, these additional logs can interfere with the JSON parsing, causing the error you’re experiencing.

**Solution:**

Try setting the **`Silence all extra Bitrise logging`** input of the `Build Cache for Xcode` step to **`true`**.

 ![Screenshot 2026-01-20 at 2.42.22 PM](https://us1.discourse-cdn.com/flex016/uploads/bitrise/original/2X/5/5e89d8f1ca7e16830a98ceeb9671821a5ed6beda.png)

**A bit more details:**

By default, the Build Cache for Xcode step adds helpful debug information to the logs, which is useful for troubleshooting cache-related issues. However, some tools (like certain fastlane actions) depend on the exact output format produced by xcodebuild. The extra debug logs can break JSON parsing or other output-dependent functionality in these tools.

Setting `Silence all extra Bitrise logging` to `true` will suppress these additional logs, allowing fastlane to correctly parse xcodebuild’s JSON output.

Let us know if this resolves the issue!

---

<div class="post-metadata">

### Author: ![zsolt.marta](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/zsolt.marta/32/7307_2.png) [@zsolt.marta](https://discuss.bitrise.io/u/zsolt.marta)
#### Post date: [February 4, 2026, 9:16am UTC](https://discuss.bitrise.io/t/error-while-using-build-cache-for-xcode/25743/3 "2026-02-04T09:16:55Z")

</div>

Hi!

As an additional follow up, we have released a change to our wrapper logic that silences all logging automatically if `-json` is passed to `xcodebuild`.
