Skip to main content

Android UI Automation Framework — like Geppetto brought Pinocchio to life, this tool brings your tests to life.

Project description

geppetto-android

Geppetto is a high-level Python framework for Android UI automation. It provides a single, typed API to orchestrate ADB, Fastboot, and UIAutomator2.

Just as Geppetto brought Pinocchio to life, this tool brings your Android tests to life.

Highlights

  • High-level Device facade for Android automation workflows.
  • Widget search through text, id, class, content description, and XPath.
  • Structured UI hierarchy parsing via lxml (WindowDump, Widget, Bounds).
  • Built-in services for Wi-Fi, lockscreen, and notification controls.
  • Optional extras for image/video analyzers and hardware integrations.

Requirements

  • Python 3.12+
  • Android SDK platform tools (adb, optional fastboot) available on PATH
  • Android device or emulator with ADB enabled

Installation

pip

pip install geppetto-android

Optional extras:

# Image/video analyzers
pip install "geppetto-android[analyzers]"

# Hardware integrations
pip install "geppetto-android[hardware]"

# All optional features
pip install "geppetto-android[all]"

uv

uv add geppetto-android
uv add "geppetto-android[analyzers]"
uv add "geppetto-android[hardware]"
uv add "geppetto-android[all]"

Quick start

from geppetto import By, Device, WifiSecurityType

device = Device("SERIAL_NUMBER")

device.install("app.apk", replace=True)
device.open_app("com.example.app")

login_button = device.await_widget(By.TEXT, "Login", timeout=15)
device.click(login_button)

device.screenshot("login_screen", pull_to_results=True)

device.wifi.connect("MyNetwork", WifiSecurityType.WPA2, "password")

Main components

  • Device: primary facade and entry point.
  • geppetto.core: ADB/Fastboot clients.
  • geppetto.ui: UI models (WindowDump, Widget, Bounds, Children).
  • geppetto.services: automation services (wifi, lockscreen, notification).
  • geppetto.models: enums such as By, Direction, WifiSecurityType, CommonClasses.

Development

git clone https://github.com/desodre/geppetto.git
cd geppetto
uv sync --all-extras

Links

License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

geppetto_android-2.0.4.tar.gz (75.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

geppetto_android-2.0.4-py3-none-any.whl (24.1 kB view details)

Uploaded Python 3

File details

Details for the file geppetto_android-2.0.4.tar.gz.

File metadata

  • Download URL: geppetto_android-2.0.4.tar.gz
  • Upload date:
  • Size: 75.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for geppetto_android-2.0.4.tar.gz
Algorithm Hash digest
SHA256 89ec238927dad430de856dbe274ecbc43e54610f95411a0fd5c068bb057b2b60
MD5 e82c9c60990c497a16e425d12c6183f8
BLAKE2b-256 dedb8dbb51cfabec530dde0f8505958bf0d9d4d3b04bf267251d1b3292a56081

See more details on using hashes here.

Provenance

The following attestation bundles were made for geppetto_android-2.0.4.tar.gz:

Publisher: publish.yml on desodre/Geppetto

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geppetto_android-2.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for geppetto_android-2.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 33facd1eb0d2f052b93a4d5de5c4d868507436ec338426b3e312566f71fa027d
MD5 11732d6d7aa5a97cd36b1ec4ce41fc79
BLAKE2b-256 b604f73cae3b53f3fc8a6976b96bc5cabec482e1ef5555b1bd25901d9bc4fd97

See more details on using hashes here.

Provenance

The following attestation bundles were made for geppetto_android-2.0.4-py3-none-any.whl:

Publisher: publish.yml on desodre/Geppetto

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page