Skip to content

Commit 932914e

Browse files
committed
renamed SQLAlchemy file into store (lower case)
flake8 compatibility, formatting, using six for python 2/3 compatibility some more grouping and sorting of imports remove deprecated pip --use-mirrors flag add setuptools to requirements-py{2,3}.txt files for travis ci change all quotes from single to double in unit-test files to use a single convention updated all single quotes to double quotes in code alphabetize and group imports final round
1 parent 4ee1791 commit 932914e

20 files changed

+495
-436
lines changed

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ python:
1515
- 3.4
1616
- 3.5
1717
install:
18-
- if [[ ${TRAVIS_PYTHON_VERSION%%.*} == '2' ]]; then pip install -r requirements-py2.txt --use-mirrors; fi
19-
- if [[ ${TRAVIS_PYTHON_VERSION%%.*} == '3' ]]; then pip install -r requirements-py3.txt --use-mirrors; fi
18+
- if [[ ${TRAVIS_PYTHON_VERSION%%.*} == '2' ]]; then pip install -r requirements-py2.txt; fi
19+
- if [[ ${TRAVIS_PYTHON_VERSION%%.*} == '3' ]]; then pip install -r requirements-py3.txt; fi
2020
- python setup.py install
2121
before_script:
2222
- sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'DROP DATABASE IF EXISTS test;' -U postgres; psql -c 'create database test;' -U postgres; export DBURI='postgresql+psycopg2://postgres@localhost/test'; fi"

rdflib_sqlalchemy/__init__.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
# -*- coding: utf-8 -*-
22
"""SQLAlchemy Store plugin for RDFLib."""
33
import logging
4+
5+
46
__author__ = "Graham Higgins"
57
__version__ = "0.3"
68

79

810
class NullHandler(logging.Handler):
9-
r"""
11+
"""
1012
Null handler.
1113
1214
c.f.
@@ -41,7 +43,7 @@ def registerplugins():
4143
from rdflib import plugin
4244

4345
try:
44-
x = plugin.get('SQLAlchemy', Store)
46+
x = plugin.get("SQLAlchemy", Store)
4547
del x
4648
return # plugins already registered
4749
except:
@@ -50,5 +52,8 @@ def registerplugins():
5052
# Register the plugins ...
5153

5254
plugin.register(
53-
'SQLAlchemy', Store,
54-
'rdflib_sqlalchemy.SQLAlchemy', 'SQLAlchemy')
55+
"SQLAlchemy",
56+
Store,
57+
"rdflib_sqlalchemy.store",
58+
"SQLAlchemy",
59+
)

0 commit comments

Comments
 (0)