semvec/pypi-packages huggingface dataset:
easydb 0.2
Simple SQLite wrapper to make it easier to manage your database
License: MIT
Keywords: db database sqlite

# EasyDB

A really simple **SQLite wrapper** that saves you from having to worry about creating tables or managing connections.

It can be used on existing SQLite database by simply passing in the database filename:

```python
from easydb import EasyDB
db = EasyDB('filename.db')
cursor = db.query("SELECT * FROM mytable")
```

New databases can be creating by specifying your schema as a dictionary, eg:

```python
schema = {
    'table_name': ['column_name column_type', …],
    'table_name': ['column_name column_type', …],
    'table_name': ['column_name column_type', …]
}
db = EasyDB('filename.db', schema)
```

If the database file already exists then the schema won't be updated, but if it doesn't exist then it'll be created with the given schema. Here's a full example:

```python
from easydb import EasyDB
db = EasyDB('my.db', {'users': ['username text', 'description text']})

db.query("INSERT INTO users (username, description) VALUES (?, ?)", ('ben', 'some sort of description'))

for result in db.query("SELECT * FROM users"):
    print result
# => ('ben', 'some sort of description')
```
diabric 0.2.0
Diabolically atomic Python Fabric fabfile tasks and utilities.
License: MIT
Keywords: fabric fabfile boto ec2 virtualenv python wsgi webapp deployment

# Introduction

Diabric is a python package containing utilities for use in Fabric fabfiles.
These tasks, functions, and classes are useful for:

- working with Amazon EC2
- configuring machines
- installing, configuring, and starting services, servers, and daemons, like
  nginx and supervisord.
- deploying python wsgi web applications.
- uploading and formatting files
- creating python virtualenv virtual environments
- installing packages into virtualenvs
- configuring fabfiles

  
This package is still very much _alpha_ and exists to reduce code duplication
across a number of fabfiles I have for different projects.

# Requirements

- Written with Python 2.7 
(http://python.org/download/releases/2.7.3/) in mind.  
- Packaged with distutils2 (http://packages.python.org/Distutils2/)
- Fabric (http://docs.fabfile.org/) for creating fabfile tasks, working with
  remote hosts, ...
- Boto (https://github.com/boto/boto) for interacting with EC2.

# Installation

## Install from pypi.python.org

Download and install diabric.

    pip install diabric

## Install from github.com

Install distutils2 if you do not yet have it installed.

    pip install distutils2

Download and install diabric.

    cd ~
    git clone git@github.com:todddeluca/diabric.git
    cd diabric
    pysetup install
dones 0.2.0
Track what keys are "done" using MySQL to implement a simple key-store.
License: MIT
Keywords: mysql keystore batch queue LSF

## Introduction

The dones module can be used to mark whether a key is "done" and check whether
a key has been marked "done".  Keys can also be unmarked, so that they are no
longer "done".  Also, all keys can be unmarked by clearing the Dones.
Keys are kept in their own namespace to avoid conflicts with other
sets of other keys and to make it easy to implement clearing.

Why?  I use `dones` to keep track of what I've already done.  More
specifically, I run large computations (a few million tasks) on a large cluster
(a few thousand cores) with a slow filesystem (Isilon).  When tasks inevitably
fail, perhaps because the network storage goes offline, or a computer dies, or
another user overwhelms the database with connections, I need to resubmit the
tasks to the batch queuing system (LSF) of the cluster that are not already
done.  

The solution in this module fits my constraints.  It handles the concurrent
writes of a thousand jobs marking things done (not all at once).  It is
reasonably fast for reading and writing up to millions of jobs.  This is
important because or batch queue (LSF) only handles a few thousand jobs at a
time gracefully.  Finally, `dones` uses MySQL as a backend, which is important
because I cannot run a key-value server like Redis on the cluster I use.


## Contribute

Feel free to make a pull request on github.


## Testing

Awkwardly, `dones` is configured with a MySQL database url from the
environment, so to test it, you need to add a url.  For example:

    DONES_DB_URL=mysql://myuser:password@localhost/mydb nosetests


## Requirements

- Probably Python 2.7 (since that is the only version it has been tested with.)
- MySQL-python PyPI package.


## Installation


### Install from pypi.python.org

Download and install using pip:

    pip install dones


### Install from github.com

Using github, one can clone and install a specific version of the package:

    cd ~
    git clone git@github.com:todddeluca/dones.git
    cd dones
    python setup.py install

Or use pip:

    pip install git+git://github.com/todddeluca/dones.git#egg=dones


## Usage


    import dones

    if not dones.get('my_pipeline').done('task1'):
        dotask('task1')
        dones.get('my_pipleline').mark('task1')
apex 0.9.10dev
Pyramid toolkit to add Velruse, Flash Messages,CSRF, ReCaptcha and Sessions
License: MIT

Apex 
====

.. image:: https://api.travis-ci.org/cd34/apex.png?branch=master
        :target: https://travis-ci.org/cd34/apex

Authentication, Form Library, I18N/L10N, Flash Message Template
(not associated with Pyramid, a Pylons project)

Uses alchemy

Authentication
--------------

Authentication has a single authentication id which can have multiple
associated credentials. A user can create a username and associate their
Facebook and Google login records with their current record and log in
with any of them. It is planned that Apex will act as an endpoint for
multi-domain multi-site installations - allowing one to associate a login
account from one domain to another.

Local authentication uses salt + BCrypt
http://codahale.com/how-to-safely-store-a-password/

Velruse is used for OpenID/OpenAuth providers and supports
  * Google
  * Facebook
  * Twitter
  * Yahoo
  * Microsoft Live
  * Bitbucket
  * Github
  * Identi.ca
  * Last.fm
  * LinkedIn
  * Any OpenID provider

Ability to overload the login form, extend the AuthUser class through
polymorphism or a Foreign Key user profile table.

Form Library
------------

WTForms is used to help those transitioning over from Django to Pyramid.

I18N/L10N
---------

Babel is used to support Internationalization and Localization.

Flash Messages
--------------

Templates and helpers for Mako and Jinja2 are included to support Flash
Messages in your application.


* apexid_from_token renamed to apex_id_from_token
* added 'add_auth' function to allow secondary authentication providers
  on a single auth_id
tailer3 0.3
Python tail is a simple implementation of GNU tail and head.
License: MIT
Keywords: tail,head

======
Tailer
======

Python tail is a simple implementation of GNU tail and head. 

It provides 3 main functions that can be performed on any file-like object that supports ``seek()`` and ``tell()``.

* ``tail`` - read lines from the end of a file
* ``head`` - read lines from the top of a file
* ``follow`` - read lines as a file grows

It also comes with ``pytail``, a command line version offering the same functionality as GNU tail. This can be particularly useful on Windows systems that have no tail equivalent.

- `Tailer on GitHub <http://github.com/six8/pytailer>`_
- `Tailer on Pypi <http://pypi.python.org/pypi/tailer>`_

Installation
============

Install with ``pip`` or ``easy_install``.

::

    pip install tailer

Examples
========

::

  import tailer
  f = open('test.txt', 'w')
  for i in range(11):
      f.write('Line %d\\n' % (i + 1))
  f.close()
    
Tail
----
::

    # Get the last 3 lines of the file
    tailer.tail(open('test.txt'), 3)
    # ['Line 9', 'Line 10', 'Line 11']

Head
----
::

    # Get the first 3 lines of the file
    tailer.head(open('test.txt'), 3)
    # ['Line 1', 'Line 2', 'Line 3']

Follow
------
::

    # Follow the file as it grows
    for line in tailer.follow(open('test.txt')):
        print line

Running Tests
=============

Tailer currently only has doctests.

Run tests with nose::

    nosetests --with-doctest src/tailer    

Run tests with doctest::

    python -m doctest -v src/tailer/__init__.py