Skip to content

Commit 45c1f59

Browse files
committed
Cleaned up some unused imports.
1 parent 54fabc7 commit 45c1f59

4 files changed

Lines changed: 5 additions & 18 deletions

File tree

sqlparse/__init__.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@
99
__version__ = '0.1.1'
1010

1111

12-
import os
13-
14-
1512
class SQLParseError(Exception):
1613
"""Base class for exceptions in this module."""
1714

sqlparse/engine/__init__.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@
55

66
"""filter"""
77

8-
import re
9-
10-
from sqlparse import lexer, SQLParseError
8+
from sqlparse import lexer
119
from sqlparse.engine import grouping
1210
from sqlparse.engine.filter import StatementFilter
1311

@@ -58,23 +56,23 @@ def _group(stream):
5856
stream = _group(stream)
5957

6058
if self.stmtprocess:
61-
def _run(stream):
59+
def _run1(stream):
6260
ret = []
6361
for stmt in stream:
6462
for filter_ in self.stmtprocess:
6563
filter_.process(self, stmt)
6664
ret.append(stmt)
6765
return ret
68-
stream = _run(stream)
66+
stream = _run1(stream)
6967

7068
if self.postprocess:
71-
def _run(stream):
69+
def _run2(stream):
7270
for stmt in stream:
7371
stmt.tokens = list(self._flatten(stmt.tokens))
7472
for filter_ in self.postprocess:
7573
stmt = filter_.process(self, stmt)
7674
yield stmt
77-
stream = _run(stream)
75+
stream = _run2(stream)
7876

7977
return stream
8078

sqlparse/engine/grouping.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,11 @@
11
# -*- coding: utf-8 -*-
22

33
import itertools
4-
import re
5-
import types
64

75
from sqlparse import tokens as T
86
from sqlparse.sql import *
97

108

11-
129
def _group_left_right(tlist, ttype, value, cls,
1310
check_right=lambda t: True,
1411
check_left = lambda t: True,

sqlparse/tokens.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,6 @@
99

1010
"""Tokens"""
1111

12-
try:
13-
set
14-
except NameError:
15-
from sets import Set as set
16-
1712

1813
class _TokenType(tuple):
1914
parent = None

0 commit comments

Comments
 (0)