Asp.Net Web Api trailing / causing odata query to fail

I am using HttpClient to query the WebApi controller using the below code:

        var uri = new Uri(url);
        var message = new HttpRequestMessage(method, uri);
        if (content != null) message.Content = new StringContent(content, Encoding.UTF8, "application/json");

        var client = new HttpClient();
        if (content != null) Debug.WriteLine($"Payload:\n {content}");
        var response = await client.SendAsync(message);
        return response;

The generated Url is as below:
http://localhost:9333/api/roles?$filter=%20Name%20eq%20’Some%20Role’/

Note the trailing ‘/’. This causes the OData Validation (code below) to fail:

    [HttpGet]
    [Route("")]
    public async Task<IHttpActionResult> GetRoles(ODataQueryOptions<RoleSummaryDto> options)
    {
        GuardForODataException(options);

        var filteredResults = await _roleService.GetRolesAsync(options);
        return Ok(filteredResults);

    }

    public void GuardForODataException<T>(ODataQueryOptions<T> options)
    {
        try
        {
            var validationSettings = new ODataValidationSettings();
            options.Validate(validationSettings);
        }
        catch (Exception e)
        {

            var result =
                new ValidationFailedResult(
                    Request,
                        new ValidationResultModel(
                            new ValidationResult(
                                new List<ValidationFailure> { new ValidationFailure("", "Odata Query is invalid") })));

            throw new HttpResponseException(result.ExecuteAsync(default(CancellationToken)).Result);
        }
    }

The exception I am getting is

“An identifier was expected at position 9.”

If however, I remove the trailing /, then the odata query returns the expected results.

I wasn’t able to find much on how to construct a HttpRequestMessage without the / at the end. Has anyone encountered this before?