Forum BigDB Error: The key XXX is invalid.

Discussion and help relating to the PlayerIO database solution, BigDB.

Error: The key XXX is invalid.

Postby UnknownGuardian » September 29th, 2010, 12:26 am

This error just started popping up today. I've cleared the database, but it still persists.

Code: Select all
Error: The key '@codeBobTheC7880030' is invalid. Keys must be between 1 and 50 word characters (no spaces).



Did a new update cause that string to be an invalid key?
UnknownGuardian
 
Posts: 94
Joined: May 25th, 2010, 5:11 am

Re: Error: The key XXX is invalid.

Postby default0 » September 29th, 2010, 2:47 pm

UnknownGuardian wrote:This error just started popping up today. I've cleared the database, but it still persists.

Code: Select all
Error: The key '@codeBobTheC7880030' is invalid. Keys must be between 1 and 50 word characters (no spaces).



Did a new update cause that string to be an invalid key?


Yes, it did.
Oliver fixed another bug and thats why several signs are disallowed now.
I dont know what signs exactly, but obviously the @ is included.

EDIT: @Oliver, how about adding a list of what signs are disallowed in the documentation and the error messages (in flash and admin panel)? I guess thatd be helpful for lots of developers.

Best regards
Try to play my Game: -->BlackGalaxy<--
User avatar
default0
 
Posts: 115
Joined: February 2nd, 2010, 6:46 pm
Location: Germany

Re: Error: The key XXX is invalid.

Postby UnknownGuardian » September 30th, 2010, 12:40 am

Yes, I would appreciate a list of invalid characters, because the saving part of my game is completely broken, and I'd prefer not to make some huge changes and then end up having to change those to something else when I find out.
UnknownGuardian
 
Posts: 94
Joined: May 25th, 2010, 5:11 am

Re: Error: The key XXX is invalid.

Postby Oliver » October 1st, 2010, 1:20 pm

Hi Guys,

Sorry about breaking your game. That's totally unacceptable, and we strive never to do it. We did lookups to see if we'd break anything but apparently we missed your game. SORRY!

Anywhere, here's the skinny: We found a bug.

BigDB keys have always had restrictions on them. It's stated right in the documentation:

Keys of database objects must between one and 50 characthers long, and only consist of word characters (no spaces, special characters).


The bug we found was simply that the regular expression that validates all keys when objects are created was faulty.

As mentioned, it's been fixed. Here is the new regular expression if you're interested: ^[\w\s\-]{1,50}$

It includes spaces and dashes because in the before-mentioned-search we found games that used those in keys, so we have to keep supporting them...

Best,
Oliver
User avatar
Oliver
.IO
 
Posts: 1159
Joined: January 12th, 2010, 8:29 am


Return to BigDB