Appium 2.0 - [W3C] Matched W3C error code 'invalid argument' to InvalidArgumentError
Maintainer antworten meist innerhalb von 5 Tagen
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 35/100
- Issue-Typ
- Bug
- Klarheit
- Größtenteils klar
- Aktivitätsstatus
- Veraltet
- Tech-Stack
- java
- Bereich
- mobile-dev
Rechercherichtung
Führe zunächst die bereitgestellte Java-Tap-Action-Reproduktion gegen die aufgeführten Appium- und Android-Versionen aus und vergleiche anschließend die serialisierten Aktionen mit den verlinkten Appium-Logs. Der relevante gemeldete Einstiegspunkt ist die W3C /actions-Anfrage, wobei der Fehler in W3CActions.safeHandle angezeigt wird; abgeschlossen ist die Aufgabe, wenn die Ursache der invalid-argument-Antwort identifiziert und dokumentiert oder korrigiert wurde.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Description
Getting error while perform tap Action using W3C
Environment
- Java client build version: 8.5.1
- Appium Version: 2.0.0-rc.3
- Node.js version: v14.18.0
- Mobile platform/version: Android 12
- Real device: Moto G20 Fusion
Code To Reproduce Issue [ Good To Have ]
Below is the sample tap action code
public void tapCenterUsingW3C()
{
log.info("CLICKING AT CENTER OF SCREEN");
Dimension dimension = getAppiumDriver().manage().window().getSize();
System.out.println("dimension dimension " + dimension);
Point point = new Point((int) (dimension.width * 0.5), (int) (dimension.height * 0.5));
System.out.println("dimension dimension point.getX() " + point.getX());
System.out.println("dimension dimension point.getY() " + point.getY());
PointerInput FINGER = new PointerInput(TOUCH, "finger");
Sequence tap = new Sequence(FINGER, 100)
.addAction(FINGER.createPointerMove(ofMillis(10), viewport(), point.getX(), point.getY()))
.addAction(FINGER.createPointerDown(LEFT.asArg()))
.addAction(new Pause(FINGER, ofMillis(milliseconds)))
.addAction(FINGER.createPointerUp(LEFT.asArg()));
getAppiumDriver().perform(List.of(tap));
log.info("CLICKED AT CENTER OF SCREEN");
}
Link To Appium Logs
[debug] [AndroidUiautomator2Driver@3aba (07890412)] Matched '/actions' to command name 'performActions'
[debug] [AndroidUiautomator2Driver@3aba (07890412)] Proxying [POST /actions] to [POST http://127.0.0.1:10001/session/042567b1-6a57-4895-816a-60f11f23ba74/actions] with body: {"actions":[{"id":"finger","type":"pointer","parameters":{"pointerType":"touch"},"actions":[{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"},{"duration":0,"type":"pause"}...
[AndroidUiautomator2Driver@3aba (07890412)] Got response with status 400: {"sessionId":"042567b1-6a57-4895-816a-60f11f23ba74","value":{"error":"invalid argument","message":"Exception while reading JSON","stacktrace":"io.appium.uiautomator2.common.exceptions.InvalidArgumentException: Exception while reading JSON\n\tat io.appium.uiautomator2.handler.W3CActions.safeHandle(W3CActions.java:92)\n\tat io.appium.uiautomator2.handler.request.SafeRequestHandler.handle(SafeRequestHandler.java:59)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleRequest(AppiumServlet.java:277)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleHttpRequest(AppiumServlet.java:271)\n\tat io.appium.uiautomator2.http.ServerHandler.channelRead(ServerHandler.java:68)\n\tat io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)\n\tat io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:352)\n\tat io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:345)\n\tat io.n...
[debug] [W3C] Matched W3C error code 'invalid argument' to InvalidArgumentError
[debug] [AndroidUiautomator2Driver@3aba (07890412)] Encountered internal error running command: io.appium.uiautomator2.common.exceptions.InvalidArgumentException: Exception while reading JSON
Detailed Appium Log:
https://gist.github.com/dipakkumar1225/76f6e226e8fb1e1a5110deb30a0aad62
- Vorherrschende Sprache
- Java
- Sterne
- 1.3k
- Forks
- 755
- Ø Merge
- 5 T. 14 Std.
- Gemergte PRs (30 T.)
- 8
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Kein Beitragsleitfaden
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus appium/java-client
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 25/100
appium/java-client#2426 ·
Maintainer antworten meist innerhalb von 5 Tagen
-
bug
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 50/100
appium/java-client#2372 ·
Maintainer antworten meist innerhalb von 5 Tagen
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 30/100
appium/java-client#2368 ·
Maintainer antworten meist innerhalb von 5 Tagen
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 30/100
appium/java-client#2341 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 5 Tagen
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 15/100
appium/java-client#2323 ·
Maintainer antworten meist innerhalb von 5 Tagen
Alle Issues in appium/java-client
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
Maintainer antworten meist innerhalb von 1 Tag
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
github/copilot-sdk#2793 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Unify jpa4 into orm8Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
-
enhancement good first issue
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 88/100