Skip to content

Setting appearance without a color fails silently #8187

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

Closed
1 of 2 tasks
code-asher opened this issue Jun 24, 2023 · 0 comments · Fixed by #9004
Closed
1 of 2 tasks

Setting appearance without a color fails silently #8187

code-asher opened this issue Jun 24, 2023 · 0 comments · Fixed by #9004
Assignees
Labels
s2 Broken use cases or features (with a workaround). Only humans may set this. site Area: frontend dashboard

Comments

@code-asher
Copy link
Member

code-asher commented Jun 24, 2023

Reproduction:

  1. Start a brand new deployment.
  2. Open appearance settings.
  3. Toggle enabled and add a message. Do not touch the color.
  4. Submit.

Behavior:

Nothing happens. Checking the network request reveals:

{
    "message": "parse color: expected 7 characters:\n    github.com/coder/coder/enterprise/coderd.validateHexColor\n        /home/coder/coder/enterprise/coderd/appearance.go:114"
}

After manually setting the color submitting always works. It is just that first request where we are not sending any color.

Solution:

  • Surface errors
  • Set default color if none yet
@code-asher code-asher added the site Area: frontend dashboard label Jun 24, 2023
@cdr-bot cdr-bot bot added the bug label Jun 24, 2023
@matifali matifali added the s2 Broken use cases or features (with a workaround). Only humans may set this. label Jun 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
s2 Broken use cases or features (with a workaround). Only humans may set this. site Area: frontend dashboard
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants