Page MenuHomePhabricator

Timezone offset is invalid is back with NaN
Closed, ResolvedPublic

Description

Looks like we ran into this here T380741: Fix "The 'timeZoneOffset' field is invalid" bug where the offset was 0.8[long]

Now we are getting it with NaN

{"status":400,"errorCode":"702","message":"The 'timeZoneOffset' field is invalid. Failed to parse [NaN] as Integer","errorType":"validation"}

Outbound data: '{"amount":{"currency":"EUR","value":1560},"reference":"229279016.1","paymentMethod":{"encryptedCardNumber":"long","encryptedExpiryYear":"long","encryptedSecurityCode":"longer","type":"scheme","holderName":"**"},"merchantAccount":"WikimediaDonations","additionalData":{"manualCapture":true},"returnUrl":"https:\/\/payments.wikimedia.org\/index.php?title=Special:AdyenCheckoutGatewayResult&order_id=229279016.1&wmf_token=e855b34771b795acf0944ba39ee618cf%2B%5C&amount=15.60&currency=EUR&payment_method=cc&payment_submethod=visa&wmf_source=B2425_031916_enIT_dsk_p2_sm_twn_twin2_optIn1.no-LP.cc&wmf_campaign=WMF_FR_C2425_enIT_dsk&wmf_medium=sitenotice","origin":"https:\/\/payments.wikimedia.org","channel":"Web","browserInfo":{"userAgent":"Mozilla\/5.0 (X11; Linux x86_64; rv:136.0) Gecko\/20100101 Firefox\/136.0","acceptHeader":"application\/json, text\/javascript, *\/*; q=0.01","language":"en-IT","colorDepth":"24","screenHeight":"1026","screenWidth":"1898","timeZoneOffset":"NaN","javaEnabled":"false"},"shopperEmail":"**,"shopperIP":"","shopperName":{"firstName":"*","lastName":"***"},"billingAddress":{"city":"NA","country":"IT","houseNumberOrName":"","postalCode":"0","stateOrProvince":"NA","street":"N0NE PROVIDED"},

Event Timeline

XenoRyet triaged this task as High priority.Apr 7 2025, 7:34 PM

Change #1144613 had a related patch set uploaded (by Damilare Adedoyin; author: Damilare Adedoyin):

[mediawiki/extensions/DonationInterface@master] Ensure Math.floor does not pass NaN value to timezone offset.

https://gerrit.wikimedia.org/r/1144613

Checked the logs and found this transaction as the only occurence of this error, perhaps it was a onetime issue that adyen has fixed. However, I went ahead to push up a patch to check for NaN values before setting the time_zone_offset.

Change #1144613 merged by jenkins-bot:

[mediawiki/extensions/DonationInterface@master] Ensure Math.floor does not pass NaN value to timezone offset.

https://gerrit.wikimedia.org/r/1144613

XenoRyet set Final Story Points to 1.