Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

motor-types

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

motor-types

Python stubs for Motor, a Non-Blocking MongoDB driver for Python's Tornado and AsyncIO based applications.

  • 1.0.0b4
  • PyPI
  • Socket score

Maintainers
1

Motor-Types

Python stubs for Motor, a Non-Blocking MongoDB driver for Python's Tornado and AsyncIO based applications.

About

Stubs for Motor (version 3.0.0+) for substituting the missing type-hints. These stubs are meant to be used along with pycharm and mypy to facilitate static type-checking. Installing this package adds these .pyi files to libs/site-packages/motor. Currently, only the stubs for AsyncIO are supported. You can contribute to stubs for Tornado by opening a pull request for the same.

Note: This project is currently under development and is in no way affiliated with MongoDB. This is an unofficial stub package.

How to use?

You can either install from PyPI using pip or add files to your project directories manually.

Installing Using pip:

pip install motor-types

To install Motor (and Dnspython) alongside the package:

pip install motor-types[motor]

To add files to the project manually:

Use this command to clone the repository:

git clone "https://github.com/L0RD-ZER0/Motor-Types"

Afterwards, you can do either of the following to use stubs:

  • Copy the stubs manually to either libs/site-packages/motor or libs/site-packages/motor-stubs, ideally the latter.
  • Add these stubs manually to project directories.
    • For MyPy.
    • For PyCharm.
    • For other static type-checking tools, consider referring to their corresponding documentation regarding stubs.

Examples:

Auto-Complete Example

Without Stubs:

ACNS

With Stubs:

ACWS

Type-Checking Example

Without Stubs:

TCNS

With Stubs:

TCWS

Dependencies

This package uses following dependencies:

How to Contribute?

The simplest contribution you can make is by opening a GitHub Issue or by forking the repository and making a pull request on the GitHub Repository for the same. The changes can be as simple as improving the documentation or as big as completing any incomplete section of the typings.

Note: All issues and pull-requests are subjected to a preliminary inspection.

License

This repository is licensed under MIT License. The license can be found within the repository.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc