Skip to content

Implement 'limit' and 'skip' options in find()#113

Merged
oskardudycz merged 6 commits into
event-driven-io:mainfrom
mat02:main
Jul 2, 2025
Merged

Implement 'limit' and 'skip' options in find()#113
oskardudycz merged 6 commits into
event-driven-io:mainfrom
mat02:main

Conversation

@mat02
Copy link
Copy Markdown
Contributor

@mat02 mat02 commented Jun 27, 2025

This PR introduces support for limit and skip options in the find() query method. These options allow more flexible querying by enabling pagination and result size control.

@oskardudycz
Copy link
Copy Markdown
Contributor

@mat02, that looks good to me, nice work! 🙂

Could you also extend the integration test suite here:

Also, the linter check is failing, are you using VSCode or other IDE? With VSCode linter settings should be automatically taken into an account and applied on save.

If you're open, it'd be nice to also extend Mongo shim and its tests:

@oskardudycz oskardudycz added enhancement New feature or request pongo filtering labels Jun 29, 2025
@mat02
Copy link
Copy Markdown
Contributor Author

mat02 commented Jun 29, 2025

Thanks for the info.
I'm using VS Code, so maybe I have some wrong defaults. Anyway, I will check and fix 👍

I'll look into integration tests and mongo shim next week.

@oskardudycz
Copy link
Copy Markdown
Contributor

I'm using VS Code, so maybe I have some wrong defaults. Anyway, I will check and fix 👍

Might be that some local config takes precedence. in theory, you should get information about recommended plugins (ESlint, Prettier etc.) and by default autofix on save should happen, if it doesn't and the issue is on my side, I'm happy to make it smoother.

It's also possible to run fix through CLI with npm run fix 👍

@mat02
Copy link
Copy Markdown
Contributor Author

mat02 commented Jun 30, 2025

Updated the Mongo shim and extended integration test suite.

The linting issues were on me. I had the linter installed in a Docker container but was editing the files in a VS Code window connected directly to WSL...

@oskardudycz oskardudycz marked this pull request as ready for review July 2, 2025 08:38
Copy link
Copy Markdown
Contributor

@oskardudycz oskardudycz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks @mat02! 🙂

@oskardudycz
Copy link
Copy Markdown
Contributor

Updated the Mongo shim and extended integration test suite.

The linting issues were on me. I had the linter installed in a Docker container but was editing the files in a VS Code window connected directly to WSL...

Thank you for following up, glad that's not on my side 😅

@oskardudycz oskardudycz merged commit 46de917 into event-driven-io:main Jul 2, 2025
1 check passed
@oskardudycz
Copy link
Copy Markdown
Contributor

@mat02, one thing to clarify, the current main code is on the next alpha, which is in the making, would you like me to cherry-pick your changes and release it to the regular version, or are you fine with just releasing it as part of the next alpha?

@mat02
Copy link
Copy Markdown
Contributor Author

mat02 commented Jul 2, 2025

If it's not a problem for you, it would be great to see this published more quickly, as I could progress with my project without having to stub in some custom build.

@oskardudycz
Copy link
Copy Markdown
Contributor

If it's not a problem for you, it would be great to see this published more quickly, as I could progress with my project without having to stub in some custom build.

Yup, it will be a regular publish. Just curious if you're fine with using alpha, or you'd prefer to retrofit it to the regular version?

@mat02
Copy link
Copy Markdown
Contributor Author

mat02 commented Jul 2, 2025

At this stage I'm perfectly fine with alpha as long as there are no drastic changes to the API or logic ;)

@oskardudycz
Copy link
Copy Markdown
Contributor

At this stage I'm perfectly fine with alpha as long as there are no drastic changes to the API or logic ;)

Great, check the newly released 0.17.0-alpha.5 🙂

@oskardudycz oskardudycz added this to the 0.17.0 milestone Sep 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request filtering pongo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants