Describe the bug
Error when trying to send double data to firebase through a json object: "bad request, Invalid data; couldn't parse JSON object. Are you sending a JSON object with valid key names?".
This happens when I try to send a double value of 0.
Printing the json object I see that the sensor data (double) is being displayed as "0." when this error occurs. Whenever I set some other value to this sensor different than 0, e.g. 0.1, everything works fine...
To Reproduce
FirebaseJson json;
double doubleVariable = 0;
json.set(pathVariable, doubleVariable);
if (!Firebase.updateNode(gFirebaseData, path, json)) {
Serial.println(gFirebaseData.errorReason());
return false;
}
Describe the bug Error when trying to send double data to firebase through a json object: "bad request, Invalid data; couldn't parse JSON object. Are you sending a JSON object with valid key names?".
This happens when I try to send a double value of 0.
Printing the json object I see that the sensor data (double) is being displayed as "0." when this error occurs. Whenever I set some other value to this sensor different than 0, e.g. 0.1, everything works fine...
To Reproduce FirebaseJson json; double doubleVariable = 0;
json.set(pathVariable, doubleVariable);
if (!Firebase.updateNode(gFirebaseData, path, json)) { Serial.println(gFirebaseData.errorReason()); return false; }
IDE and its version:
ESP32 Arduino Core SDK version
FirebaseESP32 version
FirebaseJson version