Metadata-Version: 1.1
Name: attrs-sqlalchemy
Version: 0.1.0
Summary: Add dunder-methods to SQLAlchemy models with attrs
Home-page: https://github.com/GoodRx/attrs_sqlalchemy
Author: Andy Freeland
Author-email: andy@goodrx.com
License: MIT
Description: ================
        attrs_sqlalchemy
        ================
        
        .. image:: https://travis-ci.org/GoodRx/attrs_sqlalchemy.svg?branch=master
           :target: https://travis-ci.org/GoodRx/attrs_sqlalchemy
           :alt: CI status
        
        Use `attrs <https://attrs.readthedocs.io>`_ to add ``__repr__``, ``__eq__``,
        ``__cmp__``, and ``__hash__`` methods according to the fields on a SQLAlchemy
        model class.
        
        .. code-block:: python
        
           from attrs_sqlalchemy import attrs_sqlalchemy
        
           @attrs_sqlalchemy
           class MyModel(Base):
               __tablename__ = 'mymodel'
        
               id = sa.Column(Integer, primary_key=True)
               text = sa.Column(sa.String)
        
           instance = MyModel(id=1, text='hello')
           same_data = MyModel(id=1, text='hello')
           same_pk = MyModel(id=1, text='world')
        
           assert instance == same_data
           assert instance != same_pk
           assert repr(instance) == "MyModel(id=1, text='hello')"
        
Platform: UNKNOWN
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Intended Audience :: Developers
Classifier: Natural Language :: English
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Software Development :: Libraries :: Python Modules
