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

Prevent duplicated result rendering when searching in default datasets #6765

Merged

Conversation

christian-monch
Copy link
Contributor

This PR Fixes #6763

This commit disables the result renderer in a recursive call to Dataset.search(). This recursive call is used when no dataset to search through is found and the default super-dataset, i.e. /// is used.

When the result renderer in the recursive call was not disabled, each result was reported twice.

Changelog

🐛 Bug Fixes

This commit disables the result renderer in a
recursively called 'ds.search()' because the result
will be rendered by the caller.
@christian-monch christian-monch added the semver-internal Changes only affect the internal API label Jun 14, 2022
@codecov
Copy link

codecov bot commented Jun 14, 2022

Codecov Report

Merging #6765 (f667010) into maint (d157c3c) will decrease coverage by 1.03%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##            maint    #6765      +/-   ##
==========================================
- Coverage   91.17%   90.14%   -1.04%     
==========================================
  Files         354      354              
  Lines       44612    44691      +79     
==========================================
- Hits        40677    40286     -391     
- Misses       3935     4405     +470     
Impacted Files Coverage Δ
datalad/metadata/search.py 89.00% <100.00%> (ø)
datalad/version.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/plugin/wtf.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/cmdline/main.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/plugin/addurls.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/interface/clean.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/interface/rerun.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/plugin/__init__.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/plugin/no_annex.py 0.00% <0.00%> (-100.00%) ⬇️
datalad/cmdline/__init__.py 0.00% <0.00%> (-100.00%) ⬇️
... and 60 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d157c3c...f667010. Read the comment docs.

@yarikoptic yarikoptic changed the title Prevent multiple result rendering when searching in default datasets Prevent duplicated result rendering when searching in default datasets Jun 14, 2022
@yarikoptic
Copy link
Member

Thank you @christian-monch ! I will release with this.

@yarikoptic yarikoptic added the release Create a release when this pr is merged label Jun 14, 2022
@yarikoptic yarikoptic merged commit ef7fe7d into datalad:maint Jun 14, 2022
@github-actions
Copy link

🚀 PR was released in 0.16.6 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release Create a release when this pr is merged released semver-internal Changes only affect the internal API
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants