Xcode does not let me open existing project

On my MacBook Pro M3 Pro, I have got any kind of project (C, Java, ...).

By opening Xcode, on the main window I choose "Open Existing Project...":

then I choose one of my project folders in /Users/giuliano/Documents/NaTour21, finally, I click "Open" and this comes out:

This happens for every project. Is it mandatory to have a workspace?

MacBook Pro 16″, macOS 14.2

Posted on Jan 22, 2024 10:16 AM

Reply
Question marked as Top-ranking reply

Posted on Jan 23, 2024 7:23 AM

If you use a command-line command such as the following on the directory and within the projects, does the quarantine flag show? If so, you will need ro remove that.

ls -ale@ /path/to/source/code


To (recursively!) remove the quarantine flag (aim carefully!):

xattr -d com.apple.quarantine -r /path/to/source/code


Similar questions

18 replies
Question marked as Top-ranking reply

Jan 23, 2024 7:23 AM in response to giulianoaiello

If you use a command-line command such as the following on the directory and within the projects, does the quarantine flag show? If so, you will need ro remove that.

ls -ale@ /path/to/source/code


To (recursively!) remove the quarantine flag (aim carefully!):

xattr -d com.apple.quarantine -r /path/to/source/code


Jan 22, 2024 11:33 AM in response to giulianoaiello

File ownerships and protections checked on the existing projects?


Does opening a new project also (not?) work?


What was the version of Xcode in use for the existing projects? An old one?


Any add-on security or add-on VPN clients or add-on cleaners or add-on anti-malware apps involved?


What have you already checked, past the failed open of an existing project?


A Mac (here) newly upgraded to Xcode 15.2 with locally-stored project and playground files is working as expected.

Feb 18, 2024 9:00 AM in response to giulianoaiello

giulianoaiello wrote:

Is it mandatory to have a workspace?

I think that question was part of the problem. We didn't you that you didn't know what a workspace was.


A workspace is a specific kind of "umbrella" project file. You can define a workspace file that links multiple project files together to form a functional whole.


And to make it even more complicated, the answer to "is it mandatory to have a workspace?" is complicated. I just don't know. 3 years ago, I would have said "yes", in some cases. Now, I'm not so sure. I have very complicated Xcode projects right now and I'm not using workspace files. Maybe this is an improvement in recent versions of Xcode? I don't know.


But Xcode definitely needs to have some kind of project file that defines the files included in your, ahem, workspace. I build my websites in Xcode, but that's pretty unusual. For most people, Xcode is strictly a tool for building iPhone apps. I can't fault them for that. There are lots of people who make things much more difficult for themselves by not using Xcode for this. But Xcode definitely can be used as a general-purpose IDE. You will need a project file. You might also have to learn some rather obscure and poorly-supported features like makefile-based projects. But with some effort, you can use Xcode for practically anything developer-related.

Jan 23, 2024 9:40 AM in response to MrHoffman

This is the command output:

giuliano@MBP-di-Giuliano Documents % ls -ale@ server_randomChat   
total 16
drwxr-xr-x@  8 giuliano  staff  256 Jan 22 22:35 .
	com.apple.macl	 72 
drwx------+  5 giuliano  staff  160 Jan 22 22:35 ..
 0: group:everyone deny delete
drwxr-xr-x  12 giuliano  staff  384 Jan 22 22:35 .git
-rw-r--r--   1 giuliano  staff   73 Jan 22 22:35 README.md
drwxr-xr-x   4 giuliano  staff  128 Jan 22 22:35 <file>
drwxr-xr-x   4 giuliano  staff  128 Jan 22 22:35 <file>
-rw-r--r--   1 giuliano  staff  886 Jan 22 22:35 <file>
drwxr-xr-x   4 giuliano  staff  128 Jan 22 22:35 <file>


So, I think the quarantine flag is not set, unfortunately.

Jan 22, 2024 12:43 PM in response to MrHoffman

  1. Tried even after a `chmod 777 <project>`.
  2. All project gives me this problem, even other kind of project like I specified initially.
  3. 15.2, it's my first time using MacBook and Xcode.
  4. No.
  5. Checked documentation, online forums, nothing else on my Mac. I couldn't have done anything particular on a new pc.


I don't know if this could be useful: following the same steps I defined, if I open a single file it works as expected, so I can do on Xcode "File" -> "Add Files..." -> then I select a project and I can get it on my Xcode window. This is obviously awful, I even have to delete the reference to the file I initially opened.

Feb 2, 2024 9:59 AM in response to MrHoffman

As I told, there isn't a specific project, every project won't open. Anyway you can test every project: https://github.com/FueledBy-Pizza.

I even asked for help to Apple Support and Apple Developer Program Support, but this question "fall outside their realm of expertise".

Now I'm reporting this at Feedback - MacBook Pro - Apple.

Thank you all for your support anyway, if you got any news, you can freely respond to this topic.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Xcode does not let me open existing project

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.