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

Fix/filter not filtering #319

Merged
merged 14 commits into from
Sep 19, 2024
Merged

Conversation

mosheavni
Copy link
Contributor

fixes #308

@mosheavni
Copy link
Contributor Author

it's because when we're on fallback view, the name is a table rather than a string (on defined views it's always a string):
https://github.com/mosheavni/kubectl.nvim/blob/8d664f366ef9afb3d842ffa3ec33805ba640d9f3/lua/kubectl/views/fallback/definition.lua#L73

then when we need to recuresively drop into name, it's using exact match which is almost never what we want, we want the pattern to be a substring of the field

@Ramilito Ramilito merged commit 5bcf10a into Ramilito:main Sep 19, 2024
1 check passed
@Ramilito
Copy link
Owner

Nice catch, do you have any idea why I couldn't replicate the bug??

@mosheavni
Copy link
Contributor Author

I think if you search for a substring of some field in the fallback view, you wouldn't see it, only if it's exactly the same name

@mosheavni mosheavni deleted the fix/filter-not-filtering branch September 19, 2024 11:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

filter does not work when switching from pod to ingress view
2 participants