[SERVER-15546] Command response "ok" value is floating point, should be bool or int Created: 07/Oct/14 Updated: 09/Apr/20 |
|
| Status: | Open |
| Project: | Core Server |
| Component/s: | Usability |
| Affects Version/s: | None |
| Fix Version/s: | features we're not sure of |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Danielle Jenkins | Assignee: | DO NOT USE - Backlog - Platform Team |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | move-sa, polish | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Participants: |
| Description |
|
Expected Result: Actual Result: |
| Comments |
| Comment by Matt Kangas [ 08/Oct/14 ] | |||||||||||||||||||||||
|
The "ok:" floating point value appears to come from Command::appendCommandStatus() This seems unfortunate, but for backwards compatibility reasons we may not be able to correct this easily. paddingFactor is defined as a double in the server, so a floating point representation is correct. | |||||||||||||||||||||||
| Comment by Matt Kangas [ 08/Oct/14 ] | |||||||||||||||||||||||
|
I can repro on MongoDB 2.6.1 Shell:
pymongo:
| |||||||||||||||||||||||
| Comment by Bernie Hackett [ 07/Oct/14 ] | |||||||||||||||||||||||
|
Hi, I've moved this to the SERVER project because the python driver just decodes the types defined in the response. If the response defines these fields as BSON int32 the python driver will return python int. If the response defines the fields as BSON double, the python driver returns a python float. It does not change the type defined in the response from the server. |