Skip to content

Commit

Permalink
Merge branch '6.3' into 6.4
Browse files Browse the repository at this point in the history
* 6.3:
  fix #51235 - fix the order of merging of serializationContext and self::CONTEXT_DENORMALIZE
  [HttpClient] Fix Static Code Analyzer issue with JsonMockResponse
  [Messenger] Fix exiting `FailedMessagesRetryCommand`
  [Serializer] Fix reindex normalizedData array in AbstractObjectNormalizer::denormalize()
  [Validator] Fix `File::$extensions`’ PHPDoc
  [Mime] Fix email (de)serialization issues
  [Serializer] Fix parsing XML root node attributes
  fix parsing of payload timestamp to DateTimeImmutable
  Fix routing to multiple fallback transports
  Fix missing stamps in delayed message handling
  [DoctrineBridge] Ignore invalid stores in `LockStoreSchemaListener` raised by `StoreFactory`
  • Loading branch information
nicolas-grekas committed Sep 29, 2023
2 parents 0fef6dc + 2a97911 commit 314ebef
Show file tree
Hide file tree
Showing 10 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions RemoteEvent/MailgunPayloadConverter.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ public function convert(array $payload): AbstractMailerEvent
};
$event = new MailerEngagementEvent($name, $payload['id'], $payload);
}
if (!$date = \DateTimeImmutable::createFromFormat('U.u', $payload['timestamp'])) {
throw new ParseException(sprintf('Invalid date "%s".', $payload['timestamp']));
if (!$date = \DateTimeImmutable::createFromFormat('U.u', sprintf('%.6F', $payload['timestamp']))) {
throw new ParseException(sprintf('Invalid date "%s".', sprintf('%.6F', $payload['timestamp'])));
}
$event->setDate($date);
$event->setRecipientEmail($payload['recipient']);
Expand Down
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/clicks.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521243339.873676));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521243339.873676'));

return $wh;
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/delivered_messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
},
"event-data": {
"id": "CPgfbmQMTCKtHW6uIWtuVe",
"timestamp": 1521472262.908181,
"timestamp": 1521472262.000002,
"log-level": "info",
"event": "delivered",
"delivery-status": {
Expand Down
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/delivered_messages.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521472262.908181));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521472262.000002'));
$wh->setReason('OK');

return $wh;
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/opens.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521243339.873676));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521243339.873676'));

return $wh;
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/permanent_failure.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521233195.375624));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521233195.375624'));
$wh->setReason('No Such User Here');

return $wh;
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/spam_complaints.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521233123.501324));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521233123.501324'));

return $wh;
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/suppression_failure.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521233195.375624));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521233195.375624'));
$wh->setReason('Not delivering to previously bounced address');

return $wh;
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/temporary_failure.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521472262.908181));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521472262.908181'));
$wh->setReason("4.2.2 The email account that you tried to reach is over quota. Please direct\n4.2.2 the recipient to\n4.2.2 https://support.example.com/mail/?p=422");

return $wh;
2 changes: 1 addition & 1 deletion Tests/Webhook/Fixtures/unsubscribes.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
$wh->setRecipientEmail('alice@example.com');
$wh->setTags(['my_tag_1', 'my_tag_2']);
$wh->setMetadata(['my_var_1' => 'Mailgun Variable #1', 'my-var-2' => 'awesome']);
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', 1521243339.873676));
$wh->setDate(\DateTimeImmutable::createFromFormat('U.u', '1521243339.873676'));

return $wh;

0 comments on commit 314ebef

Please sign in to comment.