Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collection.on is not a function #35

Open
logecolib opened this issue Dec 19, 2024 · 1 comment
Open

Collection.on is not a function #35

logecolib opened this issue Dec 19, 2024 · 1 comment
Labels

Comments

@logecolib
Copy link

Collection.on is not a function on latest collection2 and schema-index versions.

W20241219-14:21:10.358(-5)? (STDERR) packages/core-runtime.js:189
W20241219-14:21:10.358(-5)? (STDERR) throw error;
W20241219-14:21:10.358(-5)? (STDERR) ^
W20241219-14:21:10.358(-5)? (STDERR)
W20241219-14:21:10.358(-5)? (STDERR) TypeError: Collection2.on is not a function
W20241219-14:21:10.358(-5)? (STDERR) at module.wrapAsync.self (packages/aldeed:schema-index/common.js:12:13)
W20241219-14:21:10.358(-5)? (STDERR) at Module.wrapAsync (/home/lib/.meteor/packages/modules/.0.20.3.19t0har.56r++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/@meteorjs/reify/lib/runtime/index.js:252:8)
W20241219-14:21:10.358(-5)? (STDERR) at module (/home/lib/lib@cloud/Projects/hqlist/.meteor/local/build/programs/server/packages/aldeed_schema-index.js:124:9)
W20241219-14:21:10.358(-5)? (STDERR) at fileEvaluate (packages/modules-runtime.js:335:7)
W20241219-14:21:10.359(-5)? (STDERR) at Module.require (packages/modules-runtime.js:237:14)
W20241219-14:21:10.359(-5)? (STDERR) at Module.mod.require (/home/lib/.meteor/packages/modules/.0.20.3.19t0har.56r++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/@meteorjs/reify/lib/runtime/index.js:30:33)
W20241219-14:21:10.359(-5)? (STDERR) at Module.moduleLink [as link] (/home/lib/.meteor/packages/modules/.0.20.3.19t0har.56r++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/@meteorjs/reify/lib/runtime/index.js:102:22)
W20241219-14:21:10.359(-5)? (STDERR) at module.wrapAsync.self (packages/aldeed:schema-index/server.js:1:159)
W20241219-14:21:10.359(-5)? (STDERR) at Module.wrapAsync (/home/lib/.meteor/packages/modules/.0.20.3.19t0har.56r++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/@meteorjs/reify/lib/runtime/index.js:252:8)
W20241219-14:21:10.359(-5)? (STDERR) at module (/home/lib/lib@cloud/Projects/hqlist/.meteor/local/build/programs/server/packages/aldeed_schema-index.js:21:9)
W20241219-14:21:10.359(-5)? (STDERR) at fileEvaluate (packages/modules-runtime.js:335:7)
W20241219-14:21:10.359(-5)? (STDERR) at Module.require (packages/modules-runtime.js:237:14)
W20241219-14:21:10.359(-5)? (STDERR) at Module.mod.require (/home/lib/.meteor/packages/modules/.0.20.3.19t0har.56r++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/@meteorjs/reify/lib/runtime/index.js:30:33)
W20241219-14:21:10.359(-5)? (STDERR) at Object.require (packages/modules-runtime.js:257:21)
W20241219-14:21:10.360(-5)? (STDERR) at evaluateNextModule (packages/core-runtime.js:167:26)
W20241219-14:21:10.360(-5)? (STDERR) at runEagerModules (packages/core-runtime.js:206:3)
W20241219-14:21:10.360(-5)? (STDERR)
W20241219-14:21:10.360(-5)? (STDERR) Node.js v20.18.0

To Reproduce

Steps to reproduce the behavior:

  1. Create and empty meteor project
  2. meteor add aldeed:collection2 aldeed:schema-index aldeed:simple-schema
  3. start meteor
  4. See error

Expected behavior

Application initializes correclty with the installed packages

Versions (please complete the following information):

meteor list
aldeed:collection2 4.0.4 Automatic validation of Meteor Mongo ...
aldeed:schema-index 3.1.1 Control some MongoDB indexing with sc...
aldeed:simple-schema 1.13.1* A simple schema validation object wi...
ecmascript 0.16.10 Compiler plugin that supports ES201...
es5-shim 4.8.1 Shims and polyfills to improve ECMASc...
hot-module-replacement 0.5.4 Update code in development without re...
meteor-base 1.5.2 Packages that every Meteor app needs
mobile-experience 1.1.2 Packages for a great mobile user expe...
mongo 2.0.2* Adaptor for using MongoDB and Minimon...
react-meteor-data 3.0.2 React hook for reactively tracking Me...
reactive-var 1.0.13 Reactive variable
shell-server 0.6.1 Server-side component of the `meteor ...
standard-minifier-css 1.9.3 Standard css minifier used with Meteo...
standard-minifier-js 3.0.0 Standard javascript minifiers used wi...
static-html 1.4.0 Define static page content in .html f...
typescript 5.4.3* Compiler plugin that compiles TypeScr...

  • Meteor version: 3.0.4

Additional context

Happens on a new project or existing big ones that worked fine without schema-index

@logecolib logecolib added the bug label Dec 19, 2024
@cpravetz
Copy link

I found this error stopped when I forced an update for raix:eventemitter to 2.0.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants