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

The DBBACKUP_DATABASES configuration is ignored. #497

Open
pifantastic opened this issue Nov 29, 2023 · 0 comments
Open

The DBBACKUP_DATABASES configuration is ignored. #497

pifantastic opened this issue Nov 29, 2023 · 0 comments

Comments

@pifantastic
Copy link

Bug Report

Please help us help you by filling out any applicable information in this template and removing the rest!

Describe the bug

The DBBACKUP_DATABASES configuration is ignored. This is due to a bug in this line of code:

database_keys = self.database.split(",") or settings.DATABASES

If a -d option is not given, this code will always evaluate to [''], with the result that default is the database chosen.

To Reproduce

  • Configure DBBACKUP_DATABASES to use a non default database`
  • python manage.py dbbackup
  • Note that the database that is backed up is defaul, not the database specified by DBBACKUP_DATABASES

Expected behavior

The dbbackup command should backup the databases configure in DBBACKUP_DATABASES

Screenshots or reproduction

If applicable, add screenshots (errors, example of the behavior, etc.) to help explain your problem or post a link to a repository that replicates the issue.

Versions

Django-dbbackup

  • pypi: 4.0.2

External tools

  • Python: 3.11.6
  • Django: 4.1.13
  • OS: MacOS
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

No branches or pull requests

2 participants