-
Notifications
You must be signed in to change notification settings - Fork 639
Description
Using a version prior to version 0.30.0 everything worked. This is how I would insert a record into my local datastore:
var projectId = process.env.DATASTORE_PROJECT_ID;
var host = process.env.DATASTORE_EMULATOR_HOST;
var gcloud = require('gcloud');
var datastore = gcloud.datastore;
var dataset = datastore.dataset({
projectId: projectId,
apiEndpoint: host
});
var key = dataset.key('Company');
dataset.save({
key: key,
data: {
rating: '10'
}
}, function(err) {
console.log(key.path); // [ 'Company', 5669468231434240 ]
console.log(key.namespace); // undefined
});
The record would show up in the datastore.
I then updated to version 0.30.0 (tried also the newest and the same issue occurred). When I try to connect and insert/get (any operation) an entity I am unable to. I get the following error from my nodejs console:
E0408 22:51:33.856966404 39870 parsing.c:472] Unknown frame type 50
The code I am using to insert records for 0.30.0+ is:
var projectId = process.env.DATASTORE_PROJECT_ID;
var host = process.env.DATASTORE_EMULATOR_HOST;
var gcloud = require('gcloud')({
projectId: projectId
});
var datastore = gcloud.datastore({
apiEndpoint: host
});
var key = datastore.key('Company');
datastore.save({
key: key,
data: {
rating: '10'
}
}, function(err) {
console.log(key.path); // [ 'Company', 5669468231434240 ]
console.log(key.namespace); // undefined
});
My local datastore was installed today using the command gcloud components install gcd-eumulator so it is the version as of April/8th/2016.
I tried this on two separate environments (Ubuntu 15.04 and Windows 10) and the same error was occurring for environments.