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

sqlite,src: refactor sqlite value conversion #57571

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

geeksilva97
Copy link
Contributor

@geeksilva97 geeksilva97 commented Mar 21, 2025

This PR is a minor refactor on converting SQLite values to JS. It makes the work for #56600 easier and reduces duplication.

@nodejs-github-bot
Copy link
Collaborator

Review requested:

  • @nodejs/sqlite

@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. needs-ci PRs that need a full CI run. sqlite Issues and PRs related to the SQLite subsystem. labels Mar 21, 2025
Copy link

codecov bot commented Mar 21, 2025

Codecov Report

Attention: Patch coverage is 87.50000% with 1 line in your changes missing coverage. Please review.

Project coverage is 90.23%. Comparing base (1de917b) to head (94276bc).
Report is 45 commits behind head on main.

Files with missing lines Patch % Lines
src/node_sqlite.cc 87.50% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #57571      +/-   ##
==========================================
- Coverage   90.23%   90.23%   -0.01%     
==========================================
  Files         629      630       +1     
  Lines      184903   185009     +106     
  Branches    36223    36221       -2     
==========================================
+ Hits       166853   166944      +91     
- Misses      11010    11038      +28     
+ Partials     7040     7027      -13     
Files with missing lines Coverage Δ
src/node_sqlite.cc 78.20% <87.50%> (-0.29%) ⬇️

... and 66 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@geeksilva97 geeksilva97 added the request-ci Add this label to start a Jenkins CI on a PR. label Mar 21, 2025
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Mar 21, 2025
@nodejs-github-bot
Copy link
Collaborator

@Renegade334
Copy link
Contributor

Is this "returning function body macro" paradigm used elsewhere? Appreciate the rationale, but it seems like it lends potential for future mishaps?

@geeksilva97
Copy link
Contributor Author

but it seems like it lends potential for future mishaps?

For this, specifically, I don't think so. This type conversion is unlikely to change. We need to find a way to isolate this anyways since it's being required more and more.

@geeksilva97 geeksilva97 added the request-ci Add this label to start a Jenkins CI on a PR. label Mar 22, 2025
@geeksilva97 geeksilva97 force-pushed the sqlite-refactor-conversion-type branch from 6cf644e to 2611aa7 Compare March 24, 2025 20:44
@geeksilva97 geeksilva97 requested review from cjihrig and jasnell March 25, 2025 18:05
@geeksilva97 geeksilva97 added author ready PRs that have at least one approval, no pending requests for changes, and a CI started. request-ci Add this label to start a Jenkins CI on a PR. and removed request-ci Add this label to start a Jenkins CI on a PR. labels Mar 25, 2025
Copy link
Contributor

@cjihrig cjihrig left a comment

Choose a reason for hiding this comment

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

LGTM with one minor comment.

@geeksilva97 geeksilva97 removed the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Mar 26, 2025
@geeksilva97 geeksilva97 self-assigned this Mar 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ Issues and PRs that require attention from people who are familiar with C++. needs-ci PRs that need a full CI run. request-ci Add this label to start a Jenkins CI on a PR. sqlite Issues and PRs related to the SQLite subsystem.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants