Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@jertel
Copy link
Contributor

@jertel jertel commented Mar 14, 2023

Describe the change
The default value for the mime_db file must be None in order for it to use the default database file in the /usr tree. Defaulting to an empty string "" causes Magic to throw an exception due to a missing file at that empty path.

This likely only affects users that need to generate the config file via yaml formatters that are unable to convert None to null.

I did not create an issue. Let me know if you'd like one created and linked to this PR.

Describe testing procedures
Start the backend container with the tasting.mime_db setting deleted from the backend config file. The container will crash. Pull the fixed image and start a new container, still with the deleted setting. The container should not crash, and should start up normally.

Sample output
N/A

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of and tested my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

@phutelmyer
Copy link
Contributor

Thanks @jertel for your contribution :) This is a great catch call out. I've tested this and it works as intended.

@phutelmyer phutelmyer merged commit 3384e1f into target:master Mar 24, 2023
@phutelmyer phutelmyer added the bug Something isn't working label Mar 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants