Ask Your Question
2

question id and unicode title slug changed after askbot migration

asked 2012-07-28 23:26:34 -0600

str gravatar image

updated 2012-07-29 21:58:53 -0600

Hi all,

I updated askbot-devel from version34 to version 43, re-installed, and then run migration, everything worked fine, but the question id for each question got changed. Something like for 150 previous posts, the first one got 151, the 100th one got 250.

May be in my postgres database, there is some place I've to reset any sequence from where the question gets the id.

Any help much appreciated. All of my sites previous links posted in various places dont' work now :(

Edit: I'm using ALLOW_UNICODE_SLUGS = True. The unicode string for the question title is different(with the previous link) and wrong now. Before migration it was ok (e.g. similar with the question title)

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2012-07-28 23:55:07 -0600

Evgeny gravatar image

updated 2012-08-25 20:41:23 -0600

Have you actually checked your site's previous links? They should be working by redirection to the new urls. Do you really have broken links?

edit: id numbers cannot be matched, but we provide proper redirects so that there are no broken links.

edit flag offensive delete link more

Comments

1

I checked. But previous links dont work. Question ids are not same and no redirection takes place :( Anything to specify in settings.py? But isn't there any way to keep the original question ids as it was?

str gravatar imagestr ( 2012-07-29 03:21:35 -0600 )edit

@str there must be a way to fix old id's I will look into that and respond by Tuesday. The old id's are saved in the database, something must be wrong in the redirection code.

Evgeny gravatar imageEvgeny ( 2012-07-29 13:23:18 -0600 )edit

Many thanks, Evgeny. More updates about the issue, 1. previous links do work, i.e. redirects to the new link with new question id; 2. the unicode string for the question title is different(with the previous link) and wrong now.

str gravatar imagestr ( 2012-07-29 21:36:54 -0600 )edit

Ok, the slugs are different, if I understand correctly, but redirects work, no? Do you get broken links?

Evgeny gravatar imageEvgeny ( 2012-07-29 22:13:51 -0600 )edit

Yes, Evgeny. Redirects work. No broken link. (But is not there any way keeping the original id's? :-( ). 2. And yes, slugs are different (and wrong.)

str gravatar imagestr ( 2012-07-29 22:19:47 -0600 )edit

Re: wrong slugs - can you show me an example? Id's cannot be returned to old at the moment, I think me made mistake in the design decision, but it is what it is now. We might revert back to the "old id's" but that will perturb some other users.

Evgeny gravatar imageEvgeny ( 2012-07-29 22:22:59 -0600 )edit
  1. I sent email in your gmail account with the examples. Many thanks for your investigation. 2. Least, could you please show me some pointers in the code (if not possible to create a new branch with the fix), where to change, just to fix the 'old id' issue for myself?
str gravatar imagestr ( 2012-07-29 22:47:03 -0600 )edit

Ok, well the slugs are different, I can't read the text easily unfortunately. Do the two versions belong to the same question if you judge by the meaning of the strings? Re: id's - it's in the function askbot.views.readers.questions. and to change you'll need to refer to question by thread ids instead of the question post ids. It's not an easy change and if you do it I'm afraid you won't be able to upgrade in the future.

Evgeny gravatar imageEvgeny ( 2012-07-29 23:05:31 -0600 )edit

Yes its not possible for you to understand my language :). You mean, whether both links point to the same question? Yes. But the meaning of the news url-string doesn't make any sense, as lots of characters missing from the question title.

str gravatar imagestr ( 2012-07-29 23:41:52 -0600 )edit

Any update/suggestion/quick-fix regarding the slug? Eagerly waiting

str gravatar imagestr ( 2012-07-31 22:51:14 -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

Stats

Asked: 2012-07-28 23:26:34 -0600

Seen: 163 times

Last updated: Aug 25 '12