/UsernameChecker

Minecraft username checker with Webdriver and NameMC

Primary LanguagePythonGNU General Public License v3.0GPL-3.0

Build Status GNU License Release Version Custom

Username Finder

Table of Contents

About

Built With

This project was created with Python 3 and is PEP 8 compatible as of November 26th, 2019.

This repository was built by PyCharm Community Edition and maintained by Hayden977.

Getting Started

Prerequisites

As of November 26th, 2019, the only external prerequisite is selenium and the accompanying browser drivers. See Installation for more detail.

pip install selenium

Installation

The browser drivers can be found on the PyPI page. From the webpage, popular browser drivers are:

Browser Download Link
Chrome https://sites.google.com/a/chromium.org/chromedriver/downloads
Edge https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/
Firefox https://github.com/mozilla/geckodriver/releases
Safari https://webkit.org/blog/6900/webdriver-support-in-safari-10/

Note: if the browser driver is not in the PATH variable, the _PATH variable will need to be set to the path of the driver.

Usage

As of November 26th, 2019, running main.py will result in the following input field.

Username(s): 

This field will accept a single username or a list of usernames separated by commas and spaces. Invalid usernames (see Exceptions below) should be caught before a query is executed.

Exceptions

From Mojang, usernames must obey by the following rules:

  • Must be between 3-16 characters in length
  • Characters from A-Z (upper and lowercase) are allowed
  • Characters from 0-9 are allowed
  • The only special character allowed is _ (underscore)
    • Spaces are not allowed
    • All other characters are not allowed

Examples of valid input, followed by examples of invalid inputs, are shown below.

VALID INPUTS
Username(s): Python123
Username(s): Python123, Python456

INVALID INPUTS
Username(s): Space Character
Username(s): TwentyCharacterNames
Username(s): 2c
Username(s): русский

Contributing

The Username Finder is currently hindered by the limitations of selenium. Designed as an application tester, it needs to load all elements of a page first. This results in much slower query rates, and downtime for the program. This downtime could be taken advantage of by a library like beautifulsoup4, which can read the source of the page instead of rendering the full site. This will likely bring the query rate down from 20 seconds to 5 seconds, which will allow the following Features to be implemented.

Features

  • CSV support
  • Find all available usernames of length n
  • Username 'sniping'
  • Full Mojang API support

TODO

  • Implement beautifulsoup4 or an alternative
  • Improve general performance
  • Improve code readability
    • Remove redundant exception handlers
    • Ensure PEP 8 compatibility

License

Released under the GNU GPL v3 license.

This project is not affiliated with NameMC.

Contact

Maintained by Hayden977.

Acknowledgements