Cannot evaluate variables in xCode 16.2 debugger

When I try to look at any variable in the debugger, I get a bunch of errors complaining about inability to find a file in a location that should not exist on my machine... I just upgraded form xCode 15.2, which worked fine, but now I basically cannot debug. Who is this liangchenying? It's almost like the new version was shipped with some developer's paths hard-coded in the configuration.

(lldb) po [tableNumberTxt.text integerValue] warning: (arm64) /Users/stevedavison/lineskip_dev/POS/SNBC/POSSDKForIOSLIB.a(PortIO.o) 0x00000000000004a7: unable to locate module needed for external types: /Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch error: '/Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch' does not exist Debugging will be degraded due to missing types. Rebuilding the project will regenerate the needed module files.warning: (arm64) /Users/stevedavison/lineskip_dev/POS/SNBC/POSSDKForIOSLIB.a(WIFIPort.o) 0x000000000000171c: unable to locate module needed for external types: /Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch error: '/Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch' does not exist Debugging will be degraded due to missing types. Rebuilding the project will regenerate the needed module files.warning: (arm64) /Users/stevedavison/lineskip_dev/POS/SNBC/POSSDKForIOSLIB.a(SimpleLogger.o) 0x00000000000009b9: unable to locate module needed for external types: /Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch error: '/Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch' does not exist Debugging will be degraded due to missing types. Rebuilding the project will regenerate the needed module files.warning: (arm64) /Users/stevedavison/lineskip_dev/POS/SNBC/POSSDKForIOSLIB.a(POSCommand.o) 0x00000000000035bd: unable to locate module needed for external types: /Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch error: '/Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch' does not exist Debugging will be degraded due to missing types. Rebuilding the project will regenerate the needed module files.warning: (arm64) /Users/stevedavison/lineskip_dev/POS/SNBC/POSSDKForIOSLIB.a(WIFIPortToFile.o) 0x00000000000004da: unable to locate module needed for external types: /Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch error: '/Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch' does not exist Debugging will be degraded due to missing types. Rebuilding the project will regenerate the needed module files.warning: (arm64) /Users/stevedavison/lineskip_dev/POS/SNBC/POSSDKForIOSLIB.a(POSSDK.o) 0x0000000000002432: unable to locate module needed for external types: /Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch error: '/Users/liangchenying/Library/Developer/Xcode/DerivedData/POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/Build/Intermediates/PrecompiledHeaders/POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/POSSDKForIOSLIB-Prefix.pch.pch' does not exist Debugging will be degraded due to missing types. Rebuilding the project will regenerate the needed module files.7

Answered by DTS Engineer in 838589022
Who is this liangchenying?

Probably a developer who worked one of the third-party libraries you’re using.

Consider one of the paths in your transcript:

/Users/
  liangchenying/
    Library/
      Developer/
        Xcode/
          DerivedData/
            POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/
              Build/
                Intermediates/
                  PrecompiledHeaders/
                    POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/
                      POSSDKForIOSLIB-Prefix.pch.pch

Note how this is related to POSSDKForIOSLIB. That’s not an Apple thing, and hence my conclusion.

I have a bunch of background info about this stuff in An Apple Library Primer. It links to Understanding Mach-O Symbols, which has a section that discusses debug symbols. I suspect that it’s those debug symbols that are referencing these weird paths.

LLDB has a mechanism to remap paths like this. There’s info about that, and much more, in WWDC 2022 Session 110370 Debug Swift debugging with LLDB.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Who is this liangchenying?

Probably a developer who worked one of the third-party libraries you’re using.

Consider one of the paths in your transcript:

/Users/
  liangchenying/
    Library/
      Developer/
        Xcode/
          DerivedData/
            POSSDKForIOSLIB-bmkvfovoxsbzudehquaovgmnnooe/
              Build/
                Intermediates/
                  PrecompiledHeaders/
                    POSSDKForIOSLIB-Prefix-cfcbmooemqunxmehfbebereyakbw/
                      POSSDKForIOSLIB-Prefix.pch.pch

Note how this is related to POSSDKForIOSLIB. That’s not an Apple thing, and hence my conclusion.

I have a bunch of background info about this stuff in An Apple Library Primer. It links to Understanding Mach-O Symbols, which has a section that discusses debug symbols. I suspect that it’s those debug symbols that are referencing these weird paths.

LLDB has a mechanism to remap paths like this. There’s info about that, and much more, in WWDC 2022 Session 110370 Debug Swift debugging with LLDB.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Thank you so much for your reply Quinn. I see where you're coming from, and I'll spend a little time reading up on the links you provided.

The problem I'm having is that Xcode 15.2 gave me no issues with this, and now all I'm trying to do is evaluate local properties and UIKit types, and nothing works anymore. So something that did not cause a problem before is making it nearly impossible to debug.

I would understand if this occurred while trying to inspect a type provided by this third-party library, but I'm just trying to read the value of an input control.

OK, looking closer I see that the po command I issued did apparently produce an output... The very last line ends with:

  ... Rebuilding the project will regenerate the needed module files.7 

and I had typed a "7" into the input field.

So apparently every expression I evaluate is going to prepend a couple pages of irrelevant warnings to the output. It looks like Xcode 16 is turning on some LLDB warning output that was previously suppressed. I'm searching for a way to reduce the warning level, but haven't found it yet.

Accepted Answer

I was able to find a solution with some help from ChatGPT. Since I don't care about debugging anything related to the problem library, I decided to strip out the debug info from the offending file using the command:

strip -S -x POSSDKForIOSLIB.a
Cannot evaluate variables in xCode 16.2 debugger
 
 
Q