Skip to content

Stable Apple device behavior#400

Open
e-khalilov wants to merge 6 commits intodevelopfrom
e.khalilov/ios-stable-update/TAP-3306
Open

Stable Apple device behavior#400
e-khalilov wants to merge 6 commits intodevelopfrom
e.khalilov/ios-stable-update/TAP-3306

Conversation

@e-khalilov
Copy link
Collaborator

The purpose of this update was to optimize the Apple device workflow:

  • Replaced the embedded WebDriverAgent source with the appium-webdriveragent npm package
  • The build / installation / validation / cleanup processes are now controlled by the appium-webdriveragent package
  • Refactored touch events, optimized the touchMove event, which can now have intermediate points in the path instead of a straight line with "from - to" coordinates
  • Added setup-wda npm script that opens WebDriverAgent.xcodeproj from ./node_modules in Xcode
  • Added save-wda-sign npm script to save the user's signature for WebDriverAgent.xcodeproj, which must be used after each Xcode project edit, as dependency reinstallation ( npm install ) causes a reset
  • Added apply-wda-sign npm script to apply the saved user signature to the WebDriverAgent.xcodeproj project
  • When releasing an Apple device, it goes into lock mode and stops the current WDA Session
  • Implemented a healthcheck mechanism for the WebDriverAgent Server running on the device, which terminates the process after 4 failed attempts
    ( the ios-provider unit will automatically restart the device process )
  • Fix incorrect device model and marketName display in ui
  • Replaced usbmux with usb-hotplug to reduce USB monitoring overhead
    ( now using native macOS IOKit API )

During the work, bugs and technical debt were fixed:

  • Removed tsx from the project, added a postinstall script that initiates the project build with copying all necessary assets to the build folder and installing dependencies in ui
  • Added a postinstall script in ui that initiates the project build
  • Devices now always correctly reflect their status
    ( OFFLINE = 1 | ONLINE = 3 | CONNECTING = 4 | PREPARING = 6 )
  • Fixed the No display width or height bug that prevented ui from displaying the screen broadcast
  • Fixed a bug that prevented releasing Apple devices
  • Fixed a bug where repeated device connections were ignored
  • Added important flags when launching ios-device by the ios-provider unit

Целью данного обновления была оптимизация работы Apple устройств:

  • Локальный клон WebDriverAgent заменен на установку пакета appium-webdriveragent через npm
  • Процессы билда / установки / валидации / очистки теперь контролируются пакетом appium-webdriveragent
  • Отрефакторены touch события, оптимизировано touchMove событие, теперь оно может иметь промежуточные точки в пути вместо прямой с координатами "от - до"
  • Добавлен npm скрипт setup-wda открывающий WebDriverAgent.xcodeproj из node_modules в xcode
  • Добавлен npm скрипт save-wda-sign для сохранения подписи пользователя для WebDriverAgent.xcodeproj, его необходимо использовать после каждого редактирования xcode проекта, ведь при повторной установки зависимостей ( npm install ) происходит сброс
  • Добавлен npm скрипт apply-wda-sign для применения сохраненной подписи пользователя проекта WebDriverAgent.xcodeproj
  • При освобождении Apple устройства оно уходит в блокировку и останавливает текущую WDA Session
  • Реализован healthcheck механизм для запущенного на устройстве WebDriverAgent Server, который останавливает процесс при достижении 4х неудачных попыток
    ( юнит ios-provider автоматически запустит процесс девайса вновь )
  • Исправлено некорректное отображение model и marketName девайса в ui
  • Заменен usbmux на usb-hotplug для минимизации оверхеда при прослушке usb
    ( теперь используется нативный macOS IOKit API )

В процессе работы были исправлены баги и техдолг:

  • Убран tsx из проекта, добавлен postinstall скрипт инициирующий билд проекта с копированием всех необходимых ассетов в папку билда и установкой зависимостей в ui
  • В ui добавлен postinstall скрипт инициирующий билд проекта
  • Устройства теперь всегда корректно отражают свой статус
    ( OFFLINE = 1 | ONLINE = 3 | CONNECTING = 4 | PREPARING = 6 )
  • Исправлен баг No display width or height, из-за которого ui не мог отобразить трансляцию экрана
  • Исправлен баг, из-за которого невозможно было освободить Apple устройство
  • Исправлен баг, при котором игнорировалось повторное переподключение девайса
  • Добавлены важные флаги при запуске ios-device юнитов ios-provider

e-khalilov and others added 3 commits January 21, 2026 18:00
* Wire initial typescript (#338)

* Wire initial typescript

* Fix types

* Something works

* Finishing touches

* Linter fixes

* Build problems

* hotfix (#361)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Remove all DB connections from device side (#368)

* hotfix imei

* Decrease apt install list in dockerfile (#365)

* remove gm and jdk11

* remove libs

* Remove console-feed & react dependencies [backend only] (#366)

* remove dep console-feed

* minor fix

* linter fix

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix default quotas hierarchy QA-19255 (#367)

* -fix quotas
-fix lock
-fix test
-fix lint

* -fix test

---------

Co-authored-by: a.chistov <a.chistov@vk.team>

* dev units without db conn

* fix types

* minor fix

* minor fix

* minor fix

* remove useless sockets

---------

Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>

* fix device type & types (#374)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* reconnect in ADBObserver (#376)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* QA-10057 Remove users watcher groups-engine (#369)

* -fix after rebase
-remove user watcher
-user handler for alert message
default quotas handler
-fix merge
del handler
update quoats handler
user handler method
some fix
-move without change method of devices to separate class
-fix after move users method
-move db.users method to separate class

* add missing db method

---------

Co-authored-by: a.chistov <a.chistov@vk.team>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix heartbeat (#377)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* overrides dependencies (#378)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Automatic removal of disabled devices (#379)

* clear dead devices

* minor fix

* revert api edits

* revert ui (types) edits

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix linkifyjs issue (#380)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Resolve conflicts (#381)

* Hotfix: device imei issue (#371)

* hotfix

* minor fix

* fix types

* minor fix

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* increase ram for v8 (#372)

* hotfix (#373)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* hotfix ADBObserver (#375)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>

* Fixed transactions & minor optimizations (#382)

* minor edits

* fix transactions

* minor fix

* fix ts types

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Fix lint issues

* Minitouch refactoring (#388)

* Develop to Master for 1.5.1 (#364)

* Wire initial typescript (#338)

* Wire initial typescript

* Fix types

* Something works

* Finishing touches

* Linter fixes

* Build problems

* hotfix (#361)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Remove all DB connections from device side (#368)

* hotfix imei

* Decrease apt install list in dockerfile (#365)

* remove gm and jdk11

* remove libs

* Remove console-feed & react dependencies [backend only] (#366)

* remove dep console-feed

* minor fix

* linter fix

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix default quotas hierarchy QA-19255 (#367)

* -fix quotas
-fix lock
-fix test
-fix lint

* -fix test

---------

Co-authored-by: a.chistov <a.chistov@vk.team>

* dev units without db conn

* fix types

* minor fix

* minor fix

* minor fix

* remove useless sockets

---------

Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>

* fix device type & types (#374)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* reconnect in ADBObserver (#376)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* QA-10057 Remove users watcher groups-engine (#369)

* -fix after rebase
-remove user watcher
-user handler for alert message
default quotas handler
-fix merge
del handler
update quoats handler
user handler method
some fix
-move without change method of devices to separate class
-fix after move users method
-move db.users method to separate class

* add missing db method

---------

Co-authored-by: a.chistov <a.chistov@vk.team>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix heartbeat (#377)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* overrides dependencies (#378)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Automatic removal of disabled devices (#379)

* clear dead devices

* minor fix

* revert api edits

* revert ui (types) edits

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix linkifyjs issue (#380)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Resolve conflicts (#381)

* Hotfix: device imei issue (#371)

* hotfix

* minor fix

* fix types

* minor fix

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* increase ram for v8 (#372)

* hotfix (#373)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* hotfix ADBObserver (#375)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>

* Fixed transactions & minor optimizations (#382)

* minor edits

* fix transactions

* minor fix

* fix ts types

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Fix lint issues

---------

Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: Elmir Khalilov <52529096+e-khalilov@users.noreply.github.com>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>

* Hotfix: Fix broken import in ios

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* minitouch refactoring + TS

---------

Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>
Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>

* Sleep / wake keyevents (#390)

* Develop to Master for 1.5.1 (#364)

* Wire initial typescript (#338)

* Wire initial typescript

* Fix types

* Something works

* Finishing touches

* Linter fixes

* Build problems

* hotfix (#361)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Remove all DB connections from device side (#368)

* hotfix imei

* Decrease apt install list in dockerfile (#365)

* remove gm and jdk11

* remove libs

* Remove console-feed & react dependencies [backend only] (#366)

* remove dep console-feed

* minor fix

* linter fix

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix default quotas hierarchy QA-19255 (#367)

* -fix quotas
-fix lock
-fix test
-fix lint

* -fix test

---------

Co-authored-by: a.chistov <a.chistov@vk.team>

* dev units without db conn

* fix types

* minor fix

* minor fix

* minor fix

* remove useless sockets

---------

Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>

* fix device type & types (#374)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* reconnect in ADBObserver (#376)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* QA-10057 Remove users watcher groups-engine (#369)

* -fix after rebase
-remove user watcher
-user handler for alert message
default quotas handler
-fix merge
del handler
update quoats handler
user handler method
some fix
-move without change method of devices to separate class
-fix after move users method
-move db.users method to separate class

* add missing db method

---------

Co-authored-by: a.chistov <a.chistov@vk.team>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix heartbeat (#377)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* overrides dependencies (#378)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Automatic removal of disabled devices (#379)

* clear dead devices

* minor fix

* revert api edits

* revert ui (types) edits

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix linkifyjs issue (#380)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Resolve conflicts (#381)

* Hotfix: device imei issue (#371)

* hotfix

* minor fix

* fix types

* minor fix

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* increase ram for v8 (#372)

* hotfix (#373)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* hotfix ADBObserver (#375)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>

* Fixed transactions & minor optimizations (#382)

* minor edits

* fix transactions

* minor fix

* fix ts types

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Fix lint issues

---------

Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: Elmir Khalilov <52529096+e-khalilov@users.noreply.github.com>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>

* Hotfix: Fix broken import in ios

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* fix vulnerable deps (#384)

* sleep/wake event & fs checking fix

* fix ports slicing

---------

Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>
Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>

* Health checking of devices in provider (#391)

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* General Process Manager & iOS Refactoring (#394)

* add common process manager & refactor iOS

* update wda

* revert logger edits

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

* Fix apk install (#397)

* fix compose+logs && rewrite to ts

* ts fix

---------

Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>

---------

Co-authored-by: Maxim <me@alzhanov.ru>
Co-authored-by: e.khalilov <e.khalilov@vkteam.ru>
Co-authored-by: Maksim Alzhanov <m.alzhanov@vk.team>
Co-authored-by: Daniil <8039921+DaniilSmirnov@users.noreply.github.com>
Co-authored-by: Alexey Chistov <33050834+Alk2017@users.noreply.github.com>
Co-authored-by: a.chistov <a.chistov@vk.team>
@e-khalilov e-khalilov requested a review from a team as a code owner February 16, 2026 16:22
@SergeyAlekseevN SergeyAlekseevN self-requested a review February 16, 2026 16:43
irdkwmnsb
irdkwmnsb previously approved these changes Feb 17, 2026
@@ -842,7 +842,8 @@ message UpdateIosDevice{
required string platform = 3;
required string architecture = 4;
required string sdk = 5;
required IosServiceMessage service = 6;
required string marketName = 6;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change requires all components of the project to be updated simultaneously

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants