I have problem with Xcode.. if I want to run any playground even simple code like : print("Hello "), it is not working,
some time stuck on 'running' and won't run the code,
I tried to reinstalling and delete xcode files ...
but it's still not working
this is the message that appears:
( Failed to launch process. Unable to lookup in current state: Shutting Down )
..
Failed to launch process. Unable to lookup service com.apple.CoreSimulator.host_support: 0xfffffecc )
it's last version 8.2.1(8C1002)
This fixed it for me:-
Go to menu Xcode->Preferences->Components then select and install the most recent Simulator.
MyPlayground is constantly syncing to iCloud.
Sometimes because of buggy behavior or poor connection is stucks on "Running"
Just go to:
System Preferences - Apple ID - Apps on this Mac using iCloud- iCloud Drive - Options- And then uncheck "Playground"
That little trick prevents syncing and resolves the frozen "Running".
Related
i had to reinstall my MacBook Pro. I have installed the newest macOS & Xcode version so
macOS Monterey 12.0.1 (21A559)
and
Version 13.1 (13A1030d)
I'm programming Audio plugins so to test my plugins I'm normally running a DAW (Digital Audio Workstation) in my case I'm working the most of the time with Ableton or Bitwig.
So if I start the debuging process, I get the follow error:
Could not attach to pid XXXXXX
attach failed (Not allowed to attach to process. Look in the console messages (Console.app), near the debugserver entries, when the attach failed. The subsystem that denied the attach permission will likely have logged an informative message about why it was denied.)
If I have an eye to the console.app the the following lines:
[LaunchAttach] (3277) about to task_for_pid(2930)
error: [LaunchAttach] MachTask::TaskPortForProcessID
task_for_pid(2930) failed: ::task_for_pid ( target_tport = 0x0203, pid
= 2930, &task ) => err = 0x00000005 ((os/kern) failure)
macOSTaskPolicy: (com.apple.debugserver) may not get the task control
port of (BitwigStudio) (pid: 2930): (BitwigStudio) is hardened,
(BitwigStudio) doesn't have get-task-allow, (com.apple.debugserver) is
a declared debugger(com.apple.debugserver) is not a declared read-only
debugger
1 +0.000000 sec [0ccd/0103]: error: ::task_for_pid ( target_tport =
0x0203, pid = 2930, &task ) => err = 0x00000005 ((os/kern) failure)
err = ::task_for_pid ( target_tport = 0x0203, pid = 2930, &task ) =>
err = 0x00000005 ((os/kern) failure) (0x00000005)
I have done some research and found this:
Stackoverflow link about What does get-task-allow do
get-task-allow, when signed into an application, allows other
processes (like the debugger) to attach to your app. Distribution
profiles require that this value be turned off, while development
profiles require this value to be turned on (otherwise Xcode would
never be able to launch and attach to your app).
So there is nothing I can do to debug my programs with that software. Is that correct? :(
You can debug but you have to set the "Code Signing Inject Base Entitlements" to "Yes" for debugging
And then you have to add a provisioning profile. Go to developer.apple.com then select "Certificates, IDs & Profiles" to create a provisioning profile for the bundle ID you are testing.
This solved it for me on terminal
sudo DevToolsSecurity -enable
When you don't have access to the original source code or don't want to rebuild it, such as when developing plug-ins for another app (a DAW in your case), you can easily change the entitlements of the application as follows to enable debugging:
Read the current entitlements as follows (replace daw.app with the actual app name):
codesign --display --xml --entitlements daw.entitlements daw.app
Note: Run this in the Terminal app. It will create a file named daw.entitlements in the current folder. Run the command only once or delete any previously created daw.entitlements; otherwise the command keeps appending to the same file.
Open daw.entitlements in any text editor and insert the following text just before </dict></plist> at the end of the file:
<key>com.apple.security.get-task-allow</key><true/>
Note: If there’s already an entry with the same name, change its value from false to true instead of adding a new one.
Apply the new entitlements as follows (replace daw.app with the actual app name):
codesign -s - --deep --force --options=runtime --entitlements daw.entitlements daw.app
This should do it. In the unlikely chance that you already have a file named daw.entitlements in the same folder, use a different file name in all steps.
I tried all of these and had no luck until I figured out that I also had to disable SIP (system integrity protection) to attach to the audio server plugin I am working on.
Hopefully this helps someone to not lose a whole day on it as I did.
When I done some changes in main.Dart of simple HelloWorld program ,new changes are not reflecting in my mobile.Old UI changes are reflecting.I have restarted my visual studio editor, uninstall app.Still old UI changes are reflecting.
Visual studio provide terminal in bottom,
type Flutter run
then you will see ..
Launching lib/main.dart on SM G615F in debug mode...
Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 16.8s
✓ Built build/app/outputs/apk/debug/app-debug.apk.
Syncing files to device SM G615F...
D/GraphicBuffer(24157): register, handle(0xddbb3680) (w:1080 h:1920 s:1088 f:0x1 u:b00)
Syncing files to device SM G615F... 5,356ms (!)
Flutter run key commands.
r Hot reload. 🔥🔥🔥
R Hot restart.
h Repeat this help message.
d Detach (terminate "flutter run" but leave application running).
q Quit (terminate the application on the device).
Type r
Initializing hot reload...
Reloaded 0 of 483 libraries in 523ms.
D/GraphicBuffer(24157): register, handle(0xddbb3920) (w:1080 h:1920 s:1088 f:0x1 u:b00)
After that Type R .
Performing hot restart...
Restarted application in 2,067ms.
Changes are reflecting.Issue get resolved
if your code don't reflect on your UI or real device , you can move to master channel of flutter then run flutter clean
you can move to master channel by run in terminal :
flutter channel master
I started an empty safari app extension in Xcode, I didn't change any code from the boilerplate.
When I run this new and empty extension and choose safari to open it, something went wrong:
Could not attach to pid : “13069”
Domain: IDEDebugSessionErrorDomain
Code: 3
Failure Reason: Error 1
--
Error 1
Domain: IDEDebugSessionErrorDomain
Code: 3
--
I am totally new to xcode and safari extension, hope someone could help.
Just clean the build folder with Cmd + Shift + K and rerun the extension project, then it works.
But still, don't know what caused this problem.
when I run /Applications/Xcode.app/Contents/MacOS/Xcode from commandline it shows
2015-11-26 22:04:26.876 Xcode[1176:56924] ### Failed to load Addressbook class CNContactNameFormatter
2015-11-26 22:04:27.263 Xcode[1176:56948] DeveloperPortal: Using pre-existing current store at URL (file:///Users/Chaitanya/Library/Developer/Xcode/DeveloperPortal%207.1.1.db).
and remains in the same state and after some time xcode icon disappears
Don't launch Xcode that way. Use open /Applications/Xcode.app.
Delete /Users/xubo/Library/Application\ Support/Developer/Shared/Xcode/Plug-ins/Alcatraz.xcplugin. Then restart your computer. Next, open your project and select load Bundle.
I'm getting the following during the bundle resources copying phase in xcodebuild (XCode 7.1):
2015-11-03 22:16:28.218 xcodebuild[28202:300463] DVTAssertions:
Warning in
/Library/Caches/com.apple.xbs/Sources/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-9061/Xcode3Core/LegacyProjects/Frameworks/DevToolsCore/DevToolsCore/BuildSystem/Runtime/PBXTargetBuildContext.mm:739
Details: unexpected successful exit code from cancelled command
<C0505:'CpResource Foo.json':P10> Object: <PBXTargetBuildContext:
0x7faec015a440> Method:
-createCommandInvocationRecordFromInvocation: Thread: <NSThread: 0x7faebc8cc070>{number = 10, name = (null)} Please file a bug at
http://bugreport.apple.com with this warning message and any useful
information you can provide.
I have ~170 items I'm copying, but for some reason a few of them give me this error.
EDIT - I just ran the command again and now it works, so it doesn't seem deterministic.
The issue was a duplicate folder in the Copy Bundle Resources section. It used to be two different files, but they were moved so XCode decided to change them both to the folder they got moved into. Go figure.
Had this issue a couple of months ago. Today that error made it's comback.
I have it only if I try to emulate from ionic (--livereload) on a iOS-Device. Seem like if you have Xcode running it occurs. Close Xcode. That fixes it.