Unable to get screenshot in Appium after upgrading Appium to 1.22.3v

Hello Everyone,

I unable to find elements using Appium inspector as I am getting blanc screen in appium inspector.
I have gone through ur blogs I have cleared the Xcode cache and I remove WDA from physical device manually and tried with new but still I am unable to get the screenshot in Appium inspector. Please see the screen shot for same.

“platformName”: “iOS”,
“appium:platformVersion”: “15.3.1”,
“appium:deviceName”: “iPhone X”,
appium version is:1.22.3
Mac OS is:macOS monetaory 12.4

What version of Xcode?

Hi Wreed, I am using 13.4 xcode. I getting source element but not getting the screen shot in appium.

Could you post the server log as a git gist?

https://docs.github.com/en/get-started/writing-on-github/editing-and-sharing-content-with-gists/creating-gists

please see the below server logs:
[HTTP] Waiting until the server is closed

[HTTP] Received server close event

[Appium] Welcome to Appium v1.22.3

[Appium] Non-default server args:

[Appium] relaxedSecurityEnabled: true

[Appium] allowInsecure: {

[Appium] }

[Appium] denyInsecure: {

[Appium] }

[Appium] Appium REST http interface listener started on 0.0.0.0:4723

[HTTP] --> GET /wd/hub/sessions

[HTTP] {}

[GENERIC] Calling AppiumDriver.getSessions() with args: []

[GENERIC] Responding to client with driver.getSessions() result: []

[HTTP] <-- GET /wd/hub/sessions 304 1 ms - -

[HTTP]

[[email protected]:8100] The connection has been closed

[HTTP] --> POST /wd/hub/session

[HTTP] {“capabilities”:{“alwaysMatch”:{“platformName”:“iOS”,“appium:platformVersion”:“15.3.1”,“appium:deviceName”:“iPhone X”,“appium:udid”:“fee0f40854feb480d5105855de60cc9f6813416e”,“appium:bundleId”:“com.example.iphone.qa”,“appium:includeSafariInWebviews”:true,“appium:newCommandTimeout”:3600,“appium:connectHardwareKeyboard”:true},“firstMatch”:[{}]},“desiredCapabilities”:{“platformName”:“iOS”,“appium:platformVersion”:“15.3.1”,“appium:deviceName”:“iPhone X”,“appium:udid”:“fee0f40854feb480d5105855de60cc9f6813416c”,“appium:bundleId”:“com.example.iphone.qa”,“appium:includeSafariInWebviews”:true,“appium:newCommandTimeout”:3600,“appium:connectHardwareKeyboard”:true}}

[W3C] Calling AppiumDriver.createSession() with args: [{“platformName”:“iOS”,“appium:platformVersion”:“15.3.1”,“appium:deviceName”:“iPhone X”,“appium:udid”:“fee0f40854feb480d5105855de60cc9f6813416e”,“appium:bundleId”:“com.exampleexample.iphone.qa”,“appium:includeSafariInWebviews”:true,“appium:newCommandTimeout”:3600,“appium:connectHardwareKeyboard”:true},null,{“alwaysMatch”:{“platformName”:“iOS”,“appium:platformVersion”:“15.3.1”,“appium:deviceName”:“iPhone X”,“appium:udid”:“fee0f40854feb480d5105855de60cc9f6813416c”,“appium:bundleId”:“com.example.iphone.qa”,“appium:includeSafariInWebviews”:true,“appium:newCommandTimeout”:3600,“appium:connectHardwareKeyboard”:true},“firstMatch”:[{}]}]

[BaseDriver] Event ‘newSessionRequested’ logged at 1659856988281 (12:53:08 GMT+0530 (India Standard Time))

[Appium] DeprecationWarning: ‘automationName’ capability was not provided. Future versions of Appium will require ‘automationName’ capability to be set for iOS sessions.

[Appium] Requested iOS support with version >= 10, using ‘XCUITest’ driver instead of UIAutomation-based driver, since the latter is unsupported on iOS 10 and up.

[Appium] Appium v1.22.3 creating new XCUITestDriver (v3.59.0) session

[Appium] Applying relaxed security to ‘XCUITestDriver’ as per server command line argument. All insecure features will be enabled unless explicitly disabled by --deny-insecure

[BaseDriver] W3C capabilities and MJSONWP desired capabilities were provided

[BaseDriver] Creating session with W3C capabilities: {

[BaseDriver] “alwaysMatch”: {

[BaseDriver] “platformName”: “iOS”,

[BaseDriver] “appium:platformVersion”: “15.3.1”,

[BaseDriver] “appium:deviceName”: “iPhone X”,

[BaseDriver] “appium:udid”: “fee0f40854feb480d5105855de60cc9f6813416c”,

[BaseDriver] “appium:bundleId”: “com.example.iphone.qa”,

[BaseDriver] “appium:includeSafariInWebviews”: true,

[BaseDriver] “appium:newCommandTimeout”: 3600,

[BaseDriver] “appium:connectHardwareKeyboard”: true

[BaseDriver] },

[BaseDriver] “firstMatch”: [

[BaseDriver] {}

[BaseDriver] ]

[BaseDriver] }

[BaseDriver] Session created with session id: b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9

[XCUITest] Current user: ‘Planit’

[XCUITest] Available devices: fee0f40854feb480d5105855de60cc9f6813416c

[XCUITest] Creating iDevice object with udid ‘fee0f40854feb480d5105855de60cc9f6813416c’

[XCUITest] Determining device to run tests on: udid: ‘fee0f40854feb480d5105855de60cc9f6813416c’, real device: true

[XCUITest] Normalized platformVersion capability value ‘15.3.1’ to ‘15.3’

[BaseDriver] Event ‘xcodeDetailsRetrieved’ logged at 1659856988307 (12:53:08 GMT+0530 (India Standard Time))

[BaseDriver] Event ‘appConfigured’ logged at 1659856988307 (12:53:08 GMT+0530 (India Standard Time))

[BaseDriver] Event ‘resetStarted’ logged at 1659856988308 (12:53:08 GMT+0530 (India Standard Time))

[XCUITest] Reset: running ios real device reset flow

[BaseDriver] Event ‘resetComplete’ logged at 1659856988308 (12:53:08 GMT+0530 (India Standard Time))

[WebDriverAgent] Using WDA path: ‘/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-webdriveragent’

[WebDriverAgent] Using WDA agent: ‘/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-webdriveragent/WebDriverAgent.xcodeproj’

[XCUITest] Crash reports root ‘/Users/Planit/Library/Logs/CrashReporter/MobileDevice/iPhone’ does not exist. Got nothing to gather.

[BaseDriver] Event ‘logCaptureStarted’ logged at 1659856988549 (12:53:08 GMT+0530 (India Standard Time))

[XCUITest] Setting up real device

[WebDriverAgent] No obsolete cached processes from previous WDA sessions listening on port 8100 have been found

[DevCon Factory] Requesting connection for device fee0f40854feb480d5105855de60cc9f6813416c on local port 8100, device port 8100

[DevCon Factory] Cached connections count: 0

[DevCon Factory] Successfully requested the connection for fee0f40854feb480d5105855de60cc9f6813416c:8100

[XCUITest] Starting WebDriverAgent initialization with the synchronization key ‘XCUITestDriver’

[WD Proxy] Matched ‘/status’ to command name ‘getStatus’

[WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8100/status] with no body

[WD Proxy] Got response with status 200: {“value”:{“message”:“WebDriverAgent is ready to accept commands”,“state”:“success”,“os”:{“testmanagerdVersion”:28,“name”:“iOS”,“sdkVersion”:“15.4”,“version”:“15.3.1”},“ios”:{“ip”:“169.254.247.193”},“ready”:true,“build”:{“time”:“Aug 4 2022 21:57:29”,“productBundleIdentifier”:“com.facebook.WebDriverAgentRunner”}},“sessionId”:null}

[WebDriverAgent] Upgrade timestamp of the currently bundled WDA: 1652561248000

[WebDriverAgent] Upgrade timestamp of the WDA on the device: undefined

[WebDriverAgent] Will reuse previously cached WDA instance at ‘http://127.0.0.1:8100/’ with ‘com.facebook.WebDriverAgentRunner’. Set the wdaLocalPort capability to a value different from 8100 if this is an undesired behavior.

[XCUITest] Trying to start WebDriverAgent 1 times with 10000ms interval

[XCUITest] These values can be customized by changing wdaStartupRetries/wdaStartupRetryInterval capabilities

[BaseDriver] Event ‘wdaStartAttempted’ logged at 1659856988780 (12:53:08 GMT+0530 (India Standard Time))

[WebDriverAgent] Using provided WebdriverAgent at ‘http://127.0.0.1:8100/

[WD Proxy] Matched ‘/status’ to command name ‘getStatus’

[WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8100/status] with no body

[WD Proxy] Got response with status 200: {“value”:{“message”:“WebDriverAgent is ready to accept commands”,“state”:“success”,“os”:{“testmanagerdVersion”:28,“name”:“iOS”,“sdkVersion”:“15.4”,“version”:“15.3.1”},“ios”:{“ip”:“169.254.247.193”},“ready”:true,“build”:{“time”:“Aug 4 2022 21:57:29”,“productBundleIdentifier”:“com.facebook.WebDriverAgentRunner”}},“sessionId”:null}

[BaseDriver] Event ‘wdaSessionAttempted’ logged at 1659856988793 (12:53:08 GMT+0530 (India Standard Time))

[XCUITest] Sending createSession command to WDA

[WD Proxy] Matched ‘/session’ to command name ‘createSession’

[WD Proxy] Proxying [POST /session] to [POST http://127.0.0.1:8100/session] with body: {“capabilities”:{“firstMatch”:[{“bundleId”:“com.example.iphone.qa”,“arguments”:[],“environment”:{},“eventloopIdleDelaySec”:0,“shouldWaitForQuiescence”:true,“shouldUseTestManagerForVisibilityDetection”:false,“maxTypingFrequency”:60,“shouldUseSingletonTestManager”:true,“shouldTerminateApp”:true,“forceAppLaunch”:true,“useNativeCachingStrategy”:true,“forceSimulatorSoftwareKeyboardPresence”:false}],“alwaysMatch”:{}}}

[WebDriverAgent] Parsed BUILD_DIR configuration value: ‘/Users/Planit/Library/Developer/Xcode/DerivedData/WebDriverAgent-aghlrsejdreqngftgvcqwnjgrbou/Build/Products’

[WebDriverAgent] Got derived data root: ‘/Users/Planit/Library/Developer/Xcode/DerivedData/WebDriverAgent-aghlrsejdreqngftgvcqwnjgrbou’

[WD Proxy] Got response with status 200: {“value”:{“sessionId”:“BF1D756B-5216-4250-A89A-5361D646D2F2”,“capabilities”:{“device”:“iphone”,“browserName”:“example QA”,“sdkVersion”:“15.3.1”,“CFBundleIdentifier”:“com.example.iphone.qa”}},“sessionId”:“BF1D756B-5216-4250-A89A-5361D646D2F2”}

[WD Proxy] Determined the downstream protocol as ‘W3C’

[BaseDriver] Event ‘wdaSessionStarted’ logged at 1659856990680 (12:53:10 GMT+0530 (India Standard Time))

[BaseDriver] Event ‘wdaStarted’ logged at 1659856990680 (12:53:10 GMT+0530 (India Standard Time))

[XCUITest] Skipping setting of the initial display orientation. Set the “orientation” capability to either “LANDSCAPE” or “PORTRAIT”, if this is an undesired behavior.

[BaseDriver] Event ‘orientationSet’ logged at 1659856990680 (12:53:10 GMT+0530 (India Standard Time))

[BaseDriver] The value of ‘elementResponseAttributes’ setting did not change. Skipping the update for it

[BaseDriver] The value of ‘shouldUseCompactResponses’ setting did not change. Skipping the update for it

[Appium] New XCUITestDriver session created successfully, session b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9 added to master session list

[BaseDriver] Event ‘newSessionStarted’ logged at 1659856990681 (12:53:10 GMT+0530 (India Standard Time))

[W3C (b9f21e61)] Cached the protocol value ‘W3C’ for the new session b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9

[W3C (b9f21e61)] Responding to client with driver.createSession() result: {“capabilities”:{“webStorageEnabled”:false,“locationContextEnabled”:false,“browserName”:"",“platform”:“MAC”,“javascriptEnabled”:true,“databaseEnabled”:false,“takesScreenshot”:true,“networkConnectionEnabled”:false,“platformName”:“iOS”,“platformVersion”:“15.3.1”,“deviceName”:“iPhone X”,“udid”:“fee0f40854feb480d5105855de60cc9f6813416c”,“bundleId”:“com.example.iphone.qa”,“includeSafariInWebviews”:true,“newCommandTimeout”:3600,“connectHardwareKeyboard”:true}}

[HTTP] <-- POST /wd/hub/session 200 2402 ms - 522

[HTTP]

[HTTP] --> GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/screenshot

[HTTP] {}

[W3C (b9f21e61)] Calling AppiumDriver.getScreenshot() with args: [“b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9”]

[XCUITest] Executing command ‘getScreenshot’

[XCUITest] Taking screenshot with WDA

[WD Proxy] Matched ‘/screenshot’ to command name ‘getScreenshot’

[WD Proxy] Proxying [GET /screenshot] to [GET http://127.0.0.1:8100/session/BF1D756B-5216-4250-A89A-5361D646D2F2/screenshot] with no body

[WD Proxy] Got response with status 500: {“value”:{“error”:“unable to capture screen”,“message”:“A screen capture was made impossible”,“traceback”:""},“sessionId”:“BF1D756B-5216-4250-A89A-5361D646D2F2”}

[W3C] Matched W3C error code ‘unable to capture screen’ to UnableToCaptureScreen

[XCUITest] Error getting screenshot: A screen capture was made impossible

[XCUITest] Taking screenshot with WDA

[WD Proxy] Matched ‘/screenshot’ to command name ‘getScreenshot’

[WD Proxy] Proxying [GET /screenshot] to [GET http://127.0.0.1:8100/session/BF1D756B-5216-4250-A89A-5361D646D2F2/screenshot] with no body

[WD Proxy] Got response with status 500: {“value”:{“error”:“unable to capture screen”,“message”:“A screen capture was made impossible”,“traceback”:""},“sessionId”:“BF1D756B-5216-4250-A89A-5361D646D2F2”}

[W3C] Matched W3C error code ‘unable to capture screen’ to UnableToCaptureScreen

[XCUITest] Taking screenshot with WDA

[WD Proxy] Matched ‘/screenshot’ to command name ‘getScreenshot’

[WD Proxy] Proxying [GET /screenshot] to [GET http://127.0.0.1:8100/session/BF1D756B-5216-4250-A89A-5361D646D2F2/screenshot] with no body

[WD Proxy] Got response with status 500: {“value”:{“error”:“unable to capture screen”,“message”:“A screen capture was made impossible”,“traceback”:""},“sessionId”:“BF1D756B-5216-4250-A89A-5361D646D2F2”}

[W3C] Matched W3C error code ‘unable to capture screen’ to UnableToCaptureScreen

[W3C (b9f21e61)] Encountered internal error running command: UnableToCaptureScreen: A screen capture was made impossible

[W3C (b9f21e61)] at errorFromW3CJsonCode (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-base-driver/lib/protocol/errors.js:780:25)

[W3C (b9f21e61)] at ProxyRequestError.getActualError (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-base-driver/lib/protocol/errors.js:663:14)

[W3C (b9f21e61)] at JWProxy.command (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-base-driver/lib/jsonwp-proxy/proxy.js:272:19)

[W3C (b9f21e61)] at runMicrotasks ()

[W3C (b9f21e61)] at processTicksAndRejections (internal/process/task_queues.js:97:5)

[W3C (b9f21e61)] at XCUITestDriver.proxyCommand (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-xcuitest-driver/lib/commands/proxy-helper.js:96:12)

[W3C (b9f21e61)] at getScreenshotFromWDA (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-xcuitest-driver/lib/commands/screenshots.js:11:18)

[W3C (b9f21e61)] at wrapped (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/asyncbox/lib/asyncbox.js:60:13)

[W3C (b9f21e61)] at retry (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/asyncbox/lib/asyncbox.js:43:13)

[W3C (b9f21e61)] at retryInterval (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/asyncbox/lib/asyncbox.js:70:10)

[W3C (b9f21e61)] at XCUITestDriver.getScreenshot (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-xcuitest-driver/lib/commands/screenshots.js:42:10)

[HTTP] <-- GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/screenshot 500 1036 ms - 1788

[HTTP]

[HTTP] --> GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/window/rect

[HTTP] {}

[W3C (b9f21e61)] Calling AppiumDriver.getWindowRect() with args: [“b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9”]

[XCUITest] Executing command ‘getWindowRect’

[WD Proxy] Proxying [GET /window/size] to [GET http://127.0.0.1:8100/session/BF1D756B-5216-4250-A89A-5361D646D2F2/window/size] with no body

[WD Proxy] Got response with status 200: {“value”:{“width”:375,“height”:812},“sessionId”:“BF1D756B-5216-4250-A89A-5361D646D2F2”}

[W3C (b9f21e61)] Responding to client with driver.getWindowRect() result: {“width”:375,“height”:812,“x”:0,“y”:0}

[HTTP] <-- GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/window/rect 200 100 ms - 48

[HTTP]

[HTTP] --> GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/source

[HTTP] {}

[W3C (b9f21e61)] Calling AppiumDriver.getPageSource() with args: [“b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9”]

[XCUITest] Executing command ‘getPageSource’

[WD Proxy] Matched ‘/source?scope=AppiumAUT’ to command name ‘getPageSource’

[WD Proxy] Proxying [GET /source?scope=AppiumAUT] to [GET http://127.0.0.1:8100/session/BF1D756B-5216-4250-A89A-5361D646D2F2/source?scope=AppiumAUT] with no body

[WD Proxy] Got response with status 200: {“value”:"\n\n \n \n \n \n

[W3C (b9f21e61)] Responding to client with driver.getPageSource() result: "\n \n \n \n \n

[HTTP] <-- GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/source 200 824 ms - 13700

[HTTP]

[HTTP] --> GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts

[HTTP] {}

[W3C (b9f21e61)] Calling AppiumDriver.getTimeouts() with args: [“b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9”]

[XCUITest] Executing command ‘getTimeouts’

[W3C (b9f21e61)] Responding to client with driver.getTimeouts() result: {“command”:3600000,“implicit”:0}

[HTTP] <-- GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts 200 1 ms - 42

[HTTP]

[HTTP] --> GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts

[HTTP] {}

[W3C (b9f21e61)] Calling AppiumDriver.getTimeouts() with args: [“b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9”]

[XCUITest] Executing command ‘getTimeouts’

[W3C (b9f21e61)] Responding to client with driver.getTimeouts() result: {“command”:3600000,“implicit”:0}

[HTTP] <-- GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts 304 1 ms - -

[HTTP]

[HTTP] --> GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts

[HTTP] {}

[W3C (b9f21e61)] Calling AppiumDriver.getTimeouts() with args: [“b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9”]

[XCUITest] Executing command ‘getTimeouts’

[W3C (b9f21e61)] Responding to client with driver.getTimeouts() result: {“command”:3600000,“implicit”:0}

[HTTP] <-- GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts 304 1 ms - -

[HTTP]

[HTTP] --> GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts

[HTTP] {}

[W3C (b9f21e61)] Calling AppiumDriver.getTimeouts() with args: [“b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9”]

[XCUITest] Executing command ‘getTimeouts’

[W3C (b9f21e61)] Responding to client with driver.getTimeouts() result: {“command”:3600000,“implicit”:0}

[HTTP] <-- GET /wd/hub/session/b9f21e61-8f2a-4c0d-ba21-2226a4bfb8e9/timeouts 304 1 ms - -

[HTTP]

Could you please help me to get the screenshot in Appium inspector. I am not getting when I am using physical device but when I am using cloud based device.

Hi @onlineboss, Did you got any solution for above issue screenshot not visible in appium.

Ok, so when you use it on a physical device it works fine, but on a cloud based device it doesn’t work? That’s a big detail to leave out. What provider?

Meanwhile, here is a good tutorial on using Appium Desktop:

https://www.kobiton.com/book/chapter-5-the-appium-inspector-2

Hi Wreed, No when I am using cloud device its working fine I am getting snap shot. But when I am using physical device I am not getting screen shot. I am getting issue when I am using physical device.

Ok, probably lost in translation. One thing I notice in the tutorial I referred you to is that you are not using this capability:

"automationName": "XCUITest"

Not sure if you noticed that. Can you try?

Hi @wreed, I add the automation Name capability as well but still I am not getting the screen shot in appium inspector.

Can you try simple setup like the one in the tutorial? So for capabilities:

   {     
      "platformName": "iOS", 
      "platformVersion":   "15.3",
      "app":   "/path/to/.ipa/file",
      "deviceName": "iPhone X",
      "udid":   "fee0f40854feb480d5105855de60cc9f6813416c",
      "automationName":   "XCUITest"
   } 

Does a simple setup like that make any difference?

Hi Wreed,
I have given only simple capabilities but still I am not getting the snapshot.
{
“platformName”: “iOS”,
“appium:platformVersion”: “15.6”,
“appium:deviceName”: “iPhone X”,
“appium:udid”: “fee0f40854feb480d5105855de60cc9f6813416d”,
“appium:bundleId”: “com.example.iphone.qa”,
“appium:automationName”: “XCUITest”
}

Can you try adding app capability with absolute path to ,ipa?

I almost missed that you changed the iOS version on me. Xcode 13.4 will not work with iOS 15.6. Please see this wiki to match iOS version to Xcode version:

https://en.wikipedia.org/wiki/Xcode#14.x_series

Hi @Wreed, Got your point but previously its 15.3.1 only 2days bcak iphone version got . updated. Do you want me to upgrade my xcode to which version now it is 13.4.1? but after that only beta versions of xcode are available

I honestly don’t know if updating will fix this. The matrix shows 15.6 is supposedly only compatible with Xcode 14 beta. I would doubt Appium 1.22 series would support the beta Xcode. Maybe Appium 2.0, but I don’t think there is a GUI for that.

Living on the bleeding edge can be really painful. My best advice is to set the iPhone not to update and try this with an older iOS.