MeteorToys reference break... things. livedata_connection bug?

I was updating an old 1.6 project to 2.x and when merging some changes, Meteor.subscribe started to throw errors (see image)
I do not have MeteorToys installed and no references to it in my code.

The screenshot shows an error 'at Connection.subscribe (livedata_connection.js:392:7)' but it seems like there is some unfortunate coding in livedata_connection.js, the test for ‘existing’ returns -1 and later
if(existing), which is expecting an object or undefined, is satisfied with the -1 and goes ahead trying to read and create properties on ‘existing’, which does not really exist…

I’m lost… why does it think the name of the sub is ‘MeteorToys’ and why does not livedata_connection.js test for an object instead of undefined?

Update: I did indeed find a reference toMeteorToys in the code, but after removing it I get the same error for each call I make to Meteor.subscribe. Strange.

Hey Meteor Toys are pending a major update… they’re not really compatible with the new Meteor releases

I removed the reference (was not in packages, but existed in the ‘versions’ file), but each subscription throw the same error since existing = -1 is seen as true. MeteorToys was apparently just the first subscription.

I know it’s been awhile but was wondering if you knew current status? Or alternatively, if there are other debug tools you’d recommend for 2.x? I’ve found meteortoys to be an indispensable set of tools, especially with respect to collections and subscriptions.
Thanks!

Have you tried Meteor DevTools Evolved - Chrome Web Store ?

2 Likes

Thank you @harry97! I’m a little embarrassed because I have tried it, it’s installed in my browser, and I just forgot about it. Really appreciate the nudge!