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: Make sure not to crash user search api when search service returns empty dict #503

Merged
merged 2 commits into from
Jul 6, 2020

Conversation

verdan
Copy link
Member

@verdan verdan commented Jul 6, 2020

Summary of Changes

With the changes introduces in this PR: amundsen-io/amundsensearchlibrary#111 , if your user index feature is not implemented in the search i.e., has pass, then the frontend does not work and crashes. This PR will fix this issue.

Tests

Added the corresponding test case!

Documentation

N/A

CheckList

Make sure you have checked all steps below to ensure a timely review.

  • PR title addresses the issue accurately and concisely. Example: "Updates the version of Flask to v1.0.2"
  • PR includes a summary of changes, including screenshots of any UI changes.
  • PR adds unit tests, updates existing unit tests, OR documents why no test additions or modifications are needed.
  • In case of new functionality, my PR adds documentation that describes how to use it.
    • All the public python functions and the classes in the PR contain docstrings that explain what it does
  • PR passes all tests documented in the developer guide

@codecov-commenter
Copy link

codecov-commenter commented Jul 6, 2020

Codecov Report

Merging #503 into master will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #503   +/-   ##
=======================================
  Coverage   81.02%   81.02%           
=======================================
  Files         226      226           
  Lines        5638     5638           
  Branches      666      666           
=======================================
  Hits         4568     4568           
  Misses       1004     1004           
  Partials       66       66           
Impacted Files Coverage Δ
amundsen_application/api/search/v0.py 95.86% <100.00%> (ø)

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 3ee8845...3d9bdd9. Read the comment docs.

@verdan
Copy link
Member Author

verdan commented Jul 6, 2020

@feng-tao can you please review. This PR fixes a crash introduced in the search library.

Copy link
Member

@feng-tao feng-tao left a comment

Choose a reason for hiding this comment

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

thanks @verdan

@feng-tao feng-tao merged commit 89bbf5b into amundsen-io:master Jul 6, 2020
@feng-tao
Copy link
Member

feng-tao commented Jul 6, 2020

@verdan , qq: is it correct that ING has indexed user info into Atlas but didn't implement the search function for user entity?

@verdan
Copy link
Member Author

verdan commented Jul 6, 2020

@feng-tao that is true. We still need to implement the user related features for Atlas. The only reason we enabled the userIndex is to enable the User Profile. But yes, we will be implementing all these features over the time.

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.

3 participants