Closed JanMP closed 1 year ago
Thanks for the report. Can you let me know if this issue also affects 1.3.7, 1.3.8 and/or 1.3.9?
1.3.7 and 1.3.10 initial load fine, above error on change in lookup 1.3.8 and 1.3.9 initial load fails with a different error (also on other pipelines without lookups that don't have the dataByKey problem) see below:
Exception from sub content.forQueryString id bdmZEDZ7Jf79AceJa TypeError: Cannot convert undefined or null to object
at Function.entries (<anonymous>)
at ReactiveAggregate (packages/tunguska:reactive-aggregate/aggregate.js:56:37)
at imports/api/Content.coffee:173:5
at /Users/jan-michaelpilgenroeder/.meteor/packages/promise/.0.12.2.15o915w.zdms++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/meteor-promise/fiber_pool.js:43:40
=> awaited here:
at Function.Promise.await (/Users/jan-michaelpilgenroeder/.meteor/packages/promise/.0.12.2.15o915w.zdms++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/meteor-promise/promise_server.js:56:12)
at packages/meteor.js:367:22
at Meteor.EnvironmentVariable.EVp.withValue (packages/meteor.js:1389:31)
at Subscription._runHandler (packages/ddp-server/livedata_server.js:1123:60)
at Session._startSubscription (packages/ddp-server/livedata_server.js:934:9)
at Session.sub (packages/ddp-server/livedata_server.js:673:12)
at packages/ddp-server/livedata_server.js:603:43
What version of Meteor are you using?
2.12
Would you be able to retest with the new branch: bugfix/object-chaining
please?
still get the dataByKey Error
I have bumped the package version in the new branch in case meteor's failing to see the change, but can you also please confirm you followed this process to test the branch:
cd /path/to/your/project
packages
directory exists: mkdir -p packages
packages
directory: cd packages
git clone git@github.com:robfallows/tunguska-reactive-aggregate.git
cd tunguska-reactive-aggregate
git checkout bugfix/object-chaining
cd ../..
Note: you will need to git pull
if these were the steps you followed, in order to get the new version number.
Thanks.
you are right, had not checked out the correct branch...
now I get this error on changing feedback:
Exception in changedobserveChanges callback: errorClass [Error]: _sub$_session$collect2.keys is not iterable (cannot read property Symbol(Symbol.iterator))
at update (packages/tunguska:reactive-aggregate/aggregate.js:282:13)
at debounce (packages/tunguska:reactive-aggregate/aggregate.js:301:7)
at changed (packages/tunguska:reactive-aggregate/aggregate.js:323:9)
at runWithEnvironment (packages/meteor.js:1486:24)
at packages/meteor.js:1499:14
at packages/mongo/observe_multiplex.js:178:30
at Array.forEach (<anonymous>)
at Function._.each._.forEach (packages/underscore.js:139:11)
at Object.task (packages/mongo/observe_multiplex.js:172:9)
at Meteor._SynchronousQueue.SQp._run (packages/meteor.js:1026:16)
at packages/meteor.js:1003:12 {
path: '',
sanitizedError: errorClass [Error]: tunguska:reactive-aggregate [Error]
at errorClass.<anonymous> (packages/tunguska:reactive-aggregate/aggregate.js:11:27)
at new errorClass (packages/meteor.js:718:17)
at update (packages/tunguska:reactive-aggregate/aggregate.js:282:13)
at debounce (packages/tunguska:reactive-aggregate/aggregate.js:301:7)
at changed (packages/tunguska:reactive-aggregate/aggregate.js:323:9)
at runWithEnvironment (packages/meteor.js:1486:24)
at packages/meteor.js:1499:14
at packages/mongo/observe_multiplex.js:178:30
at Array.forEach (<anonymous>)
at Function._.each._.forEach (packages/underscore.js:139:11)
at Object.task (packages/mongo/observe_multiplex.js:172:9)
at Meteor._SynchronousQueue.SQp._run (packages/meteor.js:1026:16)
at packages/meteor.js:1003:12 {
isClientSafe: true,
error: 'Error',
reason: 'tunguska:reactive-aggregate',
details: undefined,
errorType: 'Meteor.Error'
},
errorType: 'tunguska:reactive-aggregate'
}
I've made a couple of tweaks to the property chaining. Please pull the updates and retest.
It's working 🎉
Awesome! I'll issue a new release.
The following aggregation with a $lookup phase throws an error on v1.3.10 (1.3.6 works fine) when changing data in one of the feedback documents (initial load works fine):
The Error: