Attempted to enable both Views and Views UI at once, with the attached error. Modules list showed that Views enable had completed, and Views UI enabled correctly on the second attempt - the failure was only on simultaneous install. Replicated twice more after disabling both.
DatabaseSchemaObjectExistsException: Table views_view already exists. in DatabaseSchema->createTable() (line 544 of /home/d7/includes/database/schema.inc).
The website encountered an unexpected error. Please try again later.
Linux ccserver 2.6.26-2-686 #1 SMP Sat Dec 26 09:01:51 UTC 2009 i686 GNU/Linux
memory_limit 128M
Comments
Comment #1
marcvangendI can confirm this bug, just tested with the latest D7 and Views from CVS. Definitely not minor IMO, enabling both Views and Views UI is a very common thing to do and the error message doesn't provide any clue about what to do next.
Comment #2
dawehnerMh.
What do you do to install views?
I deinstalled views. Then i enabled views and views_ui and it worked fine
PS: I'm using the latest dev.
Comment #3
dawehnerOh i tested on an old core version.
Comment #4
marcvangendI tried again just to make sure. Steps:
- get latest D7 HEAD from CVS
- install with standard profile
- checkout Views (branch DRUPAL-7--3) from CVS into /sites/all/modules/views
- opened the modules page
- checked the Views and Views UI modules and clicked 'Save configuration'
Result: The error message mentioned earlier.
When going back to the modules page, Views was enabled, but Views UI was not. When checking Views UI again and saving the configuration, Views UI was properly enabled.
I was able to trigger the error again by disabling both modules (first UI, then Views) and enabling them again simultaneously.
Comment #5
dawehnerViews does not do something special here. For me this is a drupal core bug. It seams to be, that the schema for views is created two times.
There was a patch which removes checking of already created tables
Comment #6
marcvangendDereine, you're right, it's a core issue. Enabling Coder and Coder Review simultaneously returns a similar error:
I'm marking this as critical. While it doesn't completely break the module page, we really shouldn't ship D7 with a bug like this.
Comment #7
David_Rothstein commentedIn Drupal 7, modules are not supposed to install their own schema: http://drupal.org/node/224333#install-schema
I haven't actually tested this patch, but I expect it should work. Looks like there should be a similar issue filed against the Coder module?
Comment #8
dawehnerThanks!
I tested the patch, it worked fine
Comment #9
marcvangendThanks for the fix. I assume Coder had the same issue, but I noticed I wasn't using the latest dev version. I just updated Coder and the issue is fixed already.
Comment #11
geosmaga commentedquick option: I just deleted the tables from db then enable the two modules one by one and is working fine.