-
-
Notifications
You must be signed in to change notification settings - Fork 6.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Appium Architecture Overhaul #5169
Milestone
Comments
Should this be a milestone? |
@jlipps Can we close this please? |
yes, it's done! |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The Problem
Over the years, Appium has grown organically in sometimes not-so-great ways. We've identified a number of problems that make Appium increasingly difficult to work on (especially for new developers) and increasingly prone to introducing regressions:
ios.js
andios-controller.js
define methods for the same class but in different files..bind(this)
because of JS scopingfor
loops or_.each
orArray.each
caolan/async
orQ
.It's time to spend some effort and resources cleaning house and taking Appium to the next level of quality and longevity. Tackling tech debt is always a tradeoff, but we are reaching a point where developing features has already significantly slowed because of time spent fixing bugs, many of which are due to the tech debt we have accrued. It's worth the investment to resolve these issues now before we wind up in too much of a corner. Appium has been gaining significant traction in the marketplace, and appears to be functioning well for its current users. It's a good time to pause current development and prepare for the future. If we don't do this, Appium will lose the ability to develop at a velocity appropriate for its popularity and importance. The mobile strategy for many companies banks on Appium being stable, reliable, and cutting-edge. We don't want to lose that possibility because of tech debt. From a positive perspective, the Appium dev team will be one of the first to implement solutions to these kinds of problems for large Node.js apps. We'll reaffirm Appium's position on the cutting edge and have the opportunity to share our experiences and any wisdom we've gleaned from the process with other developers.
The Solution
We want to address these issues in the following way:
async/await
equivalents.async/await
are new keywords proposed to enter JS in a future version. While not part of ES2015, they are already supported by transpilers and have a large fan-base. They are the equivalent of monocle-js but are supported as syntactic sugar over Promises, and are therefore to be preferred as part of the language itself. Moreover, they are semantically more transparent than using generators andyield
. This will be a large task but will make Appium's code more compact and infinitely easier to read and write.(Note that much of this strategy was worked out over a long period of time in #3911)
The Project
We want to do this work as part of the Appium 1.5 release. This release will target no features or bugfixes (other than ones that come along for free with the rearchitecture). The rationale for this is that we want to replace the guts of Appium with no visible change to the user, and no breaking changes. The test suite as it stands now should continue to pass after the rearchitecture. Once this is all in place, it will be much easier to fix bugs and add fixtures with greater velocity. We're talking about the most radical change to the Appium codebase that's happened since we moved to Node.js, but we want it to go completely unnoticed by users (unless they notice greater stability and reliability).
The Work
Here are the tasks which are a planned part of this rewrite, separated into 5 distinct phases:
Phase 1: Planning, new architecture, CI
Phase 2: Migrating libraries
Phase 3: Migrating drivers
Phase 4: Bringing it all together, cleanup, misc
--desired-capabilities
flagchild_process.exec
are now usingteen_process.exec
npm install
Phase 5: Test, beta, release
The text was updated successfully, but these errors were encountered: