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

fixing the indexing #4615

Merged
merged 5 commits into from Sep 7, 2018
Merged

Conversation

@safwanrahman
Copy link
Member

@safwanrahman safwanrahman commented Sep 6, 2018

@ericholscher It should fix the search indexing!

Copy link
Member

@ericholscher ericholscher left a comment

Looks good after lint fixes. 👍

Loading

Copy link
Member

@ericholscher ericholscher left a comment

Loading

data = {
'app_label': app_label,
'model_name': model_name,
'document_class': document_class,
'index_name': index_name,
'objects_id': list(chunk)
'objects_id': chunk
Copy link
Member

@ericholscher ericholscher Sep 6, 2018

Choose a reason for hiding this comment

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

This should be named chunk I think?

Loading

@ericholscher
Copy link
Member

@ericholscher ericholscher commented Sep 6, 2018

I think we probably need to support both a list of object ID's for normal running, and also a start/end for reindexing perhaps

Loading

@safwanrahman
Copy link
Member Author

@safwanrahman safwanrahman commented Sep 6, 2018

@ericholscher Oops! I missed that!
updated to support both chunk and objects id.

Loading

def index_objects_to_es(app_label, model_name, document_class, index_name,
chunk=None, objects_id=None):

assert not chunk and objects_id, "You can not pass both chunk and objects_id"
Copy link
Member

@ericholscher ericholscher Sep 6, 2018

Choose a reason for hiding this comment

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

Think this needs a (chunk and objects_id) to apply not properly.

Loading

Copy link
Member Author

@safwanrahman safwanrahman Sep 6, 2018

Choose a reason for hiding this comment

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

Sorry! my bad!

Loading

Copy link
Member Author

@safwanrahman safwanrahman Sep 6, 2018

Choose a reason for hiding this comment

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

@ericholscher fixed!

Loading

@ericholscher ericholscher merged commit 3ca137c into readthedocs:search_upgrade Sep 7, 2018
1 check failed
Loading
@ericholscher
Copy link
Member

@ericholscher ericholscher commented Sep 7, 2018

👍

Loading

safwanrahman added a commit to safwanrahman/readthedocs.org that referenced this issue Sep 15, 2018
safwanrahman added a commit to safwanrahman/readthedocs.org that referenced this issue Sep 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants