Personal tools
Skip to content. | Skip to navigation
Unlike other datetime libraries for Python, Pendulum is a drop-in replacement for the standard datetime class (it inherits from it), so, basically, you can replace all your datetime instances by DateTime instances in you code. It also removes the notion of naive datetimes: each Pendulum instance is timezone-aware and by default in UTC for ease of use.
Python DB-API and SQLAlchemy dialect for Pinot This module allows accessing Pinot via its SQL API. Current supported Pinot version: 1.1.0. Usage Using the DB API to query Pinot Broker directly: from pinotdb import connect conn = connect(host='localhost', port=8000, path='/query/sql', scheme='http') curs = conn.cursor() curs.execute(""" SELECT place, CAST(REGEXP_EXTRACT(place, '(.*),', 1) AS FLOAT) AS lat, CAST(REGEXP_EXTRACT(place, ',(.*)', 1) AS FLOAT) AS lon FROM places LIMIT 10 """) for row in curs: print(row) For HTTPS: from pinotdb import connect conn = connect(host='localhost', port=443, path='/query/sql', scheme='https') curs = conn.cursor() curs.execute(""" SELECT place, CAST(REGEXP_EXTRACT(place, '(.*),', 1) AS FLOAT) AS lat, CAST(REGEXP_EXTRACT(place, ',(.*)', 1) AS FLOAT) AS lon FROM places LIMIT 10 ""
.. image::
Pockets full of useful Python tools! *Let me check my pockets...* -The Pockets library pulls together many of the Python helper functions I've found useful over the years.If you've worked on a project that exports an API and accesses a data store, you've probably seen some code that looks like this:: Receive a data type with underscores from some API data_type 'user_preference' Convert...
polib allows you to manipulate, create, modify gettext files (pot, po and mo files). You can load existing files, iterate through it's entries, add, modify entries, comments or metadata, etc... or create new po files from scratch. polib provides a simple and pythonic API, exporting only three convenience functions 'pofile', 'mofile' and 'detect_encoding', and the 4 core classes: POFile, MOFile, POEntry and MOEntry for creating new files/entries.
Python 3 bindings for the Poppler PDF rendering library. It is needed to run programs written in Python 3 and using Poppler set.
[, a distributed SQL engine for interactive and batch big data processing. Provides a low-level client and a DBAPI 2.0 implementation.
Pretend is a library to make stubbing with Python easier.