gremlinpython 3.8.0__tar.gz → 3.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.
Files changed (43) hide show
  1. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/MANIFEST.in +1 -1
  2. gremlinpython-3.8.1/NOTICE +5 -0
  3. {gremlinpython-3.8.0/gremlinpython.egg-info → gremlinpython-3.8.1}/PKG-INFO +2 -1
  4. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/__init__.py +2 -2
  5. {gremlinpython-3.8.0/gremlin_python/process → gremlinpython-3.8.1/gremlin_python/driver}/__init__.py +1 -1
  6. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/aiohttp/__init__.py +1 -1
  7. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/aiohttp/transport.py +1 -1
  8. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/client.py +1 -1
  9. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/connection.py +1 -1
  10. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/driver_remote_connection.py +1 -1
  11. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/protocol.py +1 -1
  12. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/remote_connection.py +1 -1
  13. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/request.py +1 -1
  14. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/resultset.py +1 -1
  15. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/serializer.py +1 -1
  16. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/transport.py +3 -3
  17. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/driver/useragent.py +2 -2
  18. {gremlinpython-3.8.0/gremlin_python/driver → gremlinpython-3.8.1/gremlin_python/process}/__init__.py +1 -1
  19. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/process/anonymous_traversal.py +1 -1
  20. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/process/graph_traversal.py +1 -1
  21. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/process/strategies.py +1 -1
  22. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/process/translator.py +1 -1
  23. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/process/traversal.py +1 -1
  24. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/statics.py +1 -1
  25. {gremlinpython-3.8.0/gremlin_python/structure/io → gremlinpython-3.8.1/gremlin_python/structure}/__init__.py +3 -3
  26. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/structure/graph.py +3 -3
  27. {gremlinpython-3.8.0/gremlin_python/structure → gremlinpython-3.8.1/gremlin_python/structure/io}/__init__.py +3 -3
  28. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/structure/io/graphbinaryV1.py +8 -2
  29. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/structure/io/graphsonV2d0.py +3 -3
  30. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/structure/io/graphsonV3d0.py +13 -4
  31. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlin_python/structure/io/util.py +1 -1
  32. {gremlinpython-3.8.0 → gremlinpython-3.8.1/gremlinpython.egg-info}/PKG-INFO +2 -1
  33. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlinpython.egg-info/SOURCES.txt +1 -3
  34. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlinpython.egg-info/requires.txt +1 -0
  35. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/pyproject.toml +3 -2
  36. gremlinpython-3.8.0/NOTICE +0 -5
  37. gremlinpython-3.8.0/gremlin_python/__version__.py +0 -20
  38. gremlinpython-3.8.0/tests/test_statics.py +0 -83
  39. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/LICENSE +0 -0
  40. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/README.rst +0 -0
  41. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlinpython.egg-info/dependency_links.txt +0 -0
  42. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/gremlinpython.egg-info/top_level.txt +0 -0
  43. {gremlinpython-3.8.0 → gremlinpython-3.8.1}/setup.cfg +0 -0
@@ -6,7 +6,7 @@
6
6
  # "License"); you may not use this file except in compliance
7
7
  # with the License. You may obtain a copy of the License at
8
8
  #
9
- # http://www.apache.org/licenses/LICENSE-2.0
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
10
  #
11
11
  # Unless required by applicable law or agreed to in writing,
12
12
  # software distributed under the License is distributed on an
@@ -0,0 +1,5 @@
1
+ Apache TinkerPop
2
+ Copyright 2015-2026 The Apache Software Foundation.
3
+
4
+ This product includes software developed at
5
+ The Apache Software Foundation (http://www.apache.org/).
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gremlinpython
3
- Version: 3.8.0
3
+ Version: 3.8.1
4
4
  Summary: Gremlin-Python for Apache TinkerPop
5
5
  Maintainer-email: Apache TinkerPop <dev@tinkerpop.apache.org>
6
6
  License: Apache 2
@@ -25,6 +25,7 @@ Requires-Dist: ujson>=2.0.0; extra == "ujson"
25
25
  Provides-Extra: test
26
26
  Requires-Dist: pytest<8.0.0,>=6.2.5; extra == "test"
27
27
  Requires-Dist: radish-bdd==0.18.2; extra == "test"
28
+ Requires-Dist: lxml==5.3.0; extra == "test"
28
29
  Requires-Dist: PyHamcrest<3.0.0,>=1.9.0; extra == "test"
29
30
  Requires-Dist: PyYAML>=5.3; extra == "test"
30
31
  Dynamic: license-file
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -18,4 +18,4 @@
18
18
  #
19
19
 
20
20
  __author__ = 'Marko A. Rodriguez (http://markorodriguez.com)'
21
- __version__ = '3.8.0'
21
+ __version__ = '3.8.1'
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -6,7 +6,7 @@
6
6
  # "License"); you may not use this file except in compliance
7
7
  # with the License. You may obtain a copy of the License at
8
8
  #
9
- # http://www.apache.org/licenses/LICENSE-2.0
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
10
  #
11
11
  # Unless required by applicable law or agreed to in writing,
12
12
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -6,9 +6,9 @@
6
6
  # to you under the Apache License, Version 2.0 (the
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
14
14
  # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -18,7 +18,7 @@
18
18
  #
19
19
  import platform
20
20
 
21
- gremlin_version = "3.8.0" # DO NOT MODIFY - Configured automatically by Maven Replacer Plugin
21
+ gremlin_version = "3.8.1" # DO NOT MODIFY - Configured automatically by Maven Replacer Plugin
22
22
 
23
23
  def _generate_user_agent():
24
24
  application_name = "NotAvailable"
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -7,7 +7,7 @@
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
9
  #
10
- # http://www.apache.org/licenses/LICENSE-2.0
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
11
  #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
@@ -6,9 +6,9 @@
6
6
  # to you under the Apache License, Version 2.0 (the
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
14
14
  # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -6,9 +6,9 @@
6
6
  # to you under the Apache License, Version 2.0 (the
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
14
14
  # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -6,9 +6,9 @@
6
6
  # to you under the Apache License, Version 2.0 (the
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
14
14
  # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -7,7 +7,7 @@ to you under the Apache License, Version 2.0 (the
7
7
  "License"); you may not use this file except in compliance
8
8
  with the License. You may obtain a copy of the License at
9
9
 
10
- http://www.apache.org/licenses/LICENSE-2.0
10
+ http://www.apache.org/licenses/LICENSE-2.0
11
11
 
12
12
  Unless required by applicable law or agreed to in writing,
13
13
  software distributed under the License is distributed on an
@@ -559,7 +559,13 @@ class SetDeserializer(ListIO):
559
559
 
560
560
  @classmethod
561
561
  def objectify(cls, buff, reader, nullable=True):
562
- return set(ListIO.objectify(buff, reader, nullable))
562
+ the_list = ListIO.objectify(buff, reader, nullable)
563
+ try:
564
+ return set(the_list)
565
+ except TypeError:
566
+ log.warning("Coercing Set to list as it contains unhashable elements (e.g. dict, list). "
567
+ "See TINKERPOP-3232 for more details.")
568
+ return the_list
563
569
 
564
570
 
565
571
  class MapIO(_GraphBinaryTypeIO):
@@ -6,9 +6,9 @@
6
6
  # to you under the Apache License, Version 2.0 (the
7
7
  # "License"); you may not use this file except in compliance
8
8
  # with the License. You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
12
  # Unless required by applicable law or agreed to in writing,
13
13
  # software distributed under the License is distributed on an
14
14
  # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -5,9 +5,9 @@
5
5
  # to you under the Apache License, Version 2.0 (the
6
6
  # "License"); you may not use this file except in compliance
7
7
  # with the License. You may obtain a copy of the License at
8
- #
9
- # http://www.apache.org/licenses/LICENSE-2.0
10
- #
8
+ #
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
11
  # Unless required by applicable law or agreed to in writing,
12
12
  # software distributed under the License is distributed on an
13
13
  # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -458,9 +458,18 @@ class SetIO(_GraphSONTypeIO):
458
458
  In case Java returns numeric values of different types which
459
459
  python don't recognize, coerce and return a list.
460
460
  See comments of TINKERPOP-1844 for more details
461
+
462
+ In case the set contains non-hashable elements (e.g. dict, list),
463
+ coerce and return a list.
464
+ See TINKERPOP-3232 for more details
461
465
  """
462
466
  new_list = [reader.to_object(obj) for obj in s]
463
- new_set = set(new_list)
467
+ try:
468
+ new_set = set(new_list)
469
+ except TypeError:
470
+ log.warning("Coercing g:Set to list as it contains unhashable elements (e.g. dict, list). "
471
+ "See TINKERPOP-3232 for more details.")
472
+ return new_list
464
473
  if len(new_list) != len(new_set):
465
474
  log.warning("Coercing g:Set to list due to java numeric values. "
466
475
  "See TINKERPOP-1844 for more details.")
@@ -6,7 +6,7 @@
6
6
  # "License"); you may not use this file except in compliance
7
7
  # with the License. You may obtain a copy of the License at
8
8
  #
9
- # http://www.apache.org/licenses/LICENSE-2.0
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
10
  #
11
11
  # Unless required by applicable law or agreed to in writing,
12
12
  # software distributed under the License is distributed on an
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gremlinpython
3
- Version: 3.8.0
3
+ Version: 3.8.1
4
4
  Summary: Gremlin-Python for Apache TinkerPop
5
5
  Maintainer-email: Apache TinkerPop <dev@tinkerpop.apache.org>
6
6
  License: Apache 2
@@ -25,6 +25,7 @@ Requires-Dist: ujson>=2.0.0; extra == "ujson"
25
25
  Provides-Extra: test
26
26
  Requires-Dist: pytest<8.0.0,>=6.2.5; extra == "test"
27
27
  Requires-Dist: radish-bdd==0.18.2; extra == "test"
28
+ Requires-Dist: lxml==5.3.0; extra == "test"
28
29
  Requires-Dist: PyHamcrest<3.0.0,>=1.9.0; extra == "test"
29
30
  Requires-Dist: PyYAML>=5.3; extra == "test"
30
31
  Dynamic: license-file
@@ -4,7 +4,6 @@ NOTICE
4
4
  README.rst
5
5
  pyproject.toml
6
6
  gremlin_python/__init__.py
7
- gremlin_python/__version__.py
8
7
  gremlin_python/statics.py
9
8
  gremlin_python/driver/__init__.py
10
9
  gremlin_python/driver/client.py
@@ -36,5 +35,4 @@ gremlinpython.egg-info/PKG-INFO
36
35
  gremlinpython.egg-info/SOURCES.txt
37
36
  gremlinpython.egg-info/dependency_links.txt
38
37
  gremlinpython.egg-info/requires.txt
39
- gremlinpython.egg-info/top_level.txt
40
- tests/test_statics.py
38
+ gremlinpython.egg-info/top_level.txt
@@ -10,6 +10,7 @@ kerberos<2.0.0,>=1.3.0
10
10
  [test]
11
11
  pytest<8.0.0,>=6.2.5
12
12
  radish-bdd==0.18.2
13
+ lxml==5.3.0
13
14
  PyHamcrest<3.0.0,>=1.9.0
14
15
  PyYAML>=5.3
15
16
 
@@ -6,7 +6,7 @@
6
6
  # "License"); you may not use this file except in compliance
7
7
  # with the License. You may obtain a copy of the License at
8
8
  #
9
- # http://www.apache.org/licenses/LICENSE-2.0
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
10
  #
11
11
  # Unless required by applicable law or agreed to in writing,
12
12
  # software distributed under the License is distributed on an
@@ -50,6 +50,7 @@ ujson = ["ujson>=2.0.0"]
50
50
  test = [
51
51
  "pytest>=6.2.5,<8.0.0",
52
52
  "radish-bdd==0.18.2",
53
+ "lxml==5.3.0",
53
54
  "PyHamcrest>=1.9.0,<3.0.0",
54
55
  "PyYAML>=5.3"
55
56
  ]
@@ -57,7 +58,7 @@ test = [
57
58
  [tool.pytest.ini_options]
58
59
  addopts = "--junitxml=./python-reports/TEST-native-python.xml -sv"
59
60
  norecursedirs = [".*", "build", "dist", "CVS", "_darcs", "{arch}", "*.egg", "lib", "lib64"]
60
- testpaths = ["tests"]
61
+ testpaths = ["tests/unit","tests/integration"]
61
62
 
62
63
  [tool.setuptools.dynamic]
63
64
  version = {attr = "gremlin_python.__version__"}
@@ -1,5 +0,0 @@
1
- Apache TinkerPop
2
- Copyright 2015-2025 The Apache Software Foundation.
3
-
4
- This product includes software developed at
5
- The Apache Software Foundation (http://www.apache.org/).
@@ -1,20 +0,0 @@
1
- '''
2
- Licensed to the Apache Software Foundation (ASF) under one
3
- or more contributor license agreements. See the NOTICE file
4
- distributed with this work for additional information
5
- regarding copyright ownership. The ASF licenses this file
6
- to you under the Apache License, Version 2.0 (the
7
- "License"); you may not use this file except in compliance
8
- with the License. You may obtain a copy of the License at
9
-
10
- http://www.apache.org/licenses/LICENSE-2.0
11
-
12
- Unless required by applicable law or agreed to in writing,
13
- software distributed under the License is distributed on an
14
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15
- KIND, either express or implied. See the License for the
16
- specific language governing permissions and limitations
17
- under the License.
18
- '''
19
- version = '?'
20
- timestamp = 1739570012
@@ -1,83 +0,0 @@
1
- #
2
- # Licensed to the Apache Software Foundation (ASF) under one
3
- # or more contributor license agreements. See the NOTICE file
4
- # distributed with this work for additional information
5
- # regarding copyright ownership. The ASF licenses this file
6
- # to you under the Apache License, Version 2.0 (the
7
- # "License"); you may not use this file except in compliance
8
- # with the License. You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
12
- # Unless required by applicable law or agreed to in writing,
13
- # software distributed under the License is distributed on an
14
- # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15
- # KIND, either express or implied. See the License for the
16
- # specific language governing permissions and limitations
17
- # under the License.
18
- #
19
-
20
- __author__ = 'Marko A. Rodriguez (http://markorodriguez.com)'
21
-
22
- from decimal import Decimal
23
-
24
- from gremlin_python import statics
25
- from gremlin_python.process.traversal import Cardinality
26
- from gremlin_python.process.traversal import P
27
- from gremlin_python.process.traversal import Pop
28
-
29
-
30
- class TestStatics(object):
31
- def test_enums(self):
32
- statics.load_statics(globals())
33
- assert isinstance(list_, Cardinality)
34
- assert list_ is Cardinality.list_
35
- #
36
- assert isinstance(eq(2), P)
37
- assert eq(2) == P.eq(2)
38
- #
39
- assert isinstance(first, Pop)
40
- assert first == Pop.first
41
- statics.unload_statics(globals())
42
-
43
- def test_singlebyte(self):
44
- assert -128 == statics.SingleByte(-128)
45
- assert 1 == statics.SingleByte(1)
46
- assert 127 == statics.SingleByte(127)
47
- try:
48
- statics.SingleByte(128)
49
- raise Exception("SingleByte should throw a value error if input is larger than 127")
50
- except ValueError:
51
- pass
52
-
53
- try:
54
- statics.SingleByte(-129)
55
- raise Exception("SingleByte should throw a value error if input is smaller than -128")
56
- except ValueError:
57
- pass
58
-
59
- def test_singlechar(self):
60
- assert 'a' == statics.SingleChar('a')
61
- assert chr(76) == statics.SingleChar(chr(76))
62
- assert chr(57344) == statics.SingleChar(chr(57344))
63
- try:
64
- statics.SingleChar('abc')
65
- raise Exception("SingleChar should throw a value error if input is not a single character string")
66
- except ValueError:
67
- pass
68
-
69
- def test_bigdecimal(self):
70
- assert statics.bigdecimal(1.23456).value == statics.BigDecimal(5,123456).value
71
- assert statics.bigdecimal(-1.23456).value == statics.BigDecimal(5,-123456).value
72
- # make sure the precision isn't changed globally
73
- assert Decimal("123456789").scaleb(-5) == Decimal('1234.56789')
74
- try:
75
- statics.bigdecimal('NaN')
76
- raise Exception("to_bigdecimal should throw a value error with NaN, Infinity or -Infinity")
77
- except ValueError:
78
- pass
79
- try:
80
- statics.bigdecimal('abc')
81
- raise Exception("to_bigdecimal should throw a value error if input is not a convertable to Decimal")
82
- except ValueError:
83
- pass
File without changes
File without changes
File without changes