Prechádzať zdrojové kódy

Fix Airbnb GQL variable drift missed by last session's hash update

Updating _HASHES alone isn't enough when a persisted query's variable
schema changes too. Diffed the live HAR capture against each op's
hardcoded variables and found three mismatches:

- getDLSHostCalendar: missing includeCustomSettings, causing the
  ValidationError (data: null) behind the empty/priceless calendar
  warnings.
- ViaductGetThreadAndDataQuery: skipOldMessagePreviewFields renamed
  to getWishlistData.
- CreateBulkMessagesMutation: skipOldMessagePreviewFields dropped
  from this mutation's input entirely.
ZiB 5 dní pred
rodič
commit
c1724fa80d
1 zmenil súbory, kde vykonal 2 pridanie a 2 odobranie
  1. 2 2
      room_cal/service_api/_airbnb.py

+ 2 - 2
room_cal/service_api/_airbnb.py

@@ -259,6 +259,7 @@ class _AirbnbClient(ServiceClientBase):
       'timeZone': self._tz,
       'localizationContext': {'timeZone': self._tz, 'firstDayOfWeek': 0},
       'hostCalendarSectionTypes': ['MAIN_VIEW'],
+      'includeCustomSettings': True,
       'readConsistency': 'EVENTUAL',
     }
     referer = f'https://www.airbnb.com/multicalendar/{self._listing_id}'
@@ -530,7 +531,7 @@ class _AirbnbClient(ServiceClientBase):
         'mockListFooterSlot': None,
         'forceReturnAllReadReceipts': False,
         'originType': 'USER_INBOX',
-        'skipOldMessagePreviewFields': False,
+        'getWishlistData': False,
       },
       f'https://www.airbnb.com/messages/{thread_id}',
     )
@@ -572,7 +573,6 @@ class _AirbnbClient(ServiceClientBase):
         'businessJustification': {'feature': 'USER_INBOX'},
         'originType': 'USER_INBOX',
         'senderPlatform': 'WEB',
-        'skipOldMessagePreviewFields': False,
       },
       f'https://www.airbnb.com/messages/{thread_id}',
     )