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: disable trust provider for PostGres db #1536

Merged

Conversation

swizzmagik
Copy link
Contributor

Relates to:

  • Issues reported by using of crashes due to this error Error in trust score provider: Cannot read properties of undefined (reading 'prepare')

Risks

  • low risk

Background

  • Many users in discord have reported this error when using the Solana plugin and PostGres db. The trust provider tries to run but fails because the TrustScoreDatabase only works with Sqllite.

What does this PR do?

  • Prevents the error from occurring by adding a check for Postgres and logging a warning instead of crashing

What kind of change is this?

  • bug fix

Why are we doing this? Any context or related work?

  • Allow users of PostGres to utilize Solana and Starknet plugin

Documentation changes needed?

  • No

Testing

  • Set up a PostGres Connection
  • Activate the Solana plugin
  • Ask the agent questions about recommendations such as 'Should I buy SOL?'

BEFORE

Error in trust score provider: Cannot read properties of undefined (reading 'prepare')

AFTER

skipping trust evaluator because db is postgres

@swizzmagik swizzmagik changed the base branch from main to develop December 28, 2024 15:13
@odilitime
Copy link
Collaborator

well it's better than what we have, but much rather see postgres support

@swizzmagik
Copy link
Contributor Author

This should be a simple fix and will unblock some folks with further development.

@odilitime odilitime merged commit 6c388cd into elizaOS:develop Jan 3, 2025
5 checks passed
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.

2 participants