aceymer / courseplanner

12 stars 4 forks source link

MongoError: Failed to parse 'limit' field must be numeric #2

Closed cgabdel closed 8 years ago

cgabdel commented 8 years ago

{"name":"MongoError","message":"Failed to parse: { find: \"syllabuses\", filter: {}, sort: { title: 1 }, projection: { title: 1, lecturer: 1, year: 1, owner: 1 }, limit: \"25\" }. 'limit' field must be numeric.","waitedMS":0,"ok":0,"errmsg":"Failed to parse: { find: \"syllabuses\", filter: {}, sort: { title: 1 }, projection: { title: 1, lecturer: 1, year: 1, owner: 1 }, limit: \"25\" }. 'limit' field must be numeric.","code":9}

It's related with MongoDB 3.2.1 problems, but I don't know how to fix it.

aceymer commented 8 years ago

What's your mongoose version? And it seems limit is sent as a string, not a number. How did you send the limit?

cgabdel commented 8 years ago

mongoose 4.1.2 i get this message after à fresh install of untouched v0.4.01

aceymer commented 8 years ago

Hmm I will change that to version 4.2 and I will try to make a clean install on my machine to see if I get the error. How did you get the error? Just after login?

cgabdel commented 8 years ago

yes, i think this was an issue with version of mongodb

aceymer commented 8 years ago

But how did you get the error? Just by starting the app and logging in?

cgabdel commented 8 years ago

yes, I get the error before the generation of Syllabuses, I tried with postman, same thing too.

aceymer commented 8 years ago

Can you try to run "npm list" command. It will show you all dependencies in your project. What version does it say for mongoose?

cgabdel commented 8 years ago

mongoose@4.4.12

aceymer commented 8 years ago

Got the error after update to mongodb 3.2-- Let me look into a fix ASAP!

aceymer commented 8 years ago

Please try version 0.4.02 or master. This should be solved now!

cgabdel commented 8 years ago

Problem solved!

cgabdel commented 8 years ago

can you please, since you are still in the v3.2-- check the problem of button delete, is it still there ?.

aceymer commented 8 years ago

No issues here with the delete button. Tried on a windows machine to.. Can you send me a screenshot where the button is gone?

cgabdel commented 8 years ago

I'll try to do a screen recorde

cgabdel commented 8 years ago

it seems that sorting button doesn't work

aceymer commented 8 years ago

Hehhe ok.. Guess its a good thing I was asked to do some testing.. Seems I got plenty of bugs.. Do you get an error?

aceymer commented 8 years ago

fixed in 0.4.03

cgabdel commented 8 years ago

I believe that is because the new version of mongodb, but you made a very good job.

aceymer commented 8 years ago

It was my last commit, got to trigger happy and added number parsing in 2 places. One was sort, and that was a mistake.

aceymer commented 8 years ago

Fixed on master as well

cgabdel commented 8 years ago

The problem is resolved, but it is normal that it does not sort by page ;)

aceymer commented 8 years ago

;)