-
Notifications
You must be signed in to change notification settings - Fork 78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix csv.py parser mappings #5602
Conversation
Related to deephaven#5601
This is incomplete, because it looks like there is a bug in the underlying deephaven-csv layer. See the issue for details. |
My earlier assessment that there was a bug in the lower layer only applies to reserved keywords as column names. Will file a bug there. |
@@ -75,9 +75,9 @@ def read( | |||
dht.byte: _JParsers.BYTE, | |||
dht.char: _JParsers.CHAR, | |||
dht.short: _JParsers.SHORT, | |||
dht.int64: _JParsers.INT, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This disables support for dht.int64
and dht.float64
. That seems more accurate, but how many users will it affect?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dht.int64 == dht.long
, dht.float64 == dht.double
; they are present lower down in the map.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm afraid I don't see dht.int64, dht.float64, dht.int16 or dht.int8 anywhere in this file. What file is that in?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I see it. This is an object map, so you only need one variable that points to the object to be represented. So in dtypes.py
, both int64 and long point to the same DType object, so you only need one represented in the map.
@@ -75,9 +75,9 @@ def read( | |||
dht.byte: _JParsers.BYTE, | |||
dht.char: _JParsers.CHAR, | |||
dht.short: _JParsers.SHORT, | |||
dht.int64: _JParsers.INT, | |||
dht.int32: _JParsers.INT, | |||
dht.long: _JParsers.LONG, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do int64 and float64 correctly map to long and double?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, they are the same objects.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -75,9 +75,9 @@ def read( | |||
dht.byte: _JParsers.BYTE, | |||
dht.char: _JParsers.CHAR, | |||
dht.short: _JParsers.SHORT, | |||
dht.int64: _JParsers.INT, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm afraid I don't see dht.int64, dht.float64, dht.int16 or dht.int8 anywhere in this file. What file is that in?
@@ -75,9 +75,9 @@ def read( | |||
dht.byte: _JParsers.BYTE, | |||
dht.char: _JParsers.CHAR, | |||
dht.short: _JParsers.SHORT, | |||
dht.int64: _JParsers.INT, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I see it. This is an object map, so you only need one variable that points to the object to be represented. So in dtypes.py
, both int64 and long point to the same DType object, so you only need one represented in the map.
Fixes #5601