default_content icon indicating copy to clipboard operation
default_content copied to clipboard

Consider to be able to update existing content

Open dawehner opened this issue 9 years ago • 5 comments

Did you considered to support updating existing content?

Otherwise at least we should catch whether a specific UUID already exists. At the moment though you end up with something like:

SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'd8416a46-1dd2-4348-9c00-c77581037a60' for key 'taxonomy_term_field__uuid__value':    [error]
INSERT INTO {taxonomy_term_data} (vid, uuid, langcode) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2); Array
(
    [:db_insert_placeholder_0] => tags
    [:db_insert_placeholder_1] => d8416a46-1dd2-4348-9c00-c77581037a60
    [:db_insert_placeholder_2] => und
)

which is not optimal, for sure.

dawehner avatar Aug 29 '14 13:08 dawehner

+1 to this idea.

jibran avatar Aug 29 '14 19:08 jibran

+1 to throw sane exception. I'm not sure it makes sense to update content because the module for initial content import

andypost avatar Aug 31 '14 11:08 andypost

Well, during the development of sites, having some update mechanism would be quite useful, to be honest.

dawehner avatar Aug 31 '14 12:08 dawehner

Agree exactly but suppose this "content ci" should be a part of migrate or entity storage. @dawehner could you explain/elaborate your vision of usage of update/reimport?

andypost avatar Aug 31 '14 12:08 andypost

Agree we should catch exception, should be easy to test, install module, uninstall module, reinstall, boom

larowlan avatar Aug 31 '14 21:08 larowlan