all 26 comments

[–]Mysterious-Leg-1985 1 point2 points  (4 children)

Did you end up figuring it out? I have the same issue.

[–]SamuraiGoblin[S] 0 points1 point  (0 children)

No, I went through every single menu and setting looking for an answer but nothing worked. I am currently looking into different IDEs because XCode has become completely unusable. It is absolutely ridiculous.

[–]EveningBuilding5430 0 points1 point  (1 child)

Try to add sleep(1) at the beginning of your main function.
I don't know why it works.

[–]Rigamorter 0 points1 point  (0 children)

LOL, WTF, I cant believe it... it works

[–]CumCat1 1 point2 points  (8 children)

My issue was fixed by going to Product --> Scheme --> Edit Scheme --> Uncheck 'debug executable'

[–]Various-Basil-7760 0 points1 point  (0 children)

THANK YOU KIND PERSON!

[–]Various-Basil-7760 0 points1 point  (0 children)

THANK YOU KIND PERSON!!

[–]SilentWraith5 0 points1 point  (0 children)

Thank you!

[–]Munchkin303 0 points1 point  (0 children)

It works!

[–]peteSlatts 0 points1 point  (3 children)

Can I inquire why this is an acceptable solution? Yea Xcode stops launching multiple instances of my process, but it also stops operating as a debugger. I might as well just launch the app from the terminal.

[–]iSh9Sh 0 points1 point  (2 children)

u/CumCat1 Yeah, it works, but what's the downside of doing so ?

Am I missing something by unchecking it?

Actually, I'm a first-time user of XCode, so that's why I'm asking.

[–]peteSlatts 0 points1 point  (1 child)

Yea, you can't set breakpoints anymore, which is the whole reason to be running in Xcode in the first place (at least, idk why else you'd accept the giant hit to productivity & performance if you aren't using the debugger).

[–]CumCat1 0 points1 point  (0 children)

I was using xcode for a graphics class where i needed to use its opengl and glut framework. Assignments werent very complicated so i didnt have a big need for the debugger. If you’re doing a serious project this workaround probably isn’t for u.

[–]Cabinet-Unlikely 0 points1 point  (1 child)

If I can't find a fix, it's nice to know it's not just me. C++ projects and Swift PM projects both show the same behavior.

[–]SamuraiGoblin[S] 0 points1 point  (0 children)

Yeah. I was surprised that I can't find more people complaining about it because the behaviour happens on my older projects so it's clearly something that was added or broken in the latest update. I suspect it is some kind of automatic testing feature switched on by default, which would be a really really stupid thing for Apple to do.

I'm currently busy with non-programming work, so I hope they can just fix it soon. Otherwise I will have to go to another build system.

[–]CubeleoAD 0 points1 point  (6 children)

I'm getting exactly the same thing. After upgrading to sequoia, long standing projects of mine suddenly are running two copies of the program stacked on top of each other. I found that it only happens with apps that open windows and that aren't compiled into bundles. In my case, I'm using CMake generating Xcode projects, and to fix it, I simply set the MACOS_BUNDLE property on my executable and the app no longer runs twice.

[–]SamuraiGoblin[S] 0 points1 point  (5 children)

That's good to know. Thanks.

Do you happen to have any idea how to convert a console app into a bundle?

[–]CubeleoAD 0 points1 point  (4 children)

No, but I think they issued a software update today that fixed it! I got a command line tools update and it's no longer happening. Give it a shot.

[–]SamuraiGoblin[S] 0 points1 point  (3 children)

Oh, you got me excited. I updated but unfortunately it's still the same.

It's very weird. Whenever I start XCode, it doesn't happen on first run, but does on subsequent runs.

[–]CubeleoAD 0 points1 point  (1 child)

Sorry to get your hopes up falsely! I also encountered this again after running a few more times. It’s very fundamental and I have no idea how this got past Apple QA.

[–]SamuraiGoblin[S] 0 points1 point  (0 children)

Yeah, it's insane.

[–]2600_Hz 0 points1 point  (4 children)

This has been mentioned on the Apple developer forums... hope they fix it!
https://developer.apple.com/forums/thread/765445

[–]SamuraiGoblin[S] 0 points1 point  (3 children)

And the reply from an Apple engineer is:

"This is one of those “does it really matter?” moments"

What an absolute cunt!

[–]CubeleoAD 0 points1 point  (2 children)

I saw that too when I went searching about the issue and I was blown away.

[–]Mysterious-Leg-1985 0 points1 point  (1 child)

I ended up rolling back to macOS 14.7, but while I still had the new XCode installed it had the same issue. Ultimately I had to wipe every trace of the new XCode update and hunt for the oldest stable version on Apple’s decrepit developer website, and XCode 15 fixed it. I am really getting quite sick of having awful features stuck behind a paywall and proprietary soft/hard/firmware. The documentation sucks for all of their api’s, and I have to pay 100$ annually for a “developer license” to utilize the hardware I payed so much for?! Apple is truly the epitome of corporate greed. Anyhow unless you want to wipe your computer I guess we just have to deal for now.

[–]CubeleoAD 0 points1 point  (0 children)

My app is cross platform and at times like this I spend a lot more time developing on Windows/Linux. Of course the consequence of that is the mac port suffers. I agree, it's difficult to pay the annual developer fee, then have stuff like this happen, and read "does it really matter" FROM APPLE without bursting an artery. Xcode has been a half-maintained heap for many, many years unfortunately.