Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6.0 Feedback: Blank page shown for robots with a number sign (#) in their name #10672

Closed
SyntaxColoring opened this issue Jun 8, 2022 · 2 comments
Assignees
Labels
6.0-feedback Feedback for the 6.0 release app Affects the `app` project bug

Comments

@SyntaxColoring
Copy link
Contributor

SyntaxColoring commented Jun 8, 2022

Overview

As noticed by @mcous in #10559 (review):

Hashes in robot names break the UI quite badly

  • Even with renaming, the app treats names as robot identifiers
  • These identifiers go in URLs, because the app is a web UI
  • Hashes mean something specific in URLs, so robot names with hashes are mangled when routes are parsed, and you will not be able to navigate to the robot in question to fix the name

Steps To Reproduce

Rename a robot to have # somewhere in its name.

The Opentrons App's Rename button will currently disallow # characters for reasons that I believe are unrelated to this bug. So, to do this, you'll need to manually issue an HTTP request:

POST /server/name

{"name": "Foo # Bar"}

Current Behavior

When a robot has a # in its name, it appears properly on the Devices page.

Screen Shot 2022-06-08 at 5 34 51 PM

But when you select it, you get this blank page. Note how the name in the breadcrumbs is wrong, too.

Screen Shot 2022-06-08 at 5 34 54 PM

Expected Behavior

The app should be able to handle arbitrary Unicode robot names, including URL-unsafe characters.

(By "handle," I mean the robot's name shouldn't affect functionality. It's certainly fine to have display limitations that require stuff like sanitizing weird characters out of the name, or truncating the name to a maximum length.)

Operating system

macOS.

Robot setup or anything else?

No response

@SyntaxColoring SyntaxColoring added app Affects the `app` project 6.0-feedback Feedback for the 6.0 release labels Jun 8, 2022
@SyntaxColoring
Copy link
Contributor Author

SyntaxColoring commented Jun 8, 2022

The # character in particular is meaningful because it's what Avahi normally uses to deconflict when multiple devices on the network have the same name. For example, MyRobot would become MyRobot #2.

As discussed in #10559, for the 6.0 release, we're going to work around this by taking care on the server side to avoid exposing names with # characters. But we'll need to fix this in the app eventually in our quest to enable arbitrary Unicode names.

@SyntaxColoring SyntaxColoring changed the title 6.0 Feedback: Robots with a number sign (#) in their name are mishandled 6.0 Feedback: Blank page shown for robots with a number sign (#) in their name Jun 8, 2022
@vabruzzo vabruzzo self-assigned this Jul 26, 2022
@SyntaxColoring
Copy link
Contributor Author

Migrated to RSS-488.

@SyntaxColoring SyntaxColoring closed this as not planned Won't fix, can't repro, duplicate, stale Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.0-feedback Feedback for the 6.0 release app Affects the `app` project bug
Projects
None yet
Development

No branches or pull requests

4 participants