bobthecow / genghis

The single-file MongoDB admin app
http://genghisapp.com
MIT License
1.45k stars 164 forks source link

Unable to modify/delete documents when _id is not an ObjectId #126

Closed ghost closed 11 years ago

ghost commented 11 years ago

I use documented keyed used ints and genghis is unable to operate correctly in that situation.

bobthecow commented 11 years ago

It works for me :)

Can you give me more information? Which Genghis version and backend are you running? What OS, OS version, Mongo version, Mongo driver version, etc?

ghost commented 11 years ago

Mac OS X 10.8.4 Mongo 2.4.5

I'm updating genghisapp now, so I no longer have the old version number. Sorry about that.

ghost commented 11 years ago

I have this document: { _id: 0, shard: 0, schemaVersion: 0 }

Collection index is: [ { "v": 1, "key": { "_id": 1 }, "ns": "dbname.users", "name": "id" } ]

Modifying produces the following error in the latest genghisapp 2.3.6: Document '~MA==' not found in 'users'

bobthecow commented 11 years ago

I am unable to reproduce this. Can you give me more information?

Are you using the Ruby or PHP backend? What Ruby or PHP version are you using? How are you running Genghis? (behind Apache, nginx, standalone, etc).

ghost commented 11 years ago

Ruby backend, installed via gem. Running via "genghisapp" in the terminal

bobthecow commented 11 years ago

What Ruby version are you running? Is it the system installed Ruby, or something like RVM or rbenv?

ghost commented 11 years ago

ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0] rubygems 2.0.5

bobthecow commented 11 years ago

That helps. Something's probably not right in Ruby 1.8.x. I was trying in 1.9.x and 2.0. I'll take a look.

bobthecow commented 11 years ago

This should be fixed in the hotfix/2.3.7 branch. Do you mind checking it out?

ghost commented 11 years ago

Verified the fix in hotfix/2.3.7. Thanks

bobthecow commented 11 years ago

Great. I'll get that released!

ghost commented 11 years ago

Feel free to close the issue

bobthecow commented 11 years ago

And it's released. Thanks again for the bug report.