Skip to content

core: do not trim spaces on value returned by getInput #339

@myitcv

Description

@myitcv

Describe the bug

As I raised over in the community forums, the core package trims the value returned by getInput:

return val.trim()

I might well be missing something here, but I consider this a bug because it precludes leading/trailing spaces from ever being significant in input values. If the the caller of getInput wants to trim space on the value returned, they can make that decision. As things stand, leading/trailing spaces can never be significant in input values.

This puts input values at odds with environment variables on Linux and macOS (at least).

Please can someone provide the motivation behind this decision?

Thanks

To Reproduce

n/a

Expected behavior

Per above description.

Screenshots

n/a

Desktop (please complete the following information):

n/a

Smartphone (please complete the following information):

n/a

Additional context

None

Metadata

Metadata

Labels

bugSomething isn't workingcore

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions