Socket hang up issue when doing automation tests on iOS tablet

Hi all

I’m currently facing an issue. The so called socket hang up error. This always occurs after I click on a specific image which is actually a button. The issue only occurs on iOS tablets, android devices and iOS phones don’t have this problem. This is a part of the logs:

debug] [JSONWP Proxy] Got response with status 200: {“sessionId”:“AB4F6912-F268-44E7-BC48-3721D45BD948”,“value”:{“label”:“KENNETH”,“type”:“XCUIElementTypeStaticText”,“ELEMENT”:“29B29AA7-9E5A-4779-BD80-CE0066E7224D”},“status”:0}
[debug] [MJSONWP] Responding to client with driver.findElement() result: {“label”:“KENNETH”,“type”:“XCUIElementTypeStaticText”,“ELEMENT”:“29B29AA7-9E5A-4779-BD80-CE0066E7224D”}
[debug] [WebDriverAgent] Device: Jan 19 11:22:17 MOB023 XCTRunner[3371] : Received memory warning.
[debug] [iProxy] recv failed: Resource temporarily unavailable
[debug] [iProxy] recv failed: Operation not permitted
[debug] [XCUITest] Log file for xcodebuild test: /Users/testing/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/57FC063F-1ECB-495C-A6C9-59D82D7B94F4/Session-WebDriverAgentRunner-2017-01-19_112227-P2aBs4.log
[debug] [WebDriverAgent] Device: Jan 19 11:22:53 MOB023 XCTRunner[3425] : Running tests…
[debug] [WebDriverAgent] Device: Jan 19 11:22:56 MOB023 XCTRunner[3425] : Continuing to run tests in the background with task ID 1
[BaseDriver] Shutting down because we waited 60 seconds for a command
[debug] [JSONWP Proxy] Proxying [DELETE /session/fd75534d-b2fd-4fbf-8687-8ed2d8c1e076] to [DELETE http://localhost:8100/session/AB4F6912-F268-44E7-BC48-3721D45BD948] with no body
[Appium] Closing session, cause was ‘New Command Timeout of 60 seconds expired. Try customizing the timeout using the ‘newCommandTimeout’ desired capability’
[Appium] Removing session fd75534d-b2fd-4fbf-8687-8ed2d8c1e076 from our master session list
[debug] [iProxy] Error connecting to device!
Unhandled rejection ProxyRequestError: Could not proxy command to remote server. Original error: Error: socket hang up
at JWProxy.proxy$ (…/…/…/lib/jsonwp-proxy/proxy.js:126:13)
at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
[XCUITest] xcodebuild exited with code ‘65’ and signal ‘null’

Can somebody help me with this because this is delaying all test activities.
Thanks in advance