Known Issues

Error when trying to join a race

This can occur when some data for your race are not defined. For instance, if you refresh the page on the Selection screen, your race mode (Training, Free, Tournament) will not be defined, and you will get this error.

If this happens to you, simply click on the Play button from the menu at the top of the page to get back to the Mode screen and you will be able to launch your race without issue this time.

Transaction to join race fails

Two different types of failed transactions can happen. They are not yet handled in the frontend so this is a bit annoying, but fortunately, shouldn't happen often.

This seems to happen when 2 players start a race at the same time. For some reason, the callback from Chainlink VFR fails with this error: OutOfGas

That goes without saying, but if one of the three Chainlink subscriptions we are using runs out of funds, Fury Racing won't work as expected anymore!

The weather update is hardcoded for the Monaco track

By lack of time, the weather update has been hardcoded to the Monaco circuit, only track available for now. The update is triggered every hour by Chainlink Automation calling the requestWeatherUpdate() function below.

```solidity
/**
 * @notice Request the real-time weather score via Chainlink Functions
 * Chainlink Automation will call this function every 1 hour
 */
function requestWeatherUpdate() public onlyForwarder returns (bytes32 _requestId) {
    FunctionsRequest.Request memory req;
    req.initializeRequestForInlineJavaScript(FunctionsSource.getWeatherScore());

    // Send the request and store the request ID
    _requestId =
        _sendRequest(req.encodeCBOR(), FUNCTIONS_SUBSCRIPTION_ID, FUNCTIONS_GAS_LIMIT, DON_ID);

    requestIdToFunctionsRequests[_requestId] = FunctionsRequests({
        fulfilled: false,
        exists: true,
        requestType: RequestType.WEATHER_SCORE,
        results: new uint256[](0)
    });

    return _requestId;
}
```

This function is then calling an API via Chainlink Functions.

The logic below in the callback from Chainlink Functions needs to be slightly adjusted to allow weather updates for multiple tracks at the same time.

```solidity
if (_request.requestType == RequestType.WEATHER_SCORE) {
    uint256 weatherScore = abi.decode(response, (uint256));
    _request.results = new uint256[](1);
    _request.results[0] = weatherScore;
    
    requestIdToFunctionsRequests[requestId] = _request;
    _updateWeatherDataForCircuit(uint256(1), weatherScore); // Hardcoded to 1 (Monaco)
    emit WeatherResultFulfilled(requestId, _request.results);
```

The car starts drifting after a window change

When the race is ongoing, if you switch windows and come back to the race, the car may appear to be drifting on the road instead of driving straight!

Last updated