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

cronProcessDownloads: Cannot read property 'filter' of undefined #17714

Closed
JoshMcCullough opened this issue May 21, 2020 · 5 comments
Closed
Assignees

Comments

@JoshMcCullough
Copy link
Contributor

Description:

Seeing the log message below repeatedly.

Steps to reproduce:

No steps, noticed this while viewing the log.

Expected behavior:

Actual behavior:

Server Setup Information:

  • Version of Rocket.Chat Server: 3.1.1
  • Operating System: RHEL 7
  • Deployment Method: Docker
  • Number of Running Instances: 1
  • DB Replicaset Oplog: enabled
  • NodeJS Version: 12.16.1
  • MongoDB Version: 4.0.9

Relevant logs:

=== UnHandledPromiseRejection ===
TypeError: Cannot read property 'filter' of undefined
at app/user-data-download/server/cronProcessDownloads.js:50:57
at SynchronousCursor.forEach (packages/mongo/mongo_driver.js:1102:16)
at Cursor. [as forEach] (packages/mongo/mongo_driver.js:882:44)
at loadUserSubscriptions (app/user-data-download/server/cronProcessDownloads.js:46:9)
at app/user-data-download/server/cronProcessDownloads.js:498:3
at /app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40
=> awaited here:
at Function.Promise.await (/app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/promise_server.js:56:12)
at app/user-data-download/server/cronProcessDownloads.js:567:2
at /app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40

@JoshMcCullough
Copy link
Contributor Author

Also what is this CRON job even for?

@sampaiodiego
Copy link
Member

this cron job is in charge of processing users' "download my data" requests..

@pierre-lehnen-rc
Copy link
Contributor

Fixed by #17577

@maiconbaumx
Copy link

I'm facing a similar issue after upgrading to 3.5.0.

 === UnHandledPromiseRejection ===
 TypeError: Cannot read property 'filter' of undefined
 at app/user-data-download/server/cronProcessDownloads.js:51:59
 at SynchronousCursor.forEach (packages/mongo/mongo_driver.js:1138:16)
 at Cursor.<computed> [as forEach] (packages/mongo/mongo_driver.js:918:44)
 at loadUserSubscriptions (app/user-data-download/server/cronProcessDownloads.js:47:9)
 at app/user-data-download/server/cronProcessDownloads.js:499:3
 at /opt/Rocket.Chat/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40
 => awaited here:
 at Function.Promise.await (/opt/Rocket.Chat/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/promise_server.js:56:12)
 at app/user-data-download/server/cronProcessDownloads.js:577:2
 at /opt/Rocket.Chat/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40
 ---------------------------------
 Errors like this can cause oplog processing errors.
 Setting EXIT_UNHANDLEDPROMISEREJECTION will cause the process to exit allowing your service to automatically restart the process
 Future node.js versions will automatically exit the process
 =================================

@sampaiodiego
Copy link
Member

@maiconbaumx what version were you using before upgrading? the uids field was created by #16761 released on version 3.1.0 .. I wonder if you missed a migration 🤔

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

No branches or pull requests

4 participants