queryparser-python3 0.8.0__tar.gz → 0.8.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {queryparser_python3-0.8.0/lib/queryparser_python3.egg-info → queryparser_python3-0.8.1}/PKG-INFO +1 -1
- queryparser_python3-0.8.1/lib/queryparser/__init__.py +1 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/adqltranslator.py +10 -6
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1/lib/queryparser_python3.egg-info}/PKG-INFO +1 -1
- queryparser_python3-0.8.0/lib/queryparser/__init__.py +0 -1
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/LICENSE +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/README.md +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/ADQLLexer.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/ADQLParser.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/ADQLParserListener.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/ADQLParserVisitor.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/__init__.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/common/__init__.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/common/common.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/exceptions/__init__.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/MySQLLexer.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/MySQLParser.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/MySQLParserListener.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/__init__.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/mysqllisteners.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/mysqlprocessor.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/postgresql/PostgreSQLLexer.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/postgresql/PostgreSQLParser.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/postgresql/PostgreSQLParserListener.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/postgresql/__init__.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/postgresql/postgresqllisteners.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/postgresql/postgresqlprocessor.py +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser_python3.egg-info/SOURCES.txt +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser_python3.egg-info/dependency_links.txt +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser_python3.egg-info/requires.txt +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser_python3.egg-info/top_level.txt +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/pyproject.toml +0 -0
- {queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/setup.cfg +0 -0
{queryparser_python3-0.8.0/lib/queryparser_python3.egg-info → queryparser_python3-0.8.1}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: queryparser-python3
|
|
3
|
-
Version: 0.8.
|
|
3
|
+
Version: 0.8.1
|
|
4
4
|
Summary: Package for parsing PostgreSQL/MySQL and translating ADQL to PostgreSQL/MySQL.
|
|
5
5
|
Author-email: Kirill Makan <kmakan@aip.de>, Gal Matijevic <gmatijevic@aip.de>
|
|
6
6
|
Maintainer-email: Kirill Makan <kmakan@aip.de>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = '0.8.1'
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/adqltranslator.py
RENAMED
|
@@ -414,7 +414,7 @@ class ADQLFunctionsTranslationVisitor(ADQLParserVisitor):
|
|
|
414
414
|
self.contexts[ctx] = ctx_text
|
|
415
415
|
|
|
416
416
|
def visitComparison_predicate(self, ctx):
|
|
417
|
-
"""Rewrite DISTANCE thresholds, which require the
|
|
417
|
+
"""Rewrite equivalent DISTANCE thresholds, which require the radius.
|
|
418
418
|
|
|
419
419
|
visitDistance handles the distance function itself; this method owns
|
|
420
420
|
the surrounding operator and radius needed for spoint_dwithin.
|
|
@@ -423,15 +423,19 @@ class ADQLFunctionsTranslationVisitor(ADQLParserVisitor):
|
|
|
423
423
|
return self.visitChildren(ctx)
|
|
424
424
|
|
|
425
425
|
left, operator, right = ctx.children
|
|
426
|
-
|
|
426
|
+
distance_on_left = operator.getText() in ('<', '<=')
|
|
427
|
+
if distance_on_left:
|
|
428
|
+
distance, radius = left, right
|
|
429
|
+
elif operator.getText() in ('>', '>='):
|
|
430
|
+
distance, radius = right, left
|
|
431
|
+
else:
|
|
427
432
|
return self.visitChildren(ctx)
|
|
428
433
|
|
|
429
|
-
distance = left
|
|
430
434
|
while distance.getChildCount() == 1:
|
|
431
435
|
distance = distance.children[0]
|
|
432
436
|
if not isinstance(distance, ADQLParser.DistanceContext):
|
|
433
437
|
return self.visitChildren(ctx)
|
|
434
|
-
if 'DISTANCE' in
|
|
438
|
+
if 'DISTANCE' in radius.getText().upper():
|
|
435
439
|
return self.visitChildren(ctx)
|
|
436
440
|
|
|
437
441
|
ancestor = ctx.parentCtx
|
|
@@ -442,8 +446,8 @@ class ADQLFunctionsTranslationVisitor(ADQLParserVisitor):
|
|
|
442
446
|
if ancestor is None:
|
|
443
447
|
return self.visitChildren(ctx)
|
|
444
448
|
|
|
445
|
-
_remove_children(ctx)
|
|
446
|
-
self.visitDistance(distance,
|
|
449
|
+
_remove_children(ctx, reverse=not distance_on_left)
|
|
450
|
+
self.visitDistance(distance, radius.getText())
|
|
447
451
|
|
|
448
452
|
def visitDistance(self, ctx, dwithin_radius=None):
|
|
449
453
|
arg = ('', '')
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1/lib/queryparser_python3.egg-info}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: queryparser-python3
|
|
3
|
-
Version: 0.8.
|
|
3
|
+
Version: 0.8.1
|
|
4
4
|
Summary: Package for parsing PostgreSQL/MySQL and translating ADQL to PostgreSQL/MySQL.
|
|
5
5
|
Author-email: Kirill Makan <kmakan@aip.de>, Gal Matijevic <gmatijevic@aip.de>
|
|
6
6
|
Maintainer-email: Kirill Makan <kmakan@aip.de>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = '0.8.0'
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/ADQLParserListener.py
RENAMED
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/adql/ADQLParserVisitor.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/exceptions/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/MySQLParser.py
RENAMED
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/MySQLParserListener.py
RENAMED
|
File without changes
|
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/mysqllisteners.py
RENAMED
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/mysql/mysqlprocessor.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser/postgresql/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{queryparser_python3-0.8.0 → queryparser_python3-0.8.1}/lib/queryparser_python3.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|