-
Notifications
You must be signed in to change notification settings - Fork 182
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
Inconsistencies of MapReduce when using http or pbc [JIRA: CLIENTS-131] #394
Comments
@gglanzani We'll take a look at this. I assume it's not related to the |
No, that issue seems to be related with an older version of mochijson2, while this one present itself only when I'm NOT using mochi |
@gglanzani Sorry for the delay. Trying to understand your situation. So you are running your own, custom Erlang I'm looking at our current test cases and all of them seem to return a list values, not more complicated types like proplists. I could see that curl is simply blurping back whatever Erlang returns, but the Python client has to serialize and deserialize. As you can see from the PBC results, it's trying to convert it into a Python dict(), which is the source of the exception. I'm interested that the HTTP sort of works. I'm guessing it is unpacking part of the JSON we get back from Riak and throwing the rest on the floor. So my guess at the moment is the Python client is only supporting returning a list of values. We could look at lists of dicts() as an enhancement. |
Yes,you gave an accurate description of what (I think) is going on. I think lists of dicts were fairly common but I see that some extra code is needed to make it work. Btw, curl converts [{grid1, year1}, {grid2 , year2}] to {grid1: year1, grid2: year2}, so some conversion is happening. Is this difficult to fix? |
@gglanzani I'll take a good to see how difficult it would be to add. Probably not too hard. Just have to prioritize it. |
@javajolt At least it's in jira 😜 |
I have the following Erlang code (very simple, just for illustration)
When I run a MR code via CURL, I get
However when submitting with Python using http
I get
C7FF2796D6BD1153E847E84277F6B4A1022E29DACA35989004C10FFA92E2A5F0
If, instead, I use
pbc
the client raises an exception
Am I doing something wrong, or…? Right now changing the Erlang code is the only fix:
The text was updated successfully, but these errors were encountered: