Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard

Status: New
Owner: 
Labels: Type-Defect Priority-Medium

New issue 3967 by shirph...@126.com: upgrade from 2.0.18 to 2.0.20 get error
https://code.google.com/p/reviewboard/issues/detail?id=3967

*** READ THIS BEFORE POSTING!
***
*** You must complete this form in its entirety, or your bug report will be
*** rejected.
***
*** If you have a security issue to report, please send it confidentially
to
*** secur...@reviewboard.org. Posting security-related issues to this bug
*** tracker causes us to have to do an emergency release.
***
*** For customer support, please post to reviewbo...@googlegroups.com
***
*** If you have a patch, please submit it to
http://reviews.reviewboard.org/
***
*** This bug tracker is public. Please check that any logs or other
information
*** that you include has been stripped of confidential information.


What version are you running?
2.0.20

What's the URL of the page containing the problem?
http://shreview02

What steps will reproduce the problem?
1.sudo easy_install -U ReviewBoard
2.sudo rb-site upgrade /var/www/reviewboard
3.get the error

What is the expected output? What do you see instead?
It should be successfully, but I get the error:
Rebuilding directory structure
Updating database. This may take a while.

The log output below, including warnings and errors,
can be ignored unless upgrade fails.

--  --
Creating tables ...
Project signature has changed - an evolution is required
Installing custom SQL ...
Installing indexes ...
Installed 0 object(s) from 0 fixture(s)
The stored evolutions do not completely resolve all model changes.

Run `./manage.py evolve --hint` to see a suggestion for the changes  
required.


The following are the changes that could not be resolved:
In model reviews.ReviewRequest:
Field 'description_rich_text' has been added
Field 'testing_done_rich_text' has been added
In model reviews.Review:
Field 'body_top_rich_text' has been added
Field 'body_bottom_rich_text' has been added
In model reviews.ReviewRequestDraft:
Field 'description_rich_text' has been added
Field 'testing_done_rich_text' has been added
In model accounts.Profile:
Field 'default_use_rich_text' has been added
CommandError: Your models contain changes that Django Evolution cannot  
resolve automatically.


I remember there is the same error last upgrade to 2.0.18, but I ignore it  
because I found the 2.0.18 version number when I login the reviewboard page.


What operating system are you using? What browser?
Ubuntu 12.04, chrome

yihuihu@shreview02:/var/www/dbback$ sudo rb-site manage  
/var/www/reviewboard evolve -- --hint

[sudo] password for yihuihu:
#- Evolution for accounts
from django_evolution.mutations import AddField
from django.db import models


MUTATIONS = [
AddField('Profile', 'default_use_rich_text', models.NullBooleanField,  
null=True)

]
#--
#- Evolution for reviews
from django_evolution.mutations import AddField
from django.db import models


MUTATIONS = [
AddField('ReviewRequest', 'description_rich_text', models.BooleanField,  
initial=False),
AddField('ReviewRequest', 'testing_done_rich_text',  
models.BooleanField, initial=False),
AddField('Review', 'body_top_rich_text', models.BooleanField,  
initial=False),
AddField('Review', 'body_bottom_rich_text', models.BooleanField,  
initial=False),
AddField('ReviewRequestDraft', 'description_rich_text',  
models.BooleanField, initial=False),
AddField('ReviewRequestDraft', 'testing_done_rich_text',  
models.BooleanField, initial=False)

]
#--
Trial evolution successful.
yihuihu@shreview02:/var/www/dbback$ sudo rb-site manage  
/var/www/reviewboard list-evolutions

Applied evolutions for 'auth':
auth_delete_message
auth_unique_together_baseline

Applied evolutions for 'contenttypes':
contenttypes_unique_together_baseline

Applied evolutions for 'sessions':
session_expire_date_db_index

Applied evolutions for 'accounts':
is_private
timezone
open_an_issue
extra_data
timezone_length_30
localsiteprofile_permissions
unique_together_baseline
profile_show_closed
profile_should_send_email
profile_should_send_own_updates
profile_default_use_rich_text

Applied evolutions for 'attachments':
file_attachment_orig_filename
file_attachment_file_max_length_512
file_attachment_repo_info
file_attachment_repo_path_no_index
file_attachment_repo_revision_max_length_64

Applied evolutions for 'changedescs':
fields_changed_longtext
rich_text

Applied evolutions for 'diffviewer':
add_parent_diffs
filediff_filenames_1024_chars
diffset_basedir
filediff_status
add_diff_hash
diffsethistory_diff_updated
diffset_base_commit_id
filediffdata_line_counts
filediffdata_extra_data
all_extra_data

Applied evolutions for 'hostingsvcs':
account_hosting_url
account_hosting_url_max_length_255
 

Re: Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard


Comment #3 on issue 3967 by shirph...@126.com: upgrade from 2.0.18 to  
2.0.20 get error

https://code.google.com/p/reviewboard/issues/detail?id=3967

yihuihu@shreview02:/var/www$ sudo rb-site manage /var/www/reviewboard  
list-evolutions

[sudo] password for yihuihu:
Applied evolutions for 'auth':
auth_delete_message
auth_unique_together_baseline

Applied evolutions for 'contenttypes':
contenttypes_unique_together_baseline

Applied evolutions for 'sessions':
session_expire_date_db_index

Applied evolutions for 'accounts':
is_private
timezone
open_an_issue
extra_data
timezone_length_30
localsiteprofile_permissions
unique_together_baseline
profile_show_closed
profile_should_send_email
profile_should_send_own_updates
profile_default_use_rich_text

Applied evolutions for 'attachments':
file_attachment_orig_filename
file_attachment_file_max_length_512
file_attachment_repo_info
file_attachment_repo_path_no_index
file_attachment_repo_revision_max_length_64

Applied evolutions for 'changedescs':
fields_changed_longtext
rich_text

Applied evolutions for 'diffviewer':
add_parent_diffs
filediff_filenames_1024_chars
diffset_basedir
filediff_status
add_diff_hash
diffsethistory_diff_updated
diffset_base_commit_id
filediffdata_line_counts
filediffdata_extra_data
all_extra_data

Applied evolutions for 'hostingsvcs':
account_hosting_url
account_hosting_url_max_length_255
account_unique_together_baseline

Applied evolutions for 'reviews':
change_descriptions
last_review_timestamp
shipit_count
default_reviewer_repositories
null_repository
localsite
group_incoming_request_count
group_invite_only
group_visible
default_reviewer_local_site
add_issues_to_comments
file_attachments
file_attachment_comment_extra_data
review_request_last_review_activity_timestamp
review_request_depends_on
commit_id
file_attachment_comment_diff_id
rich_text
base_comment_extra_data
unique_together_baseline
extra_data
review_request_issue_counts
group_mailing_list_charfield
review_request_draft_commit_id
review_request_summary_index
review_request_summary_index_manual
split_rich_text

Applied evolutions for 'scmtools':
bugzilla_url_charfield
repository_raw_file_url
repository_visible
repository_path_length_255
localsite
repository_access_control
group_site
repository_hosting_accounts
repository_extra_data_null
unique_together_baseline
repository_archive
repository_hooks_uuid
repository_raw_password

Applied evolutions for 'site':
localsite_public

yihuihu@shreview02:/var/www$


--
You received this message because this project is configured to send all  
issue notifications to this address.

You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.


Re: Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard


Comment #5 on issue 3967 by shirph...@126.com: upgrade from 2.0.18 to  
2.0.20 get error

https://code.google.com/p/reviewboard/issues/detail?id=3967

OK , I got the result from command line:


from django_evolution.models import Version
for version in Version.objects.all(): print version

...
Hinted version, updated on 2015-02-12 02:23:19+00:00
Stored version, updated on 2015-02-12 02:23:19+00:00
Stored version, updated on 2014-11-13 01:53:34+00:00
Stored version, updated on 2014-08-08 02:26:47+00:00
Stored version, updated on 2014-06-04 08:17:08+00:00
Hinted version, updated on 2014-06-04 08:17:07+00:00
Stored version, updated on 2014-04-22 23:13:10+00:00
Stored version, updated on 2013-11-19 10:56:17+00:00



--
You received this message because this project is configured to send all  
issue notifications to this address.

You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.


Re: Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard

Updates:
Status: NeedInfo

Comment #2 on issue 3967 by chip...@gmail.com: upgrade from 2.0.18 to  
2.0.20 get error

https://code.google.com/p/reviewboard/issues/detail?id=3967

Sounds like your database is in a bad state. It needs to be repaired, or  
this will just continue to happen, and upgrades to future versions will  
most likely fail.


Can you run the following and post the output:

$ rb-site manage /path/to/site list-evolutions

$ rb-site manage /path/to/site shell
>>> from django_evolution.models import Version
>>> for version in Version.objects.all():
>>>  print version

--
You received this message because this project is configured to send all  
issue notifications to this address.

You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.


Re: Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard


Comment #1 on issue 3967 by shirph...@126.com: upgrade from 2.0.18 to  
2.0.20 get error

https://code.google.com/p/reviewboard/issues/detail?id=3967

admin --- database ---DJANGO_EVOLUTION --- versions:
Stored version, updated on 2015-02-12 02:23:19+00:00
Hinted version, updated on 2015-02-12 02:23:19+00:00
Stored version, updated on 2014-11-13 01:53:34+00:00
Stored version, updated on 2014-08-08 02:26:47+00:00
Stored version, updated on 2014-06-04 08:17:08+00:00
Hinted version, updated on 2014-06-04 08:17:07+00:00
Stored version, updated on 2014-04-22 23:13:10+00:00
Stored version, updated on 2013-11-19 10:56:17+00:00

--
You received this message because this project is configured to send all  
issue notifications to this address.

You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.


Re: Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard


Comment #6 on issue 3967 by chip...@gmail.com: upgrade from 2.0.18 to  
2.0.20 get error

https://code.google.com/p/reviewboard/issues/detail?id=3967

Okay, something to try:

First, back up your database. We will be doing something that might require  
re-loading it back in.


Second, go back in the Python shell and do:

>>> from django_evolution.models import Version
>>> v = Version.objects.all()[0]
>>> print v

At that point, it should say "Hinted version, updated on 2015-02-12  
02:23:19+00:00". If it doesn't, stop, and let me know.


Then do:

>>> v.delete()

Then repeat the rb-site upgrade.

--
You received this message because this project is configured to send all  
issue notifications to this address.

You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.


Re: Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard

Updates:
Status: Fixed

Comment #8 on issue 3967 by chip...@gmail.com: upgrade from 2.0.18 to  
2.0.20 get error

https://code.google.com/p/reviewboard/issues/detail?id=3967

Glad to hear it! :)

We've seen this in a couple of cases, but it's very unclear why it's  
happening.


--
You received this message because this project is configured to send all  
issue notifications to this address.

You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.


Re: Issue 3967 in reviewboard: upgrade from 2.0.18 to 2.0.20 get error

2015-09-14 Thread reviewboard


Comment #7 on issue 3967 by shirph...@126.com: upgrade from 2.0.18 to  
2.0.20 get error

https://code.google.com/p/reviewboard/issues/detail?id=3967

Thanks you very very very much, It works now.


from django_evolution.models import Version
v = Version.objects.all()[0]
print v

Hinted version, updated on 2015-02-12 02:23:19+00:00

v.delete()



yihuihu@shreview02:/var/www$ sudo rb-site upgrade /var/www/reviewboard/
[sudo] password for yihuihu:
Rebuilding directory structure
Updating database. This may take a while.

The log output below, including warnings and errors,
can be ignored unless upgrade fails.

--  --
Creating tables ...
Installing custom SQL ...
Installing indexes ...
Installed 0 object(s) from 0 fixture(s)
No evolution required.
---  ---

Resetting in-database caches.

Upgrade complete!


--
You received this message because this project is configured to send all  
issue notifications to this address.

You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.