Repository: tinkerpop
Updated Branches:
  refs/heads/master 230515947 -> 8eefb7062


Fixed issue in NumberSerializer where a 64bit integer is misidentified as 32bit

Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/5573def4
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/5573def4
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/5573def4

Branch: refs/heads/master
Commit: 5573def4a93072a79b66b3bb2e8a1727256b2d3e
Parents: 9004b4b
Author: Carlos Cheung <[email protected]>
Authored: Wed Sep 14 22:15:49 2016 -0400
Committer: GitHub <[email protected]>
Committed: Wed Sep 14 22:15:49 2016 -0400

----------------------------------------------------------------------
 .../src/main/jython/gremlin_python/structure/io/graphson.py        | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5573def4/gremlin-python/src/main/jython/gremlin_python/structure/io/graphson.py
----------------------------------------------------------------------
diff --git 
a/gremlin-python/src/main/jython/gremlin_python/structure/io/graphson.py 
b/gremlin-python/src/main/jython/gremlin_python/structure/io/graphson.py
index fd13ae9..aae3ab2 100644
--- a/gremlin-python/src/main/jython/gremlin_python/structure/io/graphson.py
+++ b/gremlin-python/src/main/jython/gremlin_python/structure/io/graphson.py
@@ -181,7 +181,7 @@ class NumberSerializer(GraphSONSerializer):
     def _dictify(self, number):
         if isinstance(number, bool):  # python thinks that 0/1 integers are 
booleans
             return number
-        elif isinstance(number, long):
+        elif isinstance(number, long) or (number > 2147483647): # in python 
all numbers are int unless specified otherwise
             return _SymbolHelper.objectify("Int64", number)
         elif isinstance(number, int):
             return _SymbolHelper.objectify("Int32", number)

Reply via email to