Skip to content

Hyphens in variable names cause ExpressionEvaluationException #122

Closed
@KaVeKa

Description

@KaVeKa

Describe the bug

When using variable names containing hyphens, executing a call does not succeed anymore due to an io.jetclient.exception.ExpressionEvaluationException.
The complete error displayed in the UI is:
Unresolved expressions: user-agent (io.jetclient.exception.ExpressionEvaluationException: Cannot evaluate binary operation with non-evaluated operands)

Autocompleting the variable in the input field still works as expected.
image

Steps to reproduce

  1. Create a global variable with a hyphen ( e.g. user-agent )
  2. Use this variable inside an http request header ( e.g. {{user-agent}} )
  3. Error occurs.

Expected behavior
The error should not occur and the call should be successful as always was the case in previous versions of JetClient.

Environment information:

  • OS: Windows
  • IDE version: 2024.3 Build #IU-243.21565.193
  • plugin version: 2024.3.19-243

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions