You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error initializing the driver: Message: The requested resource could not be found, or a request was received using an HTTP method that is not supported by the mapped resource
#970
Closed
jt7777777 opened this issue
Mar 5, 2024
· 1 comment
please help me i am getting error:
Initializing Appium driver with desired capabilities…
Error initializing the driver: Message: The requested resource could not be found, or a request was received using an HTTP method that is not supported by the mapped resource
HOOK-ERROR in before_all: WebDriverException: Message: The requested resource could not be found, or a request was received using an HTTP method that is not supported by the mapped resource
HOOK-ERROR in after_all: AttributeError: ‘Context’ object has no attribute ‘driver’
C:\Users\jakub>appium
[Appium] Welcome to Appium v2.5.1
[Appium] The autodetected Appium home path: C:\Users\jakub.appium
[Appium] Attempting to load driver uiautomator2...
[Appium] Requiring driver at C:\Users\jakub.appium\node_modules\appium-uiautomator2-driver\build\index.js
[Appium] AndroidUiautomator2Driver has been successfully loaded in 0.813s
[Appium] Appium REST http interface listener started on http://0.0.0.0:4723
[Appium] You can provide the following URLs in your client code to connect to this server:
[Appium] http://192.168.0.129:4723/
[Appium] http://127.0.0.1:4723/ (only accessible from the same host)
[Appium] Available drivers:
[Appium] - uiautomator2@3.0.1 (automationName 'UiAutomator2')
[Appium] No plugins have been installed. Use the "appium plugin" command to install the one(s) you want to use.
[HTTP] Request idempotency key: 27aabe7c-2ce6-4ba4-bf90-798ecb9cf24c
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:deviceName":"emulator-5554","appium:platformVersion":"VanillaIceCream","appium:app":"C:\Users\jakub\Downloads\Appium\AppiumProject\amaze-file-manager-3-10.apk","appium:automationName":"UiAutomator2"}}}
[HTTP] No route found for /wd/hub/session
[HTTP] <-- POST /wd/hub/session 404 12 ms - 211
[HTTP]
[HTTP] --> GET /wd/hub/status
[HTTP] {}
[HTTP] No route found for /wd/hub/status
[HTTP] <-- GET /wd/hub/status 404 11 ms - 211
[HTTP]
[HTTP] <-- GET /favicon.ico 200 1 ms - 1150
[HTTP]
[HTTP] Request idempotency key: a10acadc-3274-4c83-84dc-085b742f49bc
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:deviceName":"emulator-5554","appium:platformVersion":"VanillaIceCream","appium:app":"C:\Users\jakub\Downloads\Appium\AppiumProject\amaze-file-manager-3-10.apk","appium:automationName":"UiAutomator2"}}}
[HTTP] No route found for /wd/hub/session
[HTTP] <-- POST /wd/hub/session 404 2 ms - 211
Env code:
`from appium import webdriver
from behave import use_fixture
[Appium] You can provide the following URLs in your client code to connect to this server:
[Appium] http://192.168.0.129:4723/
[Appium] http://127.0.0.1:4723/ (only accessible from the same host)
please help me i am getting error:
Initializing Appium driver with desired capabilities…
Error initializing the driver: Message: The requested resource could not be found, or a request was received using an HTTP method that is not supported by the mapped resource
HOOK-ERROR in before_all: WebDriverException: Message: The requested resource could not be found, or a request was received using an HTTP method that is not supported by the mapped resource
HOOK-ERROR in after_all: AttributeError: ‘Context’ object has no attribute ‘driver’
Myversions: Appium-Python-Client==2.10.0, selenium==4.1.0, Python 3.12.2, appium: 2.5.1, uiautomator2@3.0.1
Appium logs:
C:\Users\jakub>appium
[Appium] Welcome to Appium v2.5.1
[Appium] The autodetected Appium home path: C:\Users\jakub.appium
[Appium] Attempting to load driver uiautomator2...
[Appium] Requiring driver at C:\Users\jakub.appium\node_modules\appium-uiautomator2-driver\build\index.js
[Appium] AndroidUiautomator2Driver has been successfully loaded in 0.813s
[Appium] Appium REST http interface listener started on http://0.0.0.0:4723
[Appium] You can provide the following URLs in your client code to connect to this server:
[Appium] http://192.168.0.129:4723/
[Appium] http://127.0.0.1:4723/ (only accessible from the same host)
[Appium] Available drivers:
[Appium] - uiautomator2@3.0.1 (automationName 'UiAutomator2')
[Appium] No plugins have been installed. Use the "appium plugin" command to install the one(s) you want to use.
[HTTP] Request idempotency key: 27aabe7c-2ce6-4ba4-bf90-798ecb9cf24c
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:deviceName":"emulator-5554","appium:platformVersion":"VanillaIceCream","appium:app":"C:\Users\jakub\Downloads\Appium\AppiumProject\amaze-file-manager-3-10.apk","appium:automationName":"UiAutomator2"}}}
[HTTP] No route found for /wd/hub/session
[HTTP] <-- POST /wd/hub/session 404 12 ms - 211
[HTTP]
[HTTP] --> GET /wd/hub/status
[HTTP] {}
[HTTP] No route found for /wd/hub/status
[HTTP] <-- GET /wd/hub/status 404 11 ms - 211
[HTTP]
[HTTP] <-- GET /favicon.ico 200 1 ms - 1150
[HTTP]
[HTTP] Request idempotency key: a10acadc-3274-4c83-84dc-085b742f49bc
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:deviceName":"emulator-5554","appium:platformVersion":"VanillaIceCream","appium:app":"C:\Users\jakub\Downloads\Appium\AppiumProject\amaze-file-manager-3-10.apk","appium:automationName":"UiAutomator2"}}}
[HTTP] No route found for /wd/hub/session
[HTTP] <-- POST /wd/hub/session 404 2 ms - 211
Env code:
`from appium import webdriver
from behave import use_fixture
def before_all(context):
try:
desired_caps = {
'platformName': 'Android',
'deviceName': 'emulator-5554',
'platformVersion': 'VanillaIceCream',
'app': 'C:\Users\jakub\Downloads\Appium\AppiumProject\amaze-file-manager-3-10.apk',
'automationName': 'UiAutomator2'
}
print("Initializing Appium driver with desired capabilities...")
context.driver = webdriver.Remote('http://127.0.0.1:4723/wd/hub', desired_caps)
print("Driver initialized:", context.driver)
except Exception as e:
print(f"Error initializing the driver: {e}")
raise
def after_all(context):
"""
Teardown that runs after all tests.
Here you might close the connection to the Appium server.
"""
context.driver.quit()
def before_feature(context, feature):
"""
This runs before each feature file is exercised.
"""
# Setup specific to a feature can be added here.
def after_feature(context, feature):
"""
This runs after each feature file is exercised.
"""
# Teardown specific to a feature can be added here.
def before_scenario(context, scenario):
"""
This runs before each scenario is run.
"""
# Setup specific to a scenario can be added here.
def after_scenario(context, scenario):
"""
This runs after each scenario is run.
"""
# Teardown specific to a scenario can be added here.
`
The text was updated successfully, but these errors were encountered: