robotframework-appium-smartlocator
Smart locator resolver for Appium and Robot Framework.
Overview
This library resolves mobile elements from human-readable descriptions and automatically generates the best locator strategy based on the current Appium page source.
It is designed primarily for Android mobile automation using Appium and Robot Framework.
Features
- Human-readable element description (e.g. "botao continuar")
- Semantic parsing of element type and identifier
- Intelligent candidate scoring based on XML attributes
- Automatic locator generation (id, accessibility, UIAutomator, XPath)
- Seamless integration with Robot Framework
- Works with Appium mobile automation
Installation
From PyPI (future)
pip install robotframework-appium-smartlocator
Local development
pip install -e .
Project Structure
robotframework-appium-smartlocator/
├── appium_smartlocator/
│ ├── __init__.py
│ ├── semantic_parser.py
│ ├── element_resolver.py
│ ├── locator_builder.py
│ ├── smart_element_resolver.py
│ └── smart_robot_library.py
├── pyproject.toml
└── README.md
Usage in Robot Framework
Import the library
*** Settings ***
Library AppiumSmartLocator
Available Keywords
Resolver Locator InteligenteClicar No ElementoPreencher ElementoValidar Elemento
Basic Example
*** Settings ***
Library appium_smartlocator.AppiumSmartLocator
*** Test Cases ***
Validate Button
Validar Elemento botao continuar
Example: Login Flow
*** Settings ***
Library AppiumSmartLocator
*** Test Cases ***
Login Example
Preencher Elemento campo usuario meu_usuario
Preencher Elemento campo senha minha_senha
Clicar No Elemento botao entrar
How It Works
- The library parses a human-readable description
- Identifies element type and target text
- Scans the Appium XML page source
- Scores possible candidates
- Selects the best match
- Builds an optimized locator
Locator Priority
The library generates locators in this order:
resource-id(best)accessibility idUiSelector (Android)XPath- fallback (
//*)
Requirements
- Python 3.10+
- Robot Framework
- Appium
- Android device/emulator
- Appium page source available via driver
Development Status
Current version: 0.1.3
This is the first functional version of the library.
Planned improvements:
- Smarter fallback strategies
- Better scoring logic
- Improved logging/debugging
- Support for more complex layouts
- Possible iOS support in future
Author
Paulo Rocha
Metadata
Release files for robotframework-appium-smartlocator 0.1.11
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| robotframework_appium_smartlocator-0.1.11.tar.gz | 10.2 kB | Without provenance | Details for robotframework_appium_smartlocator-0.1.11.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| robotframework_appium_smartlocator-0.1.11-py3-none-any.whl | Python 3 | none | any | Details for robotframework_appium_smartlocator-0.1.11-py3-none-any.whl |
Total release size: 21.0 kB
Release files / robotframework_appium_smartlocator-0.1.11.tar.gz
| Download URL | robotframework_appium_smartlocator-0.1.11.tar.gz |
|---|---|
| Size | 10.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a709bb9448a04fea28ca43e7d014136ac52c3bdf75fd19d17f1f7b4057a1f8ab
|
|
BLAKE2b-256 checksum How to use checksums |
540d0b490639c5032c602e0b3157b508a50fc11d22a16e5ca64dba7199da2116
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.1
|
Release files / robotframework_appium_smartlocator-0.1.11-py3-none-any.whl
| Download URL | robotframework_appium_smartlocator-0.1.11-py3-none-any.whl |
|---|---|
| Size | 10.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f774b7e6767581fd513ced7e9ea752153b91ecc98f4dd8819121198f8e5d737e
|
|
BLAKE2b-256 checksum How to use checksums |
d7dfe66f7019b088953c61902e6c853f31035c9acf5df62c2977e07769147783
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.1
|
Security for robotframework-appium-smartlocator 0.1.11
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.