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

Tabular.Table - Tabular.Table options must specify collection - Roles Collection #216

Open
gazzer82 opened this issue Jun 23, 2015 · 17 comments

Comments

@gazzer82
Copy link

I have enabled the Roles collection to be shown in meteor-admin as discussed in a separate issue, however for some reason showing roles and using collection-hooks, even with nothing configured for it cause the following error:

W20150623-15:17:33.102(-7)? (STDERR)          
W20150623-15:17:33.102(-7)? (STDERR) /Users/garethjeanne/.meteor/packages/meteor-tool/.1.1.3.1wysac9++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:245
W20150623-15:17:33.102(-7)? (STDERR)                        throw(ex);
W20150623-15:17:33.102(-7)? (STDERR)                              ^
W20150623-15:17:33.148(-7)? (STDERR) Error: Tabular.Table options must specify collection
W20150623-15:17:33.149(-7)? (STDERR)     at new Tabular.Table (packages/aldeed:tabular/common.js:20:1)
W20150623-15:17:33.149(-7)? (STDERR)     at packages/yogiben:admin/lib/both/startup.coffee:100:27
W20150623-15:17:33.149(-7)? (STDERR)     at Function._.each._.forEach (packages/underscore/underscore.js:113:1)
W20150623-15:17:33.149(-7)? (STDERR)     at adminCreateTables (packages/yogiben:admin/lib/both/startup.coffee:77:4)
W20150623-15:17:33.149(-7)? (STDERR)     at __coffeescriptShare (packages/yogiben:admin/lib/both/startup.coffee:125:2)
W20150623-15:17:33.149(-7)? (STDERR)     at /Users/garethjeanne/Documents/Programming/htlv2/htl/.meteor/local/build/programs/server/boot.js:229:

Removing either from the equation fixes the problem, but obviously isn't a real solution. Having the users, or any other collection added to meteor-admin doesn't cause any issues?

Thanks

Gareth

@maher-samir
Copy link

+1

@mpowaga
Copy link
Collaborator

mpowaga commented Jun 24, 2015

I had similar issue few weeks ago but this is related to aldeed:tabular package. Try to report an issue there.

One thing you can do is to check if collection causing a problem is instanceof Mongo.Collection. It's very likely to be a problem.

@HazemKhaled
Copy link

Try to open .meteor/packeges file and put alanning:roles after aldeed:collection2 not before it

@mordrax
Copy link

mordrax commented Jun 26, 2015

My package looks like this (with roles after collection2) but still getting the above error while trying to add roles to admin page

meteor-platform
accounts-ui
accounts-password
accounts-google
accounts-twitter
accounts-github
wylio:mandrill
mquandalle:jade
iron:router
aldeed:autoform
aldeed:simple-schema
aldeed:collection2
ongoworks:security
useraccounts:bootstrap
differential:event-hooks
momentjs:moment
raix:push
twbs:bootstrap
mrt:flash-messages
ovcharik:favico
matb33:collection-hooks
fortawesome:fontawesome
okgrow:iron-router-autoscroll
summernote:summernote
mpowaga:autoform-summernote
zimme:iron-router-auth
alanning:roles
dburles:collection-helpers
meteortoys:[email protected]
djedi:sanitize-html
yogiben:admin

@maher-samir
Copy link

Put it after

dburles:collection-helpers

We did it today ;)

@mordrax
Copy link

mordrax commented Jun 26, 2015

tried that and various other ordering, still getting the error, may i see your package list, maybe if i just copied your exact packages and ordering... i'd like to rule this out before looking at code/file ordering?

@maher-samir
Copy link

meteor-platform
less
accounts-password
useraccounts:bootstrap
zimme:iron-router-active
cmather:[email protected]
dburles:collection-helpers
reywood:publish-composite
mrt:moment
mrt:underscore-string-latest
matb33:collection-hooks
alanning:roles
dburles:factory
anti:fake
cunneen:mailgun
iron:[email protected]
yasinuslu:blaze-meta
yogiben:[email protected]
aldeed:simple-schema
cfs:standard-packages
cfs:gridfs
cfs:graphicsmagick

How you add the collection to the admin configuration file? type in browser console

Meteor.roles and check if the has a insert,update, etc. Rights just like Meteor.users

@maher-samir
Copy link

Also try to switch
matb33:collection-hooks
And
dburles:collection-helpers

@mordrax
Copy link

mordrax commented Jun 26, 2015

that didn't work either:

meteor-platform
accounts-ui
accounts-password
accounts-google
accounts-twitter
accounts-github
wylio:mandrill
mquandalle:jade
iron:router
aldeed:autoform
aldeed:simple-schema
aldeed:collection2
ongoworks:security
useraccounts:bootstrap
differential:event-hooks
momentjs:moment
raix:push
twbs:bootstrap
mrt:flash-messages
ovcharik:favico
fortawesome:fontawesome
okgrow:iron-router-autoscroll
summernote:summernote
mpowaga:autoform-summernote
zimme:iron-router-auth
dburles:collection-helpers
matb33:collection-hooks
alanning:roles
meteortoys:[email protected]
djedi:sanitize-html
yogiben:admin

however, I moved helpers, hooks and roles to just under collections and that did work...

meteor-platform
accounts-ui
accounts-password
accounts-google
accounts-twitter
accounts-github
wylio:mandrill
mquandalle:jade
iron:router
aldeed:autoform
aldeed:simple-schema
aldeed:collection2
dburles:collection-helpers
matb33:collection-hooks
alanning:roles
ongoworks:security
useraccounts:bootstrap
differential:event-hooks
momentjs:moment
raix:push
twbs:bootstrap
mrt:flash-messages
ovcharik:favico
fortawesome:fontawesome
okgrow:iron-router-autoscroll
summernote:summernote
mpowaga:autoform-summernote
zimme:iron-router-auth
meteortoys:[email protected]
djedi:sanitize-html
yogiben:admin

hopefully, someone fines this obscure ordering helpful. or rather, hopefully, no one else has to go through random permutations to get it compiling.

Is there a more reliable way of debugging the build process to work out dependencies?

@maher-samir
Copy link

That's the question

@gazzer82
Copy link
Author

Yup that sorted it for me too, thanks!

@brylie
Copy link

brylie commented Jul 6, 2015

I moved matb33:collection-hooks directly below aldeed:collection2 and that resolved the issue:

aldeed:collection2
matb33:collection-hooks

No other changes to ordering were necessary, where before I was getting the following error:

Error: Tabular.Table options must specify collection
     at new Tabular.Table (packages/aldeed:tabular/common.js:20:1)
     at packages/yogiben:admin/lib/both/startup.coffee:100:27
     at Function._.each._.forEach (packages/underscore/underscore.js:113:1)
     at adminCreateTables (packages/yogiben:admin/lib/both/startup.coffee:77:4)
     at __coffeescriptShare (packages/yogiben:admin/lib/both/startup.coffee:178:2)
     at /home/brylie/Code/Apinf/api-umbrella-dashboard/.meteor/local/build/programs/server/boot.js:229:5

@brylie
Copy link

brylie commented Jul 6, 2015

After further investigation, the issue seems related to the position of matb33:collection-hooks and comments in the .meteor/packages file.

# This works
matb33:collection-hooks
comments
# This breaks
comments
matb33:collection-hooks

Our project is based on yogiben:meteor-starter, so this issue may reside there.

@brylie
Copy link

brylie commented Jul 6, 2015

I have posted an issue describing the load order of the 'comments' and 'collection-hooks' packages in yogiben:meteor-starter that may be the underlying cause of this issue.

@Philip-Nunoo
Copy link
Contributor

+1 anyone facing this issue should look at @Mordra suggestion and follow it through. @mpowaga

@tmihelcich
Copy link

tmihelcich commented Aug 15, 2018

This looks like an old issue, but I am having trouble with this nearly three years later. No amount of rearranging the packages made this work for me, I went through each of the suggestions and applied what was relevant to my code. I am still receiving this 'options must specify collection' error, which prevents my app from starting. Was there a final fix for this?

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

No branches or pull requests

8 participants