Skip to main content

FSUBot

A bot which serves as the foundation for other bots for use on the Florida State University website. It is useful for automating tasks that are otherwise very menial and tedious.

This project serves as a framework for creating bots which are designed for Florida State University websites. It handles logging into MyFSU automatically, and setting up ubiquitous attributes and functionality such as:

  1. Standard argument parsing

  2. Logging into MyFSU

  3. Web browser driver handling.

Where to Begin

Package Installation

Install the FSUBot package using pip.

$ pip install fsubot

If you receive a error 13 and/or a permission error, prefer:

$ pip install fsubot --user

rather than:

sudo pip install fsubot

Driver Installation

Download and install any driver from the following (I prefer chromedriver):

  • Chrome: chromedriver

  • Firefox: geckodriver

    • There has not been extensive testing using geckodriver, proceed with caution.

Ensure that the driver executable is located within your environment’s PATH variable. There are many readily available guides on Google for how to do this.

Bot Instantiation

If you instantiate your bot with the following:

fsu_dr = FSUBot(use_cli=True)

Then, you can pass in arguments like so:

$ python fsubot/bot.py --fsu-id abc13 --fsu-pw hunter2 --browser chrome --executable-path drivers/chromedriver

Examples

  • Vindicta, my personal bot which automatically enrolls for desired courses.

  • EasyGradeBot, my personal bot which traverses through a list of BlackBoard Smart View pages and downloads all submitted assignment’s most recently submitted attempts.

Page Navigation Information

After instantiating your bot, named bot, there are a few methods you can use for traversing the DOM and navigating to different pages.

Method 1

Use bot.dr, the accessible selenium.webdriver instance, and the well-documented Selenium API.

Method 2

{
    "pages": [
        {
            "title": "",
            "iframe": false,
            "xpath": "",
            "css_selector": ""
        },

        {
            "title": "",
            "iframe": false,
            "xpath": "",
            "css_selector": ""
        },

        {
            "title": "",
            "iframe": false,
            "xpath": "",
            "css_selector": ""
        },

        {
            "title": "",
            "iframe": false,
            "xpath": "",
            "css_selector": ""
        },

        {
            "title": "",
            "iframe": false,
            "xpath": "",
            "css_selector": ""
        },

        {
            "title": "",
            "iframe": false,
            "xpath": "",
            "css_selector": ""
        }
    ]
}

The elements will be sequentially passed to bot._click and clicked as if a real user was clicking them.

  • title is used for logging purposes, to indicate when clicking an element has succeeded.

  • iframe is used to specify if the following css_selector or xpath will resolve to an iframe, which should thusly be focused on (review Selenium’s API for focusing on an iframe).

  • xpath is used to specify the xpath for resolving an element to be clicked.

  • css_selector is used to specify the CSS selector for resolving an element to be clicked.

Metadata

Release files for fsubot 0.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fsubot 0.4.1
File Size Uploaded Provenance Actions
fsubot-0.4.1.tar.gz 7.1 kB Without provenance Details for fsubot-0.4.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for fsubot 0.4.1
File Interpreter ABI Platform Actions
fsubot-0.4.1-py3-none-any.whl Python 3 none any Details for fsubot-0.4.1-py3-none-any.whl

Total release size: 15.7 kB

Release files / fsubot-0.4.1.tar.gz

Download URL fsubot-0.4.1.tar.gz
Size 7.1 kB
Tags Source
SHA-256 checksum
How to use checksums
a2ac8d2a10d76eeee28e7a68a6437da2ee242e2d2a1668d1063fc3c20d758999
BLAKE2b-256 checksum
How to use checksums
5de8bdb145c26ccca9860957acaccceba616024b9f44b745a152706019ecfbc6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / fsubot-0.4.1-py3-none-any.whl

Download URL fsubot-0.4.1-py3-none-any.whl
Size 8.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
82de77136957d74b29255431f8c6b8c818715b304b3a5f10a96243d8071ac2ae
BLAKE2b-256 checksum
How to use checksums
a6a5b373881ce30e40abda1545ed12975fff3193b5ec6b664874372e438944c9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for fsubot 0.4.1

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page