When i run a sample test case in mobile automation i getting this error. please help me with it

=============== ROOT CAUSE =====================

Caused by: org.openqa.selenium.SessionNotCreatedException: Unable to create a new remote session. Please check the server log for more details. Original error: An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: 'Command 'C:\\Users\\admin\\.katalon\\tools\\android_sdk\\platform-tools\\adb.exe -P 5037 -s cd2964fe shell 'settings delete global hidden_api_policy_pre_p_apps;settings delete global hidden_api_policy_p_apps;settings delete global hidden_api_policy'' exited with code 255'; Command output:

For trouble shooting, please visit: https://docs.katalon.com/katalon-studio/docs/troubleshooting.html

================================================

11-17-2023 03:16:58 pm Test Cases/New Test Case

Elapsed time: 6.550s

Test Cases/New Test Case FAILED.

Reason:

com.kms.katalon.core.exception.StepFailedException: Unable to open browser with url: ''

at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed(WebUIKeywordMain.groovy:64)

at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:26)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.openBrowser(OpenBrowserKeyword.groovy:81)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.execute(OpenBrowserKeyword.groovy:67)

at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:74)

at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.openBrowser(WebUiBuiltInKeywords.groovy:64)

at New Test Case.run(New Test Case:20)

at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)

at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)

at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:448)

at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:439)

at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:418)

at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:410)

at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:285)

at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:144)

at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:135)

at TempTestCase1700214411553.run(TempTestCase1700214411553.groovy:25)

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)

at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

Caused by: org.openqa.selenium.SessionNotCreatedException: Unable to create a new remote session. Please check the server log for more details. Original error: An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: 'Command 'C:\\Users\\admin\\.katalon\\tools\\android_sdk\\platform-tools\\adb.exe -P 5037 -s cd2964fe shell 'settings delete global hidden_api_policy_pre_p_apps;settings delete global hidden_api_policy_p_apps;settings delete global hidden_api_policy'' exited with code 255'; Command output:

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:25:53'

System info: host: 'DESKTOP-GCU4975', ip: '192.168.166.129', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '17.0.7'

Driver info: driver.version: SwipeableAndroidDriver

remote stacktrace: UnknownError: An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: 'Command 'C:\\Users\\admin\\.katalon\\tools\\android_sdk\\platform-tools\\adb.exe -P 5037 -s cd2964fe shell 'settings delete global hidden_api_policy_pre_p_apps;settings delete global hidden_api_policy_p_apps;settings delete global hidden_api_policy'' exited with code 255'; Command output:

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

at getResponseForW3CError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:804:9)

at asyncHandler (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\protocol.js:380:37)

Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:25:53'

System info: host: 'DESKTOP-GCU4975', ip: '192.168.166.129', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '17.0.7'

Driver info: driver.version: SwipeableAndroidDriver

at io.appium.java_client.remote.AppiumCommandExecutor$1.createSession(AppiumCommandExecutor.java:208)

at io.appium.java_client.remote.AppiumCommandExecutor.createSession(AppiumCommandExecutor.java:217)

at io.appium.java_client.remote.AppiumCommandExecutor.execute(AppiumCommandExecutor.java:239)

at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:552)

at io.appium.java_client.DefaultGenericMobileDriver.execute(DefaultGenericMobileDriver.java:42)

at io.appium.java_client.AppiumDriver.execute(AppiumDriver.java:1)

at io.appium.java_client.android.AndroidDriver.execute(AndroidDriver.java:1)

at com.kms.katalon.core.appium.driver.SwipeableAndroidDriver.execute(SwipeableAndroidDriver.java:1)

at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:213)

at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:131)

at io.appium.java_client.DefaultGenericMobileDriver.<init>(DefaultGenericMobileDriver.java:38)

at io.appium.java_client.AppiumDriver.<init>(AppiumDriver.java:84)

at io.appium.java_client.android.AndroidDriver.<init>(AndroidDriver.java:85)

at com.kms.katalon.core.appium.driver.SwipeableAndroidDriver.<init>(SwipeableAndroidDriver.java:24)

at com.kms.katalon.core.appium.driver.AppiumDriverManager.createMobileDriver(AppiumDriverManager.java:510)

at com.kms.katalon.core.appium.driver.AppiumDriverManager.createMobileDriver(AppiumDriverManager.java:492)

at com.kms.katalon.core.webui.driver.WebMobileDriverFactory.createMobileDriver(WebMobileDriverFactory.java:168)

at com.kms.katalon.core.webui.driver.DriverFactory.startNewBrowser(DriverFactory.java:384)

at com.kms.katalon.core.webui.driver.DriverFactory.openWebDriver(DriverFactory.java:264)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword$_openBrowser_closure1.doCall(OpenBrowserKeyword.groovy:74)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword$_openBrowser_closure1.call(OpenBrowserKeyword.groovy)

at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:20)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.openBrowser(OpenBrowserKeyword.groovy:81)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.execute(OpenBrowserKeyword.groovy:67)

at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:74)

at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.openBrowser(WebUiBuiltInKeywords.groovy:64)

at Script1700125863524.run(Script1700125863524.groovy:20)

... 13 more

Caused by: java.lang.reflect.InvocationTargetException

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)

at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at io.appium.java_client.remote.AppiumCommandExecutor$1.createSession(AppiumCommandExecutor.java:186)

... 39 more

Caused by: org.openqa.selenium.WebDriverException: An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: 'Command 'C:\\Users\\admin\\.katalon\\tools\\android_sdk\\platform-tools\\adb.exe -P 5037 -s cd2964fe shell 'settings delete global hidden_api_policy_pre_p_apps;settings delete global hidden_api_policy_p_apps;settings delete global hidden_api_policy'' exited with code 255'; Command output:

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:25:53'

System info: host: 'DESKTOP-GCU4975', ip: '192.168.166.129', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '17.0.7'

Driver info: driver.version: SwipeableAndroidDriver

remote stacktrace: UnknownError: An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: 'Command 'C:\\Users\\admin\\.katalon\\tools\\android_sdk\\platform-tools\\adb.exe -P 5037 -s cd2964fe shell 'settings delete global hidden_api_policy_pre_p_apps;settings delete global hidden_api_policy_p_apps;settings delete global hidden_api_policy'' exited with code 255'; Command output:

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

Exception occurred while executing 'delete':

java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS

at com.android.providers.settings.SettingsProvider.enforceWritePermission(SettingsProvider.java:2561)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1562)

at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1554)

at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1525)

at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:568)

at android.content.ContentProvider.call(ContentProvider.java:2511)

at android.content.ContentProvider$Transport.call(ContentProvider.java:525)

at com.android.providers.settings.SettingsService$MyShellCommand.deleteForUser(SettingsService.java:410)

at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:284)

at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97)

at android.os.ShellCommand.exec(ShellCommand.java:38)

at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:51)

at android.os.Binder.shellCommand(Binder.java:1073)

at android.os.Binder.onTransact(Binder.java:901)

at android.os.Binder.execTransactInternal(Binder.java:1331)

at android.os.Binder.execTransact(Binder.java:1268)

at getResponseForW3CError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:804:9)

at asyncHandler (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\protocol.js:380:37)

at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)

at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)

at org.openqa.selenium.remote.W3CHandshakeResponse.lambda$errorHandler$0(W3CHandshakeResponse.java:62)

at org.openqa.selenium.remote.HandshakeResponse.lambda$getResponseFunction$0(HandshakeResponse.java:30)

at org.openqa.selenium.remote.ProtocolHandshake.lambda$createSession$0(ProtocolHandshake.java:126)

at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:128)

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)

at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at io.appium.java_client.remote.AppiumCommandExecutor$1.createSession(AppiumCommandExecutor.java:186)

at io.appium.java_client.remote.AppiumCommandExecutor.createSession(AppiumCommandExecutor.java:217)

at io.appium.java_client.remote.AppiumCommandExecutor.execute(AppiumCommandExecutor.java:239)

at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:552)

at io.appium.java_client.DefaultGenericMobileDriver.execute(DefaultGenericMobileDriver.java:42)

at io.appium.java_client.AppiumDriver.execute(AppiumDriver.java:1)

at io.appium.java_client.android.AndroidDriver.execute(AndroidDriver.java:1)

at com.kms.katalon.core.appium.driver.SwipeableAndroidDriver.execute(SwipeableAndroidDriver.java:1)

at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:213)

at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:131)

at io.appium.java_client.DefaultGenericMobileDriver.<init>(DefaultGenericMobileDriver.java:38)

at io.appium.java_client.AppiumDriver.<init>(AppiumDriver.java:84)

at io.appium.java_client.android.AndroidDriver.<init>(AndroidDriver.java:85)

at com.kms.katalon.core.appium.driver.SwipeableAndroidDriver.<init>(SwipeableAndroidDriver.java:24)

at com.kms.katalon.core.appium.driver.AppiumDriverManager.createMobileDriver(AppiumDriverManager.java:510)

at com.kms.katalon.core.appium.driver.AppiumDriverManager.createMobileDriver(AppiumDriverManager.java:492)

at com.kms.katalon.core.webui.driver.WebMobileDriverFactory.createMobileDriver(WebMobileDriverFactory.java:168)

at com.kms.katalon.core.webui.driver.DriverFactory.startNewBrowser(DriverFactory.java:384)

at com.kms.katalon.core.webui.driver.DriverFactory.openWebDriver(DriverFactory.java:264)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword$_openBrowser_closure1.doCall(OpenBrowserKeyword.groovy:74)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword$_openBrowser_closure1.call(OpenBrowserKeyword.groovy)

at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:20)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.openBrowser(OpenBrowserKeyword.groovy:81)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.execute(OpenBrowserKeyword.groovy:67)

at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:74)

at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.openBrowser(WebUiBuiltInKeywords.groovy:64)

at New Test Case.run(New Test Case:20)

... 13 more
2 Likes

Please enable “USB Debugging (Security settings)” from developer options and try again

1 Like

i run the test by enabling it only.

Add images

Add images

1 Like

if Disable Permission Monitoring is availabe then → enable it.
also enable all option under debugging

It works after i enable the permission monitoring and also have to revoke "revoke USB debugging authorizations " before USB debugging.

1 Like