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

Unable to escape underscore #421

Closed
fgblomqvist opened this issue Mar 7, 2018 · 3 comments
Closed

Unable to escape underscore #421

fgblomqvist opened this issue Mar 7, 2018 · 3 comments

Comments

@fgblomqvist
Copy link

fgblomqvist commented Mar 7, 2018

Example

+ Request (application/json)
    + Attributes
        + api_key: `<API_KEY>` (string, required)

Gets parsed like this:
screenshot from 2018-03-07 12-20-19

(Dredd also reads it in the same way, so it is definitely the parser that is wrong)

@kylef
Copy link
Member

kylef commented Mar 7, 2018

You will need to escape the underscore, for example:

+ Request (application/json)
    + Attributes
        + `api_key`: `<API_KEY>` (string, required)

@fgblomqvist
Copy link
Author

Ah, didn't realize that it was the first underscore that was causing the issue. Apiary should imo catch that as a semantic issue: "Attribute names that include underscores need to be escaped with backticks" or something along those lines.

@kylef
Copy link
Member

kylef commented Jan 10, 2019

I'm going to close this issue as it's tracked in #210.

@kylef kylef closed this as completed Jan 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants