Skip to content

bug: "TypeError: Cannot read properties of undefined (reading 'value')" when clicking on Workspace Preset currently already selected #16953

Closed
@jingyuanliang

Description

@jingyuanliang

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

No response

Relevant Log Output

TypeError: Cannot read properties of undefined (reading 'value')
    at https://coder/assets/CreateWorkspacePage-tcxUJeQU.js:2:7226
    at Hy (https://coder/assets/index-CbAGGasI.js:48:24296)
    at zu (https://coder/assets/index-CbAGGasI.js:48:42451)
    at gie (https://coder/assets/index-CbAGGasI.js:48:41273)
    at pl (https://coder/assets/index-CbAGGasI.js:48:40312)
    at ZD (https://coder/assets/index-CbAGGasI.js:48:36913)
    at Gs (https://coder/assets/index-CbAGGasI.js:46:3288)
    at https://coder/assets/index-CbAGGasI.js:48:34286

Expected Behavior

No response

Steps to Reproduce

  1. Create a template with workspace presets
  2. Try to create a workspace using the template
  3. In the "Select a preset to get started" dropdown, expand then choose the currently selected item (e.g. None)
  4. Frontend shows "Something went wrong"

Environment

  • Host OS: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36
  • Coder version: v2.20.1

Additional Context

I have tested this on the latest version

Metadata

Metadata

Assignees

Labels

s2Broken use cases or features (with a workaround). Only humans may set this.

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions