Skip to content

Excluding Tolls not working as expected #2026

Description

@sridharvenkatesan

I have tried the following code to exclude toll gates. But it is always showing the route with tolls.

NavigationRoute.builder(NavigationMapRouteActivity.this) .accessToken(Mapbox.getAccessToken()) .origin(origin) .alternatives(true) .exclude(DirectionsCriteria.EXCLUDE_TOLL) .destination(destination) .build()

Alternatives also seems not working good. I can't see more than one route in my screen. I thought giving alternatives true will show one or more routes. But it is always showing only one route.

ANDROID API : 24-25
SDK VERSION : 0.41.0

Steps to trigger behavior

  1. Initially don't add the exclude and alternatives to NavigationRoute and check the route
  2. Add the exclude toll and check the route
  3. Now add the alternative true and check the route

Expected behavior

It should not show the route with toll gates and it should provide one or two different routes to the user.

Actual behavior

It is always showing the same route.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugDefect to be fixed.needs discussionCan't be started in current state, needs clarification.

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions