Open PhilipLund opened 3 years ago
Hey @PhilipLund,
Nothing should have changed on our side, I'll dig in our past commits to make sure I didn't missed anything.
only the first level is returned sometimes the first and the last level.
Do you mean results are inconsistent? Are you using the Async client?
In the meantime, could you please:
Thanks!
Hey This code will only return the first and last level.
` from algoliasearch.search_client import SearchClient import pandas as pd
cols = [ "objectID", "inStock", "searchHierachy", "targetProductType", ]
client = SearchClient.create(application_id, api_key) index = client.init_index(index_name)
records = [] for record in index.browse_objects({"query": "", "attributesToRetrieve": cols}): records.append(record)
df = pd.DataFrame(records) df["lenght"] = df["searchHierachy"].apply(lambda x: len(x.keys())) cols = ["lenght", "searchHierachy"] print(df.sort_values("lenght")[cols]) ` It is inconsistent from what is displayed on the algolia dashboard. I am not using the Async client but have tried different versions (2.3.0, 2.4.0, 2.5.0, 2.6.0)
Description
When updating to version 2.5.0 from 2.4.0 data is missing from the searchHierachy attribute. fetching the data using curl or looking at the Algolia dashboard shows that a product has several search hierarchies but when using the algoliasearch module version 2.5.0 only the first level is returned sometimes the first and the last level.
Steps To Reproduce
Comparing the output of a single search between version 2.4.0 and 2.5.0
Example
Expected response: searchHierachy: { lvl0: [ "Husholdning" ] lvl1: [ "Rengøring" ] lvl2: [ "Rengøringsmidler" ] lvl3: [ "Toilet og bad" ] lvl4: [ "WC-rens" ] lvl5: [ "Toiletrens" ] }
Actual response: searchHierachy: { lvl0: [ "Husholdning" ] lvl5: [ "Toiletrens" ] }