16

I don't understand this error during xcode build:

Sandbox: bash(30970) deny(1) file-read-data /Users/.../ios/App/Pods/Target Support Files/Pods-[name]/Pods-[name]-frameworks.sh

can anyone help me please?

5
  • 6
    I have exact the same problem at the moment. Using an Ionic App with Capacitor. Sandbox: bash(26268) deny(1) file-read-data /Users/.../ios/App/Pods/Target Support Files/Pods-App/Pods-App-frameworks.sh Commented Dec 17, 2023 at 8:32
  • @Kisimedia.de Yes, I'm in the same boat. Commented Dec 26, 2023 at 12:05
  • @Kisimedia.de, i reinitialized my config and it was ok for me. So, I didn't understand this error Commented Jan 8, 2024 at 10:00
  • @YannaY I have the same problem, what did you do to solve it? What config did you reinitialize? Commented Apr 12, 2024 at 12:08
  • 1
    Related (no answer): stackoverflow.com/questions/77165105/… Commented May 13, 2024 at 12:44

1 Answer 1

41

This error seems to be caused by the fact that ENABLE_USER_SCRIPT_SANDBOXING in the build settings got switched to YES. This variable, intuitively, enables sandboxing for scripts that are run as build phases. So, when the build phase script simply calls an external script file, the build phase script can not get access either to the script file itself, or maybe to some of the files that the script tries to access, although I'm not sure if the latter would produce the same error.

A quick fix is to set ENABLE_USER_SCRIPT_SANDBOXING to NO in the Build Settings for both the project and the target (at least setting it just for the target didn't work for me).

The right way would be to leave it on, but configure input / output files for the script, however I was not able to do it right away and resorted to the "quick and dirty" solution, since all the scripts in the project are mine.

Here a user was able to get the scripts to run by adding the script itself into input/output files, but it didn't work for me.

Sign up to request clarification or add additional context in comments.

2 Comments

It works and should be an accepted answer! Thx!
You're welcome :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.