10up / ElasticPress

A fast and flexible search and query engine for WordPress.
https://elasticpress.io
GNU General Public License v2.0
1.25k stars 313 forks source link

QUESTION: Unable to modify search results with ElasticPress Custom Results #2602

Closed cmoa-webmaster closed 2 years ago

cmoa-webmaster commented 2 years ago

Unable to modify existing ElasticPress Custom Results

Hello,

I was attempting to reorder search results for our ElasticSearch, but I am unable to do so? I made sure to enable "Custom Search Results" and add and apply custom search results. I attached images to help further explain the issue. I am using it with Wordpress, specifically Elasticpress Version 3.6.6.

Any information would be appreciated, or if you need anymore from me I can provide. I attempted to clear cache, but I am not sure what else to do.

Screen Shot 2022-02-18 at 3 26 41 PM Screen Shot 2022-02-18 at 3 26 31 PM Screen Shot 2022-02-18 at 3 26 13 PM
brandwaffle commented 2 years ago

@cmoa-webmaster thanks for filing the report! Before I get into some deeper debugging, could you try re-titling the Custom Results post with all lowercase (i.e. lowercase the 'c' and 'i') and then see if the search matches? I'm thinking this could be related to the different cases having different ASCII character mapping. If that's not it, there are some more steps we can go through to debug.

cmoa-webmaster commented 2 years ago

@brandwaffle apologies for this. I will be testing this Monday. Only editors can touch content like that title, so I need their permission first. Thanks for your quick response though! I will get back to you asap.

cmoa-webmaster commented 2 years ago

Hello @brandwaffle I misread that originally, but still no success https://cmoa.org/?s=58th+carnegie+international

Screen Shot 2022-02-21 at 9 21 30 AM Screen Shot 2022-02-21 at 9 21 38 AM
cmoa-webmaster commented 2 years ago

If you need anymore information, please ask. Would it be better for me to create a test page that you would recommend to test the search results?

felipeelia commented 2 years ago

Hey @cmoa-webmaster,

Can you please install Debug Bar and Debug Bar ElasticPress plugins, refresh that screen and share with us both the Query Body and the Query Results that will be available in the Debug -> ElasticPress item in the admin bar? Thanks!

cmoa-webmaster commented 2 years ago

Hello @felipeelia I have the results below. If you need anything else, please let me know.

Screen Shot 2022-02-28 at 10 23 58 AM Screen Shot 2022-02-28 at 10 25 16 AM Screen Shot 2022-02-28 at 10 26 35 AM

{ "took": 17, "timed_out": false, "_shards": { "total": 5, "successful": 5, "skipped": 0, "failed": 0 }, "hits": { "total": 3, "max_score": 0.11437348, "hits": [ { "_index": "cmoaorg-post-1", "_type": "post", "_id": "14517", "_score": 0.11437348, "_source": { "post_id": 14517, "ID": 14517, "post_author": { "raw": "bohannonj", "login": "bohannonj", "display_name": "Jordan Bohannon", "id": 26 }, "post_date": "2021-06-18 10:28:20", "post_date_gmt": "2021-06-18 14:28:20", "post_title": "58th Carnegie International", "post_excerpt": "The 58th Carnegie International is coming to Pittsburgh on September 24, 2022. Established in 1896, the Carnegie International is the longest-running North American exhibition of international art, second globally only to the Venice Biennale. ", "post_content_filtered": "

n", "post_content": "", "post_status": "publish", "post_name": "58-carnegie-international", "post_modified": "2022-01-18 14:34:12", "post_modified_gmt": "2022-01-18 19:34:12", "post_parent": 0, "post_type": "exhibition", "post_mime_type": "", "permalink": "https://cmoa.org/exhibition/58-carnegie-international/", "terms": { "departments": [ { "term_id": 3, "slug": "contemporary-arts", "name": "Contemporary Arts", "parent": 0, "term_taxonomy_id": 3, "term_order": 0 } ], "series": [ { "term_id": 9, "slug": "carnegie-international", "name": "Carnegie International", "parent": 0, "term_taxonomy_id": 9, "term_order": 0 } ], "locations": [ { "term_id": 81, "slug": "carnegie-museum-of-art", "name": "Carnegie Museum of Art", "parent": 0, "term_taxonomy_id": 81, "term_order": 0 } ] }, "meta": { "inline_featured_image": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "tab_bar": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "open_by_default": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "is_sticky": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hero_type": [ { "value": "image", "raw": "image", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hero_link": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hide_credit": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hero_image": [ { "value": "14319", "raw": "14319", "long": 14319, "double": 14319, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "lead_message": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "start_date": [ { "value": "20220924", "raw": "20220924", "long": 20220924, "double": 20220924, "boolean": false, "date": "2022-09-24", "datetime": "2022-09-24 04:00:00", "time": "04:00:00" } ], "end_date": [ { "value": "20230402", "raw": "20230402", "long": 20230402, "double": 20230402, "boolean": false, "date": "2023-04-02", "datetime": "2023-04-02 04:00:00", "time": "04:00:00" } ], "exhibition_images": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "gallery_texts": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "installation_views": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "multimedias": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "checklists": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "exhibition_credits": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "related_items_heading": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "related_items_count": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "related_items": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "sponsorship_sections": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ] }, "date_terms": { "year": 2021, "month": 6, "week": 24, "dayofyear": 168, "day": 18, "dayofweek": 5, "dayofweek_iso": 5, "hour": 14, "minute": 28, "second": 20, "m": 202106 }, "comment_count": 0, "comment_status": "closed", "ping_status": "closed", "menu_order": 0, "guid": "https://cmoa.org/?post_type=exhibition&p=14517" } }, { "_index": "cmoaorg-post-1", "_type": "post", "_id": "15834", "_score": 0.096204355, "_source": { "post_id": 15834, "ID": 15834, "post_author": { "raw": "bohannonj", "login": "bohannonj", "display_name": "Jordan Bohannon", "id": 26 }, "post_date": "2021-11-30 10:53:40", "post_date_gmt": "2021-11-30 15:53:40", "post_title": "Artist Workshop u2014 James "Yaya" Hough", "post_excerpt": "", "post_content_filtered": "

Please join artist James u201cYayau201d Hough for an art-making workshop and conversation about the ways that public art can share stories of the past, present, and future of our neighborhoods. This participatory workshop will contribute to Hough’s creation of a new mural on Centre Avenue commissioned for the 58th Carnegie International.

n

The workshop will meet in the Ford Mateer Classroom, which is just inside the museum’s Portal Entry at the rear of the building. No registration is required and all are encouraged to participate.

n

About the Artist

n

James “Yaya” Hough (b. 1974, Pittsburgh, PA) lives and works in Pittsburgh, PA. For over a decade, Hough has been heavily involved with Mural Arts Philadelphia. Since working with Mural Arts, Hough has created over 50 works that have been installed in Philadelphia, State Correctional Institution Graterford, and State Correctional Institution Phoenix. In 2019, as a part of a program supported by the Art for Justice Fund and Fair and Just Prosecution, Hough was selected to be the inaugural Artist-in-Residence at the Office of the District Attorney of Philadelphia. Currently, Houghu2019s work is included in Marking Time: Art in the Age of Mass Incarceration, curated by Dr. Nicole R. Fleetwood, at the Abroms-Engel Institute for the Visual Arts, Birmingham, AL, which traveled from MoMA PS1, Queens, NY.

n", "post_content": "

Please join artist James u201cYayau201d Hough for an art-making workshop and conversation about the ways that public art can share stories of the past, present, and future of our neighborhoods. This participatory workshop will contribute to Hough's creation of a new mural on Centre Avenue commissioned for the 58th Carnegie International.

rnrn

The workshop will meet in the Ford Mateer Classroom, which is just inside the museum's Portal Entry at the rear of the building. No registration is required and all are encouraged to participate.

rnrn

About the Artist

rn

James "Yaya" Hough (b. 1974, Pittsburgh, PA) lives and works in Pittsburgh, PA. For over a decade, Hough has been heavily involved with Mural Arts Philadelphia. Since working with Mural Arts, Hough has created over 50 works that have been installed in Philadelphia, State Correctional Institution Graterford, and State Correctional Institution Phoenix. In 2019, as a part of a program supported by the Art for Justice Fund and Fair and Just Prosecution, Hough was selected to be the inaugural Artist-in-Residence at the Office of the District Attorney of Philadelphia. Currently, Houghu2019s work is included in Marking Time: Art in the Age of Mass Incarceration, curated by Dr. Nicole R. Fleetwood, at the Abroms-Engel Institute for the Visual Arts, Birmingham, AL, which traveled from MoMA PS1, Queens, NY.

", "post_status": "publish", "post_name": "artist-workshop-james-yaya-hough", "post_modified": "2021-12-10 15:18:22", "post_modified_gmt": "2021-12-10 20:18:22", "post_parent": 0, "post_type": "ai1ec_event", "post_mime_type": "", "permalink": "https://cmoa.org/event/artist-workshop-james-yaya-hough/", "terms": { "locations": [ { "term_id": 81, "slug": "carnegie-museum-of-art", "name": "Carnegie Museum of Art", "parent": 0, "term_taxonomy_id": 81, "term_order": 0 } ], "events_categories": [ { "term_id": 129, "slug": "carnegie-international", "name": "Carnegie International", "parent": 0, "term_taxonomy_id": 129, "term_order": 0 }, { "term_id": 168, "slug": "free-programs", "name": "Free Programs", "parent": 0, "term_taxonomy_id": 168, "term_order": 0 }, { "term_id": 29, "slug": "workshops", "name": "Workshops", "parent": 0, "term_taxonomy_id": 29, "term_order": 0 } ] }, "meta": { "inline_featured_image": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "is_sticky": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hero_type": [ { "value": "image", "raw": "image", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hero_link": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hide_credit": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "hero_image": [ { "value": "15892", "raw": "15892", "long": 15892, "double": 15892, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "related_items_heading": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "related_items_count": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "related_items": [ { "value": "a:1:{i:0;s:5:"14224";}", "raw": "a:1:{i:0;s:5:"14224";}", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "sponsorship_sections": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "date_display": [ { "value": "Dec. 11, 2021", "raw": "Dec. 11, 2021", "boolean": false, "date": "2021-12-11", "datetime": "2021-12-11 00:00:00", "time": "00:00:00" } ], "hidden": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "excerpt": [ { "value": "Join artist James u201cYayau201d Hough for an art-making workshop and conversation about the ways that public art can share stories of the past, present, and future of our neighborhoods.", "raw": "Join artist James u201cYayau201d Hough for an art-making workshop and conversation about the ways that public art can share stories of the past, present, and future of our neighborhoods.", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "registration_information": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "event_status": [ { "value": "confirmed", "raw": "confirmed", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "ticket_availability": [ { "value": "on_sale", "raw": "on_sale", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ], "ai1ec_banner_image": [ { "value": "", "raw": "", "boolean": false, "date": "1971-01-01", "datetime": "1971-01-01 00:00:01", "time": "00:00:01" } ] }, "date_terms": { "year": 2021, "month": 11, "week": 48, "dayofyear": 333, "day": 30, "dayofweek": 2, "dayofweek_iso": 2, "hour": 10, "minute": 53, "second": 40, "m": 202111 }, "comment_count": 0, "comment_status": "open", "ping_status": "closed", "menu_order": 0, "guid": "https://cmoa.org/?post_type=ai1ec_event&p=15834" } }, { "_index": "cmoaorg-post-1", "_type": "post", "_id": "7795", "_score": 0.08978865, "_source": { "post_id": 7795, "ID": 7795, "post_author": { "raw": "cmoa", "login": "cmoa", "display_name": "Webmaster", "id": 2 }, "post_date": "2019-09-09 14:23:41", "post_date_gmt": "2019-09-09 18:23:41", "post_title": "Upcoming Exhibitions", "post_excerpt": "", "post_content_filtered": "
An empty marble hall.
Hall of Sculpture. Photo: Bryan Conley
n

58th Carnegie International

n", "post_content": "[caption id="attachment_14319" align="alignnone" width="600"]An empty marble hall. Hall of Sculpture. Photo: Bryan Conley[/caption]rn

58th Carnegie International

", "post_status": "publish", "post_name": "upcoming", "post_modified": "2021-08-09 10:27:47", "post_modified_gmt": "2021-08-09 14:27:47", "post_parent": 239, "post_type": "page", "post_mime_type": "", "permalink": "https://cmoa.org/exhibitions/upcoming/", "terms": [], "meta": { "tab_bar": [ { "value": "4672", "raw": "4672", "long": 4672, "double": 4672, "boolean": false, "date": "4672-02-21", "datetime": "4672-02-21 09:19:06", "time": "09:19:06" } ], "sidebar_sections": [ { "value": "1", "raw": "1", "long": 1, "double": 1, "boolean": true, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "open_by_default": [ { "value": "1", "raw": "1", "long": 1, "double": 1, "boolean": true, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_heading": [ { "value": "Other Installations and Projects", "raw": "Other Installations and Projects", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_blocks_0_block_image": [ { "value": "7527", "raw": "7527", "long": 7527, "double": 7527, "boolean": false, "date": "7527-02-21", "datetime": "7527-02-21 09:19:06", "time": "09:19:06" } ], "sidebar_sections_0_section_blocks_0_block_title": [ { "value": "Hillman Photography Initiative", "raw": "Hillman Photography Initiative", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_blocks_0_block_url": [ { "value": "https://cmoa.org/art/hillman-photography-initiative/", "raw": "https://cmoa.org/art/hillman-photography-initiative/", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_blocks_0_block_content": [ { "value": "Through collaboration, the museum connects audiences to exchange new ideas about photography.", "raw": "Through collaboration, the museum connects audiences to exchange new ideas about photography.", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_blocks": [ { "value": "2", "raw": "2", "long": 2, "double": 2, "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "hero_type": [ { "value": "image", "raw": "image", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "hero_link": [ { "value": "", "raw": "", "boolean": false } ], "hide_credit": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false } ], "hero_image": [ { "value": "", "raw": "", "boolean": false } ], "sponsorship_sections": [ { "value": "", "raw": "", "boolean": false } ], "inline_featured_image": [ { "value": "0", "raw": "0", "long": 0, "double": 0, "boolean": false } ], "sidebar_sections_0_section_blocks_1_block_image": [ { "value": "14319", "raw": "14319", "long": 14319, "double": 14319, "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_blocks_1_block_title": [ { "value": "Carnegie International", "raw": "Carnegie International", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_blocks_1_block_url": [ { "value": "https://cmoa.org/58-carnegie-international/", "raw": "https://cmoa.org/58-carnegie-international/", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ], "sidebar_sections_0_section_blocks_1_block_content": [ { "value": "Explore what it means to be u201cinternationalu201d at this moment in time.", "raw": "Explore what it means to be u201cinternationalu201d at this moment in time.", "boolean": false, "date": "1970-01-01", "datetime": "1970-01-01 00:00:01", "time": "00:00:01" } ] }, "date_terms": { "year": 2019, "month": 9, "week": 37, "dayofyear": 251, "day": 9, "dayofweek": 1, "dayofweek_iso": 1, "hour": 14, "minute": 23, "second": 41, "m": 201909 }, "comment_count": 0, "comment_status": "closed", "ping_status": "closed", "menu_order": 0, "guid": "http://cmoa.org/?page_id=7795" } } ] }, "aggregations": { "terms": { "doc_count": 3, "resource_levels": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "resource_subjects": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "associated_artists": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "events_tags": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "learning_levels": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "post_format": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "learning_series": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "events_categories": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [ { "key": "carnegie-international", "doc_count": 1 }, { "key": "free-programs", "doc_count": 1 }, { "key": "workshops", "doc_count": 1 } ] }, "ep_custom_result": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "series": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [ { "key": "carnegie-international", "doc_count": 1 } ] }, "media_category": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "locations": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [ { "key": "carnegie-museum-of-art", "doc_count": 2 } ] }, "post_status": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "departments": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [ { "key": "contemporary-arts", "doc_count": 1 } ] }, "category": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "curators": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] }, "post_tag": { "doc_count_error_upper_bound": 0, "sum_other_doc_count": 0, "buckets": [] } } } }

cmoa-webmaster commented 2 years ago

@felipeelia can I help debug this in anymore ways?

felipeelia commented 2 years ago

hi @cmoa-webmaster , you sent us the results but not sent the query body. Do you mind sending that too? In cases where a huge amount of code needs to be shared, we recommend you to create a pastebin in pastebin.com, so it'll be easier to read. Thanks

cmoa-webmaster commented 2 years ago

@felipeelia Sorry for the delay. I have the Pastebin here: https://pastebin.com/YdwbJcRh For the various sections like Header, I labeled the sections like "START OF QUERY ARGS" and "END OF QUERY ARGS" so you could easily search within the data for a section that you want.

Let me know if you need anymore data or if there is anything more that I can do to help debug this.

felipeelia commented 2 years ago

Hi @cmoa-webmaster, The Custom Results functionality is based on a taxonomy named ep_custom_result. Terms of that taxonomy are applied to the chosen posts in custom results, so they appear in the search results set. That doesn't seem to be happening with your content.

That said it is likely you have an underlying problem indexing your content. Would it be possible to you to run a full resync and check for any errors? For that, you can index using WP-CLI (run wp elasticpress index --setup --yes --show-errors) or, if you've upgraded to 4.0 already, go to the Sync page, click on the Delete all Data and Start a Fresh Sync, then on "Show logs" and check the errors tab.

Can you please do one of those procedures and let us know the output? Thanks!

github-actions[bot] commented 2 years ago

This issue has been automatically closed because there has been no response to our request for more information. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further. See this blog post on bug reports and the importance of repro steps for more information about the kind of information that may be helpful.

cmoa-webmaster commented 2 years ago

Hi @cmoa-webmaster, The Custom Results functionality is based on a taxonomy named ep_custom_result. Terms of that taxonomy are applied to the chosen posts in custom results, so they appear in the search results set. That doesn't seem to be happening with your content.

That said it is likely you have an underlying problem indexing your content. Would it be possible to you to run a full resync and check for any errors? For that, you can index using WP-CLI (run wp elasticpress index --setup --yes --show-errors) or, if you've upgraded to 4.0 already, go to the Sync page, click on the Delete all Data and Start a Fresh Sync, then on "Show logs" and check the errors tab.

Can you please do one of those procedures and let us know the output? Thanks!

Hello,

So I upgraded to Elasticpress 4 specifically 4.0.1 and noticed a permission error Found out I don't have permission to run sync against our third party self hosted elasticsearch instance. Still trying to fix it.

felipeelia commented 2 years ago

No problem @cmoa-webmaster. Did the permission error come from a change we made in the plugin or something that changed in your setup? Thanks!

cmoa-webmaster commented 2 years ago

So we were using self hosted for our elasticsearch instance. The permissions were readonly via kibana. To further complicate our issue, our site search data was mixed with our records database. We also don't have the login for kibana. So it would likely break the current process. This doesn't help that our records database went widely undocumented and the git log is unreadable.

TLDR; The issue wasn't from your plugin but due to our permission of readonly I can't reset the current elasticsearch instance. That is probably for the best since it is mixed with another database of our record data. My guess is this was done due to cost.

Thank you for your help debugging this @felipeelia

felipeelia commented 2 years ago

Got it @cmoa-webmaster. Well, looking to the half-full glass, at least you were able to identify those issues! :) I'm going ahead and closing the issue out now, feel free to leave a comment if you have any additional follow up and we can reopen it if needed.

cmoa-webmaster commented 2 years ago

True @felipeelia Thanks for your debugging help with these issues.

cmoa-webmaster commented 2 years ago

@felipeelia Hey again. So I wanted to start off by saying that I spun up and successfully connected a new elasticsearch version 7.17.3 to our development website. Possibly that it is a bit newer of a version could be the issue, but I have not been able to sync it properly. I have the full log from the /wp-admin side here when trying to run a sync here: https://pastebin.com/2biqa9e5 but when I run a normal Delete all data and sync, it appears to sync successfully.

I also ran the sync with the wp-cli command as you recommend way earlier within this message chain and I have the pastebin here: https://pastebin.com/SLDe51tt I am wondering if advanced custom fields is somehow causing this issue.

<img width="902" alt="Screen Shot 2022-05-24 at 9 59 29 AM" src="https://user

Screen Shot 2022-05-24 at 11 24 31 AM

-images.githubusercontent.com/9203439/170076043-1e3667ff-31b1-47d1-819c-7

Screen Shot 2022-05-24 at 11 24 40 AM

98679017e97.png">

If you have any suggestions or if you would like for me to provide anymore log messages or run commands, please let me know? I really appreciate your help so far. Just a note ES_SHIELD I defined in our wp-config.php file again. It appears to have been an env variable in a hidden dot file. I commented it out, but it still appears to exist magically probably in cache somewhere. I am not exactly sure how to obliterate it completely. I have tried several methods via command line, but no luck. I can't even echo out ES_SHIELD in anyway.

brandwaffle commented 2 years ago

@cmoa-webmaster helping to troubleshoot custom Elasticsearch endpoints is something we can support, but unfortunately only through our hourly consulting. This is especially true given the version of Elasticsearch you're using is not yet supported by ElasticPress, and the fact that there seems to be other application(s) running in your Elasticsearch environment. You can learn more about our consulting here https://www.elasticpress.io/elasticpress-consulting/. Please note that we're unable to provide additional support via ElasticPress.io since your trial was canceled.

cmoa-webmaster commented 2 years ago

@brandwaffle No problem! I completely understand. I just may consider it. I wanted to use ElasticPress.io really bad, but it wouldn't connect to my instance. My theory was that our existing ES_SHIELD credential was being passed. Possibly since I was able to figure out how to override the constant on my end, I would be able to pass my username and password to elasticpress.io elasticsearch.

I am not sure if this helps, but it appears the elasticpress plugin repo had documentation at one point on how to pass ES_SHIELD so a username and password was sent with the given method. It appears those docs were removed.