Skip to content

Webots bridge crashes when teleop core receives multiple frontend mounts #19

Description

@MNikoliCC

Summary

teleop-pro on main can pass multiple frontend mounts to the public teleop core so the backend can serve the operator UI at /, the operator alias at /teleop, and the spectator TV UI at /tv.

The current local teleop core on feature-multi-arm expects frontend_dir to be a single string path. When teleop-pro passes the mount list, the Webots bridge crashes during backend startup.

Observed error

TypeError: expected str, bytes or os.PathLike object, not list

Stack:

File ".../backend/__init__.py", line 40, in __init__
  self.teleop = Teleop(...)
File ".../teleop/teleop/__init__.py", line 306, in __setup_routes
  assets_dir = os.path.join(self.__frontend_dir, "assets")

Expected behavior

The core teleop.Teleop serving hook should remain backward compatible with a single frontend directory and also support a list of (mount_path, frontend_dir) pairs.

Acceptance criteria

  • frontend_dir="/path/to/dist" still serves the legacy core UI at /.
  • frontend_dir=[("/", operator), ("/teleop", operator), ("/tv", tv)] serves each frontend and its assets correctly.
  • /ws and product routers continue to work unchanged.
  • teleop-pro setup docs specify the required teleop branch or commit containing this support.

Notes

A local compatibility patch was tested successfully by normalizing frontend mounts in teleop.Teleop and mounting assets at /assets, /teleop/assets, and /tv/assets.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    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