1/ I wish #golang json serialization marshal/unmarshal an int64 as a string while keeping the int64 representation. Something like,
type User {
UserId int64 `json:"user_id,stringmode"`
}
-
Show this thread
-
2/ I think it's a common use case. Twitter does `id_str` for this reason. And, I got burned for it in
@dgraphlabs' ratel interface not to long ago because I expected the client to do it automatically since it uses json as an exchange format.https://github.com/dgraph-io/ratel/issues/142 …2 replies 0 retweets 0 likesShow this thread -
Replying to @generativist
I'm not sure I understand what you expect Dgraph to do in this case. Either we encode the integer as a string and some programs will have issues parsing, or we store them as integers and JavaScript will have a bad time. What option are you proposing? https://play.golang.org/p/lD0Y4HbWMDq
1 reply 0 retweets 1 like
dgraph itself: nothing. ratel as UI? not sure. my expectation was violated because I'm consuming dgraph mostly through not-javascript so the integer truncation in ratel was surprising, even though it's obviousy a JS gui. But I'm not sure patching ratel is worth the cost.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.