Hi,

I'm migrating events from a Drupal 7 site to another Drupal 7 site, using the Migrate module.

I've noticed that, in my case, dates with repeat rules are not migrated properly. What happens is the following:

Assume that in the source site I have an event with start date June 5 2014, which repeats every week during 3 weeks. When the migrate code runs for such a date, I will end up with an even starting on June 26 2014, with the same repeat rule.

The reason for this is that the dates instances are rebuilt EVERY TIME for each date instance. The patch that I will attach should explain things better, I hope.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

guillaumev’s picture

Status: Active » Needs review
FileSize
1.35 KB

Here is the patch.

Status: Needs review » Needs work

The last submitted patch, 1: 2280551-date_migrate-1.patch, failed testing.

guillaumev’s picture

Status: Needs work » Needs review
FileSize
2.39 KB

I actually found another issue with the date migration class: timezones do not seem to be handled properly. Values that come out of the legacy database are treated with whatever timezone the site you are migrating to has set, while they should be treated as UTC, given that they are in UTC.

The following patch fixes this. I will try to see later why tests are failing.

Status: Needs review » Needs work

The last submitted patch, 3: 2280551-date_migrate-3.patch, failed testing.