Skip to content

feat: add text_search #215

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

Merged
merged 6 commits into from
Feb 19, 2023
Merged

feat: add text_search #215

merged 6 commits into from
Feb 19, 2023

Conversation

J0
Copy link
Contributor

@J0 J0 commented Feb 12, 2023

Add text_search as per js spec

See #191 for details

TODO

  • add tests

@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Feb 12, 2023

Sourcery Code Quality Report

❌  Merging this PR will decrease code quality in the affected files by 1.12%.

Quality metrics Before After Change
Complexity 0.59 ⭐ 0.75 ⭐ 0.16 👎
Method Length 36.59 ⭐ 37.47 ⭐ 0.88 👎
Working memory 5.09 ⭐ 5.29 ⭐ 0.20 👎
Quality 88.82% 87.70% -1.12% 👎
Other metrics Before After Change
Lines 1188 1260 72
Changed files Quality Before Quality After Quality Change
postgrest/_async/request_builder.py 80.44% ⭐ 78.76% ⭐ -1.68% 👎
postgrest/_sync/request_builder.py 80.49% ⭐ 78.80% ⭐ -1.69% 👎
tests/_async/test_request_builder.py 93.83% ⭐ 93.82% ⭐ -0.01% 👎
tests/_sync/test_request_builder.py 93.83% ⭐ 93.82% ⭐ -0.01% 👎

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
postgrest/_async/request_builder.py AsyncSelectRequestBuilder.text_search 4 ⭐ 116 🙂 10 😞 62.91% 🙂 Extract out complex expressions
postgrest/_sync/request_builder.py SyncSelectRequestBuilder.text_search 4 ⭐ 116 🙂 10 😞 62.91% 🙂 Extract out complex expressions
postgrest/_async/request_builder.py AsyncRequestBuilder.upsert 0 ⭐ 60 ⭐ 13 😞 69.70% 🙂 Extract out complex expressions
postgrest/_sync/request_builder.py SyncRequestBuilder.upsert 0 ⭐ 60 ⭐ 13 😞 69.70% 🙂 Extract out complex expressions
postgrest/_async/request_builder.py AsyncRequestBuilder.insert 0 ⭐ 54 ⭐ 11 😞 73.95% 🙂 Extract out complex expressions

Legend and Explanation

The emojis denote the absolute quality of the code:

  • ⭐ excellent
  • 🙂 good
  • 😞 poor
  • ⛔ very poor

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!

@codecov
Copy link

codecov bot commented Feb 12, 2023

Codecov Report

Base: 91.99% // Head: 91.37% // Decreases project coverage by -0.63% ⚠️

Coverage data is based on head (1c938c6) compared to base (29cb042).
Patch coverage: 72.22% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #215      +/-   ##
==========================================
- Coverage   91.99%   91.37%   -0.63%     
==========================================
  Files          23       23              
  Lines        1112     1148      +36     
==========================================
+ Hits         1023     1049      +26     
- Misses         89       99      +10     
Impacted Files Coverage Δ
postgrest/_async/request_builder.py 79.61% <64.28%> (-2.42%) ⬇️
postgrest/_sync/request_builder.py 86.40% <64.28%> (-3.48%) ⬇️
tests/_async/test_request_builder.py 100.00% <100.00%> (ø)
tests/_sync/test_request_builder.py 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@J0 J0 marked this pull request as ready for review February 19, 2023 11:30
@J0 J0 merged commit 0d16b47 into master Feb 19, 2023
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.

1 participant