vscode-httpyac icon indicating copy to clipboard operation
vscode-httpyac copied to clipboard

HttpBook executes wrong line

Open col-panic opened this issue 8 months ago • 4 comments

I have the following http code file:

/*
# User Management API v1
see http://localhost:8080/q/swagger-ui/

https://httpyac.github.io/guide/assert.html
*/
/*
## `localdev` environment only
Perform these tasks to prepare the localdev environment. These executions are expected to fail on second call.
*/
### Delete Administrator user
DELETE {{endpoint_api_v1}}/user/Administrator
Authorization: openid password
?? status == 204
### List available roles
GET {{endpoint_api_v1}}/user/list-available-roles
Authorization: openid password
?? status == 200
###
GET {{endpoint_api_v1}}/user
Authorization: openid password
?? status == 200
###
POST {{endpoint_api_v1}}/user
Authorization: openid password
Content-Type: application/json
{
		"id": "mikemccurry",
		"firstName": "Michael",
		"familyName": "McCurry",
		"email": "[email protected]",
		"associatedContactId": "",
		"aoboMandatorIds": [],
		"roles": [
            "user"
        ],
		"groups": []
	}⏎   

When executing the second cell by pressing Execute Cell, it executes the first one, as can be seen in the following screenshot

Image

Why is that?

col-panic avatar May 06 '25 08:05 col-panic

Maybe the problem is related to this ## localdev environment only line

col-panic avatar May 06 '25 08:05 col-panic

It somehow seems to break when using the second https://httpyac.github.io/guide/metaData.html#title type, that is ### my title

col-panic avatar May 06 '25 11:05 col-panic

probably because my parser misinterprets it with the region separator.

AnWeber avatar May 06 '25 11:05 AnWeber

Maybe its not considering /* markdown */ correctly, to differentiate between markdown and http areas?

col-panic avatar May 06 '25 12:05 col-panic