I am using the latest appium version 2.5.1. While initializing the appium server, I tried to pass the USE_PLUGINS flag in arguments and it caused failure in searching xpath locators. I passed this flag like this →
final AppiumServiceBuilder serviceBuilder = new AppiumServiceBuilder().withArgument(() -> "--base-path", "/wd/hub");
serviceBuilder.withArgument(GeneralServerFlag.RELAXED_SECURITY);
serviceBuilder.withArgument(GeneralServerFlag.USE_PLUGINS, "all");
Now when I remove the USE_PLUGINS argument, the script runs fine, but with it, all xpath locators are failing. Why is it happening?