Skip to content

Is anyone using Beanie with AWS DocumentDB? #441

Answered by eze1981
eze1981 asked this question in Question
Discussion options

You must be logged in to vote

Hi all,

I solved this issue by overriding the BeaniBaseUser internal Settings class. Here you have an example to remove the collation configuration:

class User(BeanieBaseUser[PydanticObjectId]):
    first_name: Optional[str]
    last_name: Optional[str]
    affiliation: Optional[str]
    studies: list = []
    
    class Settings:
        email_collation = None
        indexes = [
            IndexModel("email", unique=True)
        ]

    pass

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@amirsalaar
Comment options

@eze1981
Comment options

Answer selected by eze1981
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants