mongo-express / mongo-express-docker

a dockerized mongo-express for viewing mongoDB in the browser
MIT License
198 stars 93 forks source link

Pagination Appears to be Broken in Latest Build #102

Closed FrancisBaileyH closed 5 months ago

FrancisBaileyH commented 9 months ago

I pulled in the latest image this morning and discovered that while server stats are now working, pagination of items is not. E.g. when clicking on the pagination link:

https:///db//?skip=60&key=&value=&type=&query=&projection=&runAggregate=false, the service returns a 302 and simply redirects back to the page. I was able to reproduce this on all collections. I checked the container logs and found the following:

2023-10-02 22:57:44 MongoInvalidArgumentError: Argument "pipeline" must be an array of aggregation stages
2023-10-02 22:57:44     at Collection.aggregate (/node_modules/mongodb/lib/collection.js:368:19)
2023-10-02 22:57:44     at exp.viewCollection (/node_modules/mongo-express/lib/routes/collection.js:167:26)
2023-10-02 22:57:44     at Layer.handle [as handle_request] (/node_modules/express/lib/router/layer.js:95:5)
2023-10-02 22:57:44     at next (/node_modules/express/lib/router/route.js:144:13)
2023-10-02 22:57:44     at mongoMiddleware (/node_modules/mongo-express/lib/router.js:260:5)
2023-10-02 22:57:44     at Layer.handle [as handle_request] (/node_modules/express/lib/router/layer.js:95:5)
2023-10-02 22:57:44     at next (/node_modules/express/lib/router/route.js:144:13)
2023-10-02 22:57:44     at Route.dispatch (/node_modules/express/lib/router/route.js:114:3)
2023-10-02 22:57:44     at Layer.handle [as handle_request] (/node_modules/express/lib/router/layer.js:95:5)
2023-10-02 22:57:44     at /node_modules/express/lib/router/index.js:284:15 {
2023-10-02 22:57:44   [Symbol(errorLabels)]: Set(0) {}
2023-10-02 22:57:44 }
FrancisBaileyH commented 9 months ago

Potentially related issue: https://github.com/mongo-express/mongo-express/issues/944

BlackthornYugen commented 9 months ago

Thanks for letting us know. We will try to get 1.0.1 or 1.0.2 out as soon as possible.

BlackthornYugen commented 5 months ago

Closing as 1.0.2 has been released with the fix.