Package: rpaframework
REQUEST for user input!We are looking at improving our keyword usage to cover situations where developer might be
struggling to smoothly write task for a Robot. Describe the situation where yourimplementation speed slowsdue to the lack of easier syntax.Comment HEREIntroductionRPA Frameworkis a collection of open-source libraries and tools for
Robotic Process Automation (RPA), and it is designed to be used with bothRobot FrameworkandPython. The goal is to offer well-documented and
actively maintained core libraries for Software Robot Developers.Learn more about RPA atRobocorp Documentation.The project is:100% Open SourceSponsored byRobocorpOptimized for RobocorpControl RoomandDeveloper ToolsAccepting external contributionsLinksHomepage:https://www.github.com/robocorp/rpaframework/Documentation:https://rpaframework.org/PyPI:https://pypi.org/project/rpaframework/Release notes:https://rpaframework.org/releasenotes.htmlRSS feed:https://rpaframework.org/releases.xmlPackagesFrom the above packages,rpaframework-coreandrpaframework-recognitionare
support packages, which alone donotcontain any libraries.LibrariesThe RPA Framework project currently includes the following libraries:Thexin thePACKAGEcolumn means that libraryisincluded in therpaframeworkpackage and for example.x,dialogsmeans thatRPA.Dialogslibrary is provided in both therpaframeworkandrpaframework-dialogspackages.LIBRARY NAMEDESCRIPTIONPACKAGEArchiveArchiving TAR and ZIP filesxAssistantDisplay information to a user and request input.assistantBrowser.SeleniumControl browsers and automate the webxBrowser.PlaywrightNewer way to control browsersspecial (more below)CalendarFor date and time manipulationsxCloud.AWSUse Amazon AWS servicesx,awsCloud.AzureUse Microsoft Azure servicesxCloud.GoogleUse Google Cloud servicesgoogleCryptoCommon hashing and encryption operationsxDatabaseInteract with databasesxDesktopCross-platform desktop automationxDesktop.ClipboardInteract with the system clipboardxDesktop.OperatingSystemRead OS information and manipulate processesxDocumentAIIntelligent Document Processing wrapperxDocumentAI.Base64AIIntelligent Document Processing servicexDocumentAI.NanonetsIntelligent Document Processing servicexEmail.ExchangeE-Mail operations (Exchange protocol)xEmail.ImapSmtpE-Mail operations (IMAP & SMTP)xExcel.ApplicationControl the Excel desktop applicationxExcel.FilesManipulate Excel files directlyxFileSystemRead and manipulate files and pathsxFTPInteract with FTP serversxHTTPInteract directly with web APIsxHubspotAccess HubSpot CRM data objectshubspotImagesManipulate imagesxJavaAccessBridgeControl Java applicationsxJSONManipulate JSON objectsxMFAAuthenticate using one-time passwords (OTP) & OAuth2xNotifierNotify messages using different servicesxOpenAIArtificial Intelligence serviceopenaiOutlook.ApplicationControl the Outlook desktop applicationxPDFRead and create PDF documentsx,pdfRobocorp.ProcessUse the Robocorp Process APIxRobocorp.WorkItemsUse the Robocorp Work Items APIxRobocorp.VaultUse the Robocorp Secrets APIxRobocorp.StorageUse the Robocorp Asset Storage APIxSalesforceSalesforce operationsxSAPControl SAP GUI desktop clientxSmartsheetAccess Smartsheet sheetsxTablesManipulate, sort, and filter tabular dataxTasksControl task executionxTwitterTwitter API interfacexWindowsAlternative library for Windows automationx,windowsWord.ApplicationControl the Word desktop applicationxInstallation of RPA.Browser.PlaywrightTheRPA.Browser.Playwrightat the moment requires special installation, because
of the package size and the post install step it needs to be fully installed.Minimum requiredconda.yamlto install Playwright:channels:-conda-forgedependencies:-python=3.9.16-nodejs=16.14.2-pip=22.1.2-pip:-robotframework-browser==17.2.0-rpaframework==24.1.2rccPostInstall:-rfbrowser initInstallationLearn about installing Python packages atInstalling Python Packages.Default installation method with RobocorpDeveloper Toolsusingconda.yaml:channels:-conda-forgedependencies:-python=3.9.16-pip=22.1.2-pip:-rpaframework==24.1.2To install all extra packages (including Playwright dependencies), you can use:channels:-conda-forgedependencies:-python=3.9.16-tesseract=4.1.1-nodejs=16.14.2-pip=22.1.2-pip:-robotframework-browser==17.2.0-rpaframework==24.1.2-rpaframework-aws==5.2.8-rpaframework-google==7.0.3-rpaframework-recognition==5.1.2rccPostInstall:-rfbrowser initSeparate installation of AWS, Dialogs, PDF and Windows libraries without the mainrpaframework:channels:-conda-forgedependencies:-python=3.9.16-pip=22.1.2-pip:-rpaframework-aws==5.2.8# included in the rpaframework as an extra-rpaframework-dialogs==4.0.4# included in the rpaframework by default-rpaframework-pdf==7.1.5# included in the rpaframework by default-rpaframework-windows==7.3.2# included in the rpaframework by defaultInstallation method withpipusing Pythonvenv:python-mvenv.venvsource.venv/bin/activatepipinstallrpaframeworkNotePython 3.8 or higher is requiredExampleAfter installation the libraries can be directly imported insideRobot Framework:*** Settings ***LibraryRPA.Browser.Selenium*** Tasks ***Login as userOpen available browserhttps://example.comInput textid:user-name${USERNAME}Input textid:password${PASSWORD}The libraries are also available insidePython:fromRPA.Browser.SeleniumimportSeleniumlib=Selenium()lib.open_available_browser("https://example.com")lib.input_text("id:user-name",username)lib.input_text("id:password",password)Support and contactrpaframework.orgfor library documentationRobocorp Documentationfor guides and tutorials#rpaframeworkchannel inRobot Framework Slackif you
have open questions or want to contributeRobocorp Forumfor discussions about RPACommunicate with your fellow Software Robot Developers and Robocorp experts
atRobocorp Developers SlackContributingFound a bug? Missing a critical feature? Interested in contributing?
Head over to theContribution guideto see where to get started.DevelopmentRepository development isPythonbased and requires at minimum
Python version 3.8+ installed on the development machine. The default Python version used in the
Robocorp Robot template is 3.9.16 so it is a good choice for the version to install. Not recommended
versions are 3.7.6 and 3.8.1, because they have issues with some of the dependencies related torpaframework.
At the time the newer Python versions starting from 3.11 are also not recommended, because some of
the dependencies might cause issues.Repository development tooling is based onpoetryandinvoke. Poetry is the
underlying tool used for compiling, building and running the package. Invoke is used
for scripting purposes, for example for linting, testing and publishing tasks.Before writing any code, please read and acknowledge our extensiveDev Guide.First steps to start developing:initial poetry configurationpoetryconfigvirtualenvs.pathnullpoetryconfigvirtualenvs.in-projecttruepoetryconfigrepositories.devpi"https://devpi.robocorp.cloud/ci/test"git clone the repositorycreate a new Git branch or switch to correct branch or stay in master branchsome branch naming conventionsfeature/name-of-feature,hotfix/name-of-the-issue,release/number-of-releasepoetry installwhich install package with its dependencies into the.venvdirectory of the package, for examplepackages/main/.venvif testing against Robocorp Robot which is usingdevdata/env.jsonset environment variablesorpoetry buildand use resulting .whl file (in thedist/directory) in the Robotconda.yamlorpoetry buildand push resulting .whl file  (in thedist/directory) into a repository and use raw url
to include it in the Robotconda.yamlanother possibility for Robocorp internal development is to use Robocorpdevpiinstance, bypoetry publish--ciand pointconda.yamlto use rpaframework version in devpipoetry run python-mrobot <ROBOT_ARGS> <TARGET_ROBOT_FILE>commonROBOT_ARGSfrom Robocorp Robot template:--reportNONE--outputdiroutput--logtitle"Task log"poetry run python <TARGET_PYTHON_FILE>invoke lintto make sure that code formatting is according torpaframeworkrepository guidelines.
It is possible and likely that Github action will fail the if developer has not linted the code changes. Code
formatting is based onblackandflake8and those are run with theinvoke lint.the library documentation can be created in the repository root (so called “meta” package level). The documentation is
built by the docgen tools using the locally installed version of the project, local changes for the main package
will be reflected each time you generate the docs, but if you want to see local changes for optional packages, you must
utilizeinvokeinstall-local--package<package_name>using the appropriate package name (e.g.,rpaframework-aws). This
will reinstall that package as a local editable version instead of from PyPI. Multiple such packages can be added by
repeating the use of the--packageoption. In order to reset this, useinvoke install--reset.poetry updateand/orinvokeinstall-local--package<package name>make docsopendocs/build/html/index.htmlwith the browser to view the changes or executemake localand navigate tolocalhost:8000to view docs as a live local webpage.# Before[tool.poetry.dependencies]python="^3.8"rpaframework={path="packages/main",extras=["cv","playwright","aws"]}rpaframework-google="^4.0.0"rpaframework-windows="^4.0.0"# After[tool.poetry.dependencies]python="^3.8"rpaframework={path="packages/main",extras=["cv","playwright"]}rpaframework-aws={path="packages/aws"}rpaframework-google="^4.0.0"rpaframework-windows="^4.0.0"invoke test(this will run both Python unittests and robotframework tests defined in the packagestests/ directory)to run specific Python test:poetry run pytestpath/to/test.py::test_functionto run specific Robotframework test:inv testrobot-r<robot_name>-t<task_name>git commit changesgit push changes to remotecreate pull request from the branch describing changes included in the descriptionupdatedocs/source/releasenotes.rstwith changes (commit and push)Packaging and publishing are done after changes have been merged into master branch.
All the following steps should be done within master branch.git pull latest changes into master branchin the package directory containing changes executeinvoke lintandinvoke testupdatepyproject.tomlwith new version according to semantic versioningupdatedocs/source/releasenotes.rstwith changesin the repository root (so called “meta” package level) run commandpoetry updategit commit changedpoetry.lockfiles (on meta and target package level),releasenotes.rstandpyproject.tomlwith message “PACKAGE. version x.y.z”git pushinvoke publishafter Github action on master branch is all greenSome recommended tools for developmentVisual Studio Codeas a code editor with following extensions:Robocorp CodeRobot Framework Language ServerGitLensPython extensionGitHub Desktopwill make version management less prone to errorsLicenseThis project is open-source and licensed under the terms of theApache License 2.0.