mem0 icon indicating copy to clipboard operation
mem0 copied to clipboard

data source model uses "type" not "data_type"

Open amber-beasley-liatrio opened this issue 1 year ago • 2 comments

🐛 Describe the bug

Impacted versions: >= 1.8.2

Description:

There seems to be a bug in the get_data_sources() method. It eventually tried to get the "data_type" attribute but that throws a no attribute error.

I believe this is the release that introduced the bug: https://github.com/embedchain/embedchain/releases/tag/0.1.82

The model for the data uses "type" but the method that pulls the data is using "data_type"

When bug was introduced: PR: https://github.com/embedchain/embedchain/pull/1273/files#diff-d494029527663b5dde22e3dc804d17421db5bdc6cdf0d191d3cb294e18aaaff4R16

Code:

  • "type": https://github.com/embedchain/embedchain/blob/6518c0c06bc32a0163c0c7407c400cf18a883df2/embedchain/core/db/models.py#L16
  • "date_type": https://github.com/embedchain/embedchain/blob/6518c0c06bc32a0163c0c7407c400cf18a883df2/embedchain/app.py#L298

Recreate bug:

  • create app and db
  • add data sources with data_type specified
  • run the app.get_data_sources() method --> attribute error

amber-beasley-liatrio avatar Feb 29 '24 15:02 amber-beasley-liatrio

I saw same

davidtheITguy avatar Mar 02 '24 00:03 davidtheITguy

Fix for me in version 0.1.90 See release note https://github.com/embedchain/embedchain/releases/tag/0.1.90

PhilFlash avatar Mar 02 '24 13:03 PhilFlash