In Drupal 8 an E-mail field type has been added to core (#1668332: Add an E-mail field type into core). Comparing to the contrib Email field module in D7, the database column for the field value was renamed from 'email' to 'value'. Furthermore the contrib module comes with a few extended field formatters, like a contact form, spamspan and invisimail, which will stay in contrib for D8.

The open question is whether Drupal core is going to include the upgrade path, or if an upgrade module should be provided by contrib. Upgrading the data shouldn't be that hard (renaming all database columns), but what should happen with formatters that are not provided by core? Either leave them as they are (and thus broken) or map them to the default formatter.

CommentFileSizeAuthor
#7 drupal8.email-upgrade.6.patch1.11 KBsun
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

klonos’s picture

Title: Upgrade path for the email field module » D7 -> D8 upgrade path for the email field module

...minor title edit.

sun’s picture

Title: D7 -> D8 upgrade path for the email field module » Provide a basic upgrade path for the D7 E-mail field module
Category: task » feature
Issue tags: +Upgrade path, +D8 upgrade path

I think that the 90% use-case of the contrib module was a bare e-mail field -- without any of the obfuscation formatters and the contact pages.

So I think it would make sense to provide an upgrade path that checks for existing email field types and if there are any, just renames the database schema column.

Anything else would be left to the contrib module (which needs a new project/namespace now).

mh86’s picture

I totally agree with that. Spamspan and invisimail are already separated contrib modules, and the contact formatter can be moved to a standalone module as well, and someone who is really interested in it can take it over.

webchick’s picture

I would actually be tempted to move this issue to email module wholesale. Core is generally not in the habit of providing upgrade paths for data it did not previously store.

sun’s picture

@webchick: Unless I'm mistaken, we provided a basic upgrade path for the D6 CCK field types that were moved into core for D7?

Dave Reid’s picture

No we never did.

sun’s picture

Status: Active » Needs review
FileSize
1.11 KB
Dave Reid’s picture

The column name itself is not the only thing that is different. The contrib email.module defines a maxlength of 255, while this defines a maxlength of 254.

Dave Reid’s picture

Issue summary: View changes

...minor edit to clarify that it's not *the* email.module that got imported to core, but rather *a* new email field.

benjy’s picture

Issue summary: View changes
Status: Needs review » Closed (won't fix)

We are now supporting migrating over upgrading and we support the email field type in the migrate api so I think this can be closed.