ransacklib 0.1.11__tar.gz → 1.0.0__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.

Potentially problematic release.


This version of ransacklib might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ransacklib
3
- Version: 0.1.11
3
+ Version: 1.0.0
4
4
  Summary: A modern, extensible language for manipulation with structured data
5
5
  Author-email: "Rajmund H. Hruška" <rajmund.hruska@cesnet.cz>
6
6
  License-Expression: MIT
@@ -23,6 +23,8 @@ Requires-Dist: sphinx; extra == "dev"
23
23
  Requires-Dist: sphinx_rtd_theme; extra == "dev"
24
24
  Requires-Dist: mypy; extra == "dev"
25
25
  Requires-Dist: ruff; extra == "dev"
26
+ Requires-Dist: build; extra == "dev"
27
+ Requires-Dist: twine; extra == "dev"
26
28
  Dynamic: license-file
27
29
 
28
30
  Welcome to ransack
@@ -31,6 +31,8 @@ dev = [
31
31
  "sphinx_rtd_theme",
32
32
  "mypy",
33
33
  "ruff",
34
+ "build",
35
+ "twine",
34
36
  ]
35
37
 
36
38
  [project.urls]
@@ -2,7 +2,7 @@ from .exceptions import EvaluationError, ParseError, RansackError, ShapeError
2
2
  from .parser import Parser
3
3
  from .transformer import Filter, get_values
4
4
 
5
- __version__ = "0.1.11"
5
+ __version__ = "1.0.0"
6
6
 
7
7
  __all__ = (
8
8
  "EvaluationError",
@@ -112,7 +112,7 @@ class Parser:
112
112
  DATE.2: /[0-9]{4}-[0-9]{2}-[0-9]{2}/
113
113
  TIME.2: /[0-9]{2}:[0-9]{2}:[0-9]{2}(?:\.[0-9]+)?(?:[Zz]|(?:[+-][0-9]{2}:[0-9]{2}))?/
114
114
  TIMEDELTA.2: /([0-9]+[D|d])?[0-9]{2}:[0-9]{2}:[0-9]{2}/
115
- STRING: /"([^"]+)"|\'([^\']+)\'/
115
+ STRING: /"([^"]*)"|\'([^\']*)\'/
116
116
  VARIABLE: /\.?[_a-zA-Z][-_a-zA-Z0-9]*(?:\.?[_a-zA-Z][-_a-zA-Z0-9]*)*/
117
117
  FUNCTION.2: /[_a-zA-Z][_a-zA-Z0-9]*\(/
118
118
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ransacklib
3
- Version: 0.1.11
3
+ Version: 1.0.0
4
4
  Summary: A modern, extensible language for manipulation with structured data
5
5
  Author-email: "Rajmund H. Hruška" <rajmund.hruska@cesnet.cz>
6
6
  License-Expression: MIT
@@ -23,6 +23,8 @@ Requires-Dist: sphinx; extra == "dev"
23
23
  Requires-Dist: sphinx_rtd_theme; extra == "dev"
24
24
  Requires-Dist: mypy; extra == "dev"
25
25
  Requires-Dist: ruff; extra == "dev"
26
+ Requires-Dist: build; extra == "dev"
27
+ Requires-Dist: twine; extra == "dev"
26
28
  Dynamic: license-file
27
29
 
28
30
  Welcome to ransack
@@ -8,3 +8,5 @@ sphinx
8
8
  sphinx_rtd_theme
9
9
  mypy
10
10
  ruff
11
+ build
12
+ twine
@@ -326,6 +326,14 @@ def test_string_with_special_chars(parser):
326
326
  assert "string" in tree.pretty()
327
327
  assert special_input in tree.pretty()
328
328
 
329
+ # Test empty strings
330
+ def test_string_empty(parser):
331
+ tree = parser.parse_only('""')
332
+ assert tree is not None
333
+ assert "string" in tree.pretty()
334
+ tree = parser.parse_only("''")
335
+ assert tree is not None
336
+ assert "string" in tree.pretty()
329
337
 
330
338
  # Test for strings in a larger expression (within arithmetic expression)
331
339
  def test_string_in_expression(parser):
File without changes
File without changes
File without changes
File without changes