Search Unity

Bug Error 400 while fetching overrides on WebGL

Discussion in 'Matchmaker' started by MarcoZVincenzi, Feb 8, 2024.

  1. MarcoZVincenzi

    MarcoZVincenzi

    Joined:
    Mar 3, 2022
    Posts:
    17
    We are using GSH Multiplay 1.1.0 and Matchmaker 1.1.2 on our WebGL project. When creating a matchmaking ticket, in the browser console we get the following error:

    [Matchmaker]: Error while fetching overrides: code=400, message='HTTP/1.1 400 Bad Request'

    This never appears on the Editor, only on a WebGL client that uses WSS (tested on Chrome and Firefox).
    After the error is thrown, howerver, the ticket is created correctly and matchmaking continues smoothly, which is why we've ignored it for the longest time.

    Looking through the source code, it seems to be thrown inside of ABRemoteConfig -> RefreshGameOverridesAsync, where a POST fails with either an HTTP or Network error.
    RefreshGameOverridesAsync itself is called in the CreateTicketAsync method, but only under a UGS_MATCHMAKER_ANALYTICS preprocessor define.

    Code (CSharp):
    1.  
    2. #if UGS_MATCHMAKER_ANALYTICS
    3.     await m_abRemoteConfig.RefreshGameOverridesAsync();
    4. #endif
    5.  
    The AB- prefix in the class name makes me think this is an AB Testing tool of some sort, used by Unity Matchmaking itself, where some data is sent to their servers but gets blocked by the browser (pure speculation on my part tho).
    Does anyone know how to fix it? This doesn't really hinder our connection flow, but it'd be nice to get rid of console errors on the final build.

    Any help would be appreciated, thanks!
     
  2. guillaumedUnity

    guillaumedUnity

    Unity Technologies

    Joined:
    Apr 1, 2021
    Posts:
    36
    Hi, out of curiosity are you using the Analytics SDK ?
     
  3. MarcoZVincenzi

    MarcoZVincenzi

    Joined:
    Mar 3, 2022
    Posts:
    17
    Yes, we do use UnityAnalytics if that's what you mean. Could it be related to this? We initialize it with UnityServices.InitializeAsync(options) on the same GSH Environment well before the matchmaking starts.
     
    Last edited: Apr 15, 2024
  4. MarcoZVincenzi

    MarcoZVincenzi

    Joined:
    Mar 3, 2022
    Posts:
    17
    Update: we changed the connection flow, and now the error also appears in the Editor, where I can confirm it's coming from ABRemoteConfig.cs. We are not using A/B testing overrides in any of the matchmaker queues. Can I somehow stop the client from trying to check for A/B testing configurations?