Ask Your Question

problem of title is to long

asked 2012-02-19 03:36:41 -0600

yangshuo's avatar

updated 2012-02-19 03:39:16 -0600

If i input title to long,page display "Internal server error system error log is recorded, error will be fixed as soon as possible please report the error to the site administrators if you wish "

log dispaly " TIME: 2012-02-19 17:22:52,437 MSG: 錯誤: 值對型別 character varying(300) 而言太長"

I advise tiltle do checking,if title to long ,page don't permit input.

edit retag flag offensive close merge delete


Could you post the title here, please, I'll test it.

Evgeny's avatar Evgeny  ( 2012-02-19 11:31:27 -0600 )edit

2 Answers

Sort by » oldest newest most voted

answered 2012-02-19 11:51:08 -0600

Evgeny's avatar

updated 2012-02-19 14:30:42 -0600

edit: fixed in the repository, will be in version 0.7.40.

In encoded unicode characters byte length and the character count are not the same.

In your case the unicode string is below the character count limit and the byte length is above, so the first check passes, but on the level of database it fails and you get an internal server error.

Now adjusted the input length validator.

edit flag offensive delete link more


Evgeny, I got the latest master off Github today, I'm getting the error message 'The title is too long, maximum allowed size is 255 bytes' for even very short messages. If I try an all-Latin title I get an error page with: "__init__() got an unexpected keyword argument 'parser'". Do I post a separate bug or is it something you're working on.

Basel Shishani's avatar Basel Shishani  ( 2012-02-27 01:10:20 -0600 )edit

Sorry this seems to have been related to the html5lib issue - it went away after I downgraded to v0.90

Basel Shishani's avatar Basel Shishani  ( 2012-02-27 03:35:42 -0600 )edit

answered 2012-03-15 12:53:40 -0600

Miguel's avatar

changing from:

elif encoded_value > self.max_length:


elif len(encoded_value) > self.max_length:

solves the issue!

edit flag offensive delete link more


Oh, man, thanks. That was a silly bug! Pushed this fix to the repo.

Evgeny's avatar Evgeny  ( 2012-03-15 15:10:28 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2012-02-19 03:36:41 -0600

Seen: 359 times

Last updated: Mar 15 '12