Kong / Kong/insomnia

substring-after in Xpath filter

Open
#6,673 3 comments 0 reactions 0 assignees View on GitHub
B-bug S-verified
Dominant language
TypeScript
Stars
40k
Forks
2.4k
Avg merge
2d 13h
Merged PRs (30d)
61

Description

### Expected Behavior

I try to set a filter for a tag. I have a url and I want to use substring-after to get a specific part of it.

I'm using this string

`substring-after(/*/*/@href, "rollouts/")`

and it is valid regarding xpather.com
![image](https://github.com/Kong/insomnia/assets/6458997/7a4f6ea7-5695-4ce3-91c2-280014a08d8d)

### Actual Behavior

What I get is the error message.

`TypeError: H.filter is not a function`

![image](https://github.com/Kong/insomnia/assets/6458997/a2d19985-077a-46f1-b234-049b07a26554)

I think it's not a bug but I'm missing something. Can anyone help?

### Reproduction Steps

_No response_

### Is there an existing issue for this?

- [X] I have searched the [issue tracker](https://www.github.com/Kong/insomnia/issues) for this problem.

### Additional Information

_No response_

### Insomnia Version

8.20

### What operating system are you using?

macOS

### Operating System Version

macOS 14.0

### Installation method

updated in insomnia

### Last Known Working Insomnia version

_No response_

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the XPath filter from the report in Insomnia 8.20, using `substring-after(/*/*/@href, "rollouts/")`, and capture the `TypeError: H.filter is not a function` failure. Compare the behavior with a simpler tag filter and establish the expected result before identifying the relevant filter-handling entry point.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.