Debian Patches

Status for python-magic/2:0.4.27-6

Patch Description Author Forwarded Bugs Origin Last update
cherry-picked/0.4.27-1-gf3ab085.add-magic-1-dll-to-the-list-of-dll-files-to-search-for-on-windows.patch Add "magic-1.dll" to the list of DLL files to search for on Windows
This is the name of the DLL file generated when using vcpkg to build libmagic:
https://github.com/microsoft/vcpkg/tree/master/ports/libmagic
valpogus <32718480+valpogus@users.noreply.github.com> not-needed upstream, commit 0.4.27-1-gf3ab085 <https://github.com/ahupp/python-magic/commit/0.4.27-1-gf3ab085> 2022-06-16
cherry-picked/0.4.27-3-gcc0c587.corrected-the-command-for-the-test-for-python3.patch Corrected the command for the test for python3 ekko <gar001300@gmail.com> not-needed upstream, commit 0.4.27-3-gcc0c587 <https://github.com/ahupp/python-magic/commit/0.4.27-3-gcc0c587> 2022-10-22
cherry-picked/0.4.27-5-gcd3929f.added-path-for-local-homebrew-installation-267.patch Added path for local homebrew installation (#267)
* added path for local homebrew installation
* used brew --prefix to detect local path
Manuele <57706020+manvento@users.noreply.github.com> not-needed upstream, commit 0.4.27-5-gcd3929f <https://github.com/ahupp/python-magic/commit/0.4.27-5-gcd3929f> 2022-10-24
cherry-picked/0.4.27-6-gea2150d.add-python-3-10-to-tox-environment-list.patch Add python 3.10 to tox environment list Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-6-gea2150d <https://github.com/ahupp/python-magic/commit/0.4.27-6-gea2150d> 2022-10-24
cherry-picked/0.4.27-7-g05fde96.further-update-readme-for-test-running-changes.patch Further update README for test running changes Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-7-g05fde96 <https://github.com/ahupp/python-magic/commit/0.4.27-7-g05fde96> 2022-10-24
cherry-picked/0.4.27-8-g3794a39.docker-test-cleanup.patch Docker test cleanup Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-8-g3794a39 <https://github.com/ahupp/python-magic/commit/0.4.27-8-g3794a39> 2022-10-24
cherry-picked/0.4.27-9-g4ffcd59.update-test-for-upstream-added-gzip-extensions.patch Update test for upstream added gzip extensions Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-9-g4ffcd59 <https://github.com/ahupp/python-magic/commit/0.4.27-9-g4ffcd59> 2023-01-09
cherry-picked/0.4.27-10-gb805925.dont-run-coverage-by-default-in-tox-config.patch Don't run coverage by default in tox config Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-10-gb805925 <https://github.com/ahupp/python-magic/commit/0.4.27-10-gb805925> 2023-01-10
cherry-picked/0.4.27-11-gc7a2e7b.remove-python3-ism-from-loader.patch Remove python3-ism from loader Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-11-gc7a2e7b <https://github.com/ahupp/python-magic/commit/0.4.27-11-gc7a2e7b> 2023-01-10
cherry-picked/0.4.27-12-gc7642f0.chore-tests-add-python-3-10-and-3-11-in-ci-runs-tox-trove-classifier-284.patch Chore(tests): add Python 3.10 and 3.11 in CI runs/tox/trove classifier (#284) Stevie Gayet <87695919+stegayet@users.noreply.github.com> not-needed upstream, commit 0.4.27-12-gc7642f0 <https://github.com/ahupp/python-magic/commit/0.4.27-12-gc7642f0> 2023-01-23
cherry-picked/0.4.27-13-ge0052c5.bump-to-0-4-28.patch Bump to 0.4.28 Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-13-ge0052c5 <https://github.com/ahupp/python-magic/commit/0.4.27-13-ge0052c5> 2023-03-23
cherry-picked/0.4.27-14-g7cde785.revert-remove-python3-ism-from-loader.patch Revert "remove python3-ism from loader"
This reverts commit c7a2e7bc7c387af23b3c896bf05003cf2bd8646b.
Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-14-g7cde785 <https://github.com/ahupp/python-magic/commit/0.4.27-14-g7cde785> 2023-03-30
cherry-picked/0.4.27-15-g3ab9608.revert-added-path-for-local-homebrew-installation-267.patch Revert "added path for local homebrew installation (#267)"
This reverts commit cd3929fa7cbc2e383629d0893fc08bcb68a7614c.
Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-15-g3ab9608 <https://github.com/ahupp/python-magic/commit/0.4.27-15-g3ab9608> 2023-03-30
cherry-picked/0.4.27-16-g545a2a5.fix-test-suite-with-file-5-45.patch Fix test suite with file 5.45
[ 12s] test/python_magic_test.py:53: in assert_values
[ 12s] self.assertIn(value, expected_value)
[ 12s] E AssertionError: 'PDF document, version 1.2, 2 page(s)' not found in ('PDF document, version 1.2', 'PDF document, version 1.2, 2 pages')
Dominique Leuenberger <dimstar@opensuse.org> not-needed upstream, commit 0.4.27-16-g545a2a5 <https://github.com/ahupp/python-magic/commit/0.4.27-16-g545a2a5> 2023-08-02
cherry-picked/0.4.27-17-g0cc3cf8.chore-python-add-python-3-12-in-test-matrix.patch Chore(python): add Python 3.12 in test matrix Stevie <stevie.gayet@backmarket.com> not-needed upstream, commit 0.4.27-17-g0cc3cf8 <https://github.com/ahupp/python-magic/commit/0.4.27-17-g0cc3cf8> 2023-08-06
cherry-picked/0.4.27-18-g7229954.fix-dont-raise-filenotfoundexception-on-symlinks.patch Fix: Don't raise FileNotFoundException on symlinks
The builtin `open` will always follow symlinks.
Using `os.stat` is the easiest solution imo.
An alternative would be using `os.access` but that does not raise
a FileNotFoundException so I chose `os.stat`.
Marten Ringwelski <git@maringuu.de> not-needed upstream, commit 0.4.27-18-g7229954 <https://github.com/ahupp/python-magic/commit/0.4.27-18-g7229954> 2023-08-23
cherry-picked/0.4.27-19-g2a01b18.add-magic-symlink-support-and-tests-for-same.patch Add MAGIC_SYMLINK support, and tests for same Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-19-g2a01b18 <https://github.com/ahupp/python-magic/commit/0.4.27-19-g2a01b18> 2023-08-25
cherry-picked/0.4.27-20-g64ed0bd.typing-stubs-add-magic-init-extension-follow-symlinks-args.patch Typing stubs: add Magic.__init__ extension & follow_symlinks args Robert Scott <code@humanleg.org.uk> not-needed upstream, commit 0.4.27-20-g64ed0bd <https://github.com/ahupp/python-magic/commit/0.4.27-20-g64ed0bd> 2023-10-07
cherry-picked/0.4.27-21-gfd279e0.magic-init-add-kwargs-to-enable-disable-different-types-of-magic-detection.patch Magic.__init__: add kwargs to enable/disable different types of magic detection Robert Scott <code@humanleg.org.uk> not-needed upstream, commit 0.4.27-21-gfd279e0 <https://github.com/ahupp/python-magic/commit/0.4.27-21-gfd279e0> 2023-10-07
cherry-picked/0.4.27-22-g54d86fd.python-magic-tests-add-test-files-for-elf-and-json-use-to-test-flags.patch Python-magic tests: add test files for elf and json, use to test flags
elf-NetBSD-x86_64-echo is from
https://github.com/JonathanSalwan/binary-samples under an MIT license

incidentally this exposes that the ELF builtin magic detector
only works on files, falling back to the soft magic for buffers


Note for Debian: test/testdata/elf-NetBSD-x86_64-echo.gz.b64 is
upstream's test/testdata/elf-NetBSD-x86_64-echo¹, gzip'ed and
base64-encoded so it fits in a patch. Unpacking is done in
debian/rules and debian/tests/run-testsuite

¹ sha256sum 17ebd33e39aeda51701f48f925340b09596602bbe6bc02a7ec94183797095618
Robert Scott <code@humanleg.org.uk> not-needed upstream, commit 0.4.27-22-g54d86fd <https://github.com/ahupp/python-magic/commit/0.4.27-22-g54d86fd> 2023-10-07
cherry-picked/0.4.27-23-g8eecfb7.travis-ci-test-on-python-3-13-beta.patch Travis CI: Test on Python 3.13 beta
The Python 3.13 release notes mention `python-magic` as one of the alternatives for `imghdr` which was removed from the Standard Library so let's ensure that its tests pass on Python 3.13 beta.

https://www.python.org/downloads/release/python-3130b1/

May raise `ModuleNotFoundError: No module named 'imghdr'` because Python 3.13 removes it from the Standard Library.
* https://docs.python.org/3/library/imghdr.html

> imghdr: use the projects [filetype](https://pypi.org/project/filetype/), [puremagic](https://pypi.org/project/puremagic/), or [python-magic](https://pypi.org/project/python-magic/) instead. (Contributed by Victor Stinner in [gh-104773](https://github.com/python/cpython/issues/104773).)

https://docs.python.org/3.13/whatsnew/3.13.html#pep-594-dead-batteries-and-other-module-removals
Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-23-g8eecfb7 <https://github.com/ahupp/python-magic/commit/0.4.27-23-g8eecfb7> 2024-05-11
cherry-picked/0.4.27-24-g7ee4180.delete-travis-yml.patch Delete .travis.yml
As discussed at https://github.com/ahupp/python-magic/pull/317#issuecomment-2111634995 this file is useless without a paid subscription to Travis CI.

GitHub Actions is free to open source projects but Travis CI is not.
* #318
Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-24-g7ee4180 <https://github.com/ahupp/python-magic/commit/0.4.27-24-g7ee4180> 2024-05-16
cherry-picked/0.4.27-25-ge578995.github-action-to-replace-travis-ci.patch GitHub Action to replace Travis CI Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-25-ge578995 <https://github.com/ahupp/python-magic/commit/0.4.27-25-ge578995> 2024-05-11
cherry-picked/0.4.27-26-gab1b2a4.update-ci-yml.patch Update ci.yml Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-26-gab1b2a4 <https://github.com/ahupp/python-magic/commit/0.4.27-26-gab1b2a4> 2024-05-16
cherry-picked/0.4.27-27-gaa49677.update-readme-md.patch Update README.md
Remove travis build badge
Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-27-gaa49677 <https://github.com/ahupp/python-magic/commit/0.4.27-27-gaa49677> 2024-05-16
cherry-picked/0.4.27-28-geae08a3.readme-md-add-a-badge-for-github-actions.patch README.md: Add a badge for GitHub Actions
https://docs.github.com/en/actions/monitoring-and-troubleshooting-workflows/adding-a-workflow-status-badge

[![Tests](https://github.com/ahupp/python-magic/actions/workflows/ci.yml/badge.svg)](https://github.com/ahupp/python-magic/actions/workflows/ci.yml)
Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-28-geae08a3 <https://github.com/ahupp/python-magic/commit/0.4.27-28-geae08a3> 2024-05-16
cherry-picked/0.4.27-29-gfc7ebc0.update-readme-md.patch Update README.md Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-29-gfc7ebc0 <https://github.com/ahupp/python-magic/commit/0.4.27-29-gfc7ebc0> 2024-05-16
cherry-picked/0.4.27-30-g1217005.fix-typos-discovered-by-codespell.patch Fix typos discovered by codespell ddelange <14880945+ddelange@users.noreply.github.com> not-needed upstream, commit 0.4.27-30-g1217005 <https://github.com/ahupp/python-magic/commit/0.4.27-30-g1217005> 2024-05-22
cherry-picked/0.4.27-31-gcf21065.clean-up-loader-py.patch Clean up loader.py Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-31-gcf21065 <https://github.com/ahupp/python-magic/commit/0.4.27-31-gcf21065> 2024-05-22
cherry-picked/0.4.27-32-g0a2fda3.handle-unknown-platforms-gracefully-in-loader-py.patch Handle unknown platforms gracefully in loader.py Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-32-g0a2fda3 <https://github.com/ahupp/python-magic/commit/0.4.27-32-g0a2fda3> 2024-05-26
cherry-picked/0.4.27-33-g4b776d7.rename-no-json-test-to-avoid-duplicate-function-definitions.patch Rename no_json test to avoid duplicate function definitions Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-33-g4b776d7 <https://github.com/ahupp/python-magic/commit/0.4.27-33-g4b776d7> 2024-05-26
cherry-picked/0.4.27-34-g339eac0.smartos-support-adapted-from-132.patch Smartos support, adapted from #132 Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-34-g339eac0 <https://github.com/ahupp/python-magic/commit/0.4.27-34-g339eac0> 2024-05-26
cherry-picked/0.4.27-35-ga9e6276.log-warning-on-ctypes-load-error-adapted-from-279.patch Log warning on ctypes load error, adapted from #279 Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-35-ga9e6276 <https://github.com/ahupp/python-magic/commit/0.4.27-35-ga9e6276> 2024-05-26
cherry-picked/0.4.27-36-g067399b.update-readme-md.patch Update README.md Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-36-g067399b <https://github.com/ahupp/python-magic/commit/0.4.27-36-g067399b> 2024-06-09
cherry-picked/0.4.27-37-g42980e5.simplify-tests-into-something-more-delarative.patch Simplify tests into something more delarative Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-37-g42980e5 <https://github.com/ahupp/python-magic/commit/0.4.27-37-g42980e5> 2024-05-26
cherry-picked/0.4.27-38-g36ecbf9.update-magic-compat-py.patch Update magic/compat.py
This pulls changes from https://github.com/file/file, commit
512840337ead1076519332d24fefcaa8fac36e06
Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-38-g36ecbf9 <https://github.com/ahupp/python-magic/commit/0.4.27-38-g36ecbf9> 2024-08-05
cherry-picked/0.4.27-39-ga3ed086.unbreak-various-things.patch Unbreak various things
* A merge to reduce error spam during loading broke .so
loading in at least some (maybe all?) cases, where find_library
doesn't return an absolute path.
* Prematurely pushed some in-progress test changes that were super broken, all fixed now.
Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-39-ga3ed086 <https://github.com/ahupp/python-magic/commit/0.4.27-39-ga3ed086> 2025-02-18
cherry-picked/0.4.27-40-g5a89644.add-support-for-python-3-13.patch Add support for python 3.13 Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-40-g5a89644 <https://github.com/ahupp/python-magic/commit/0.4.27-40-g5a89644> 2025-02-19
cherry-picked/0.4.27-41-g62bd3c6.format-with-ruff.patch Format with ruff Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-41-g62bd3c6 <https://github.com/ahupp/python-magic/commit/0.4.27-41-g62bd3c6> 2025-03-01
cherry-picked/0.4.27-42-gfac6615.small-fix-to-readme-that-makes-pip-install-command-easier-to-see-find.patch Small Fix to ReadMe that makes pip install command easier to see/find
I wasn't able to really find the pip command quickly, so I thought this addition would help with readability and help people find the pip install command easier
Name <87663453+Dodf12@users.noreply.github.com> not-needed upstream, commit 0.4.27-42-gfac6615 <https://github.com/ahupp/python-magic/commit/0.4.27-42-gfac6615> 2025-07-01
cherry-picked/0.4.27-43-g8361a33.update-readme-md.patch Update README.md Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-43-g8361a33 <https://github.com/ahupp/python-magic/commit/0.4.27-43-g8361a33> 2025-07-06
cherry-picked/0.4.27-44-g7cbbc99.update-readme-md.patch Update README.md Adam Hupp <adam@hupp.org> not-needed upstream, commit 0.4.27-44-g7cbbc99 <https://github.com/ahupp/python-magic/commit/0.4.27-44-g7cbbc99> 2025-08-14
cherry-picked/0.4.27-45-gf8fb0ee.add-python-3-14-to-the-testing.patch Add Python 3.14 to the testing
Python v3.14 -- October 7th
* https://www.python.org/download/pre-releases
* https://www.python.org/downloads/release/python-3140rc3
* https://docs.python.org/3.14/whatsnew/3.14.html

Like:
* #347
Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-45-gf8fb0ee <https://github.com/ahupp/python-magic/commit/0.4.27-45-gf8fb0ee> 2025-09-24
cherry-picked/0.4.27-46-g07bd5dd.keep-github-actions-up-to-date-with-github-s-dependabot.patch Keep GitHub Actions up to date with GitHub's Dependabot
* [Keeping your software supply chain secure with Dependabot](https://docs.github.com/en/code-security/dependabot)
* [Keeping your actions up to date with Dependabot](https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot)
* [Configuration options for the `dependabot.yml` file - package-ecosystem](https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#package-ecosystem)
Christian Clauss <cclauss@me.com> not-needed upstream, commit 0.4.27-46-g07bd5dd <https://github.com/ahupp/python-magic/commit/0.4.27-46-g07bd5dd> 2025-09-24
cherry-picked/0.4.27-47-g5cffa79.bump-actions-checkout-from-5-to-6-in-the-github-actions-group.patch Bump actions/checkout from 5 to 6 in the github-actions group
Bumps the github-actions group with 1 update: [actions/checkout](https://github.com/actions/checkout).


Updates `actions/checkout` from 5 to 6
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: github-actions
...

Signed-off-by: dependabot[bot] <support@github.com>
dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> not-needed upstream, commit 0.4.27-47-g5cffa79 <https://github.com/ahupp/python-magic/commit/0.4.27-47-g5cffa79> 2025-11-24
cherry-picked/0.4.27-48-gff3e049.drop-unused-imports.patch Drop unused imports Semyon Pupkov <mail@semyonpupkov.com> not-needed upstream, commit 0.4.27-48-gff3e049 <https://github.com/ahupp/python-magic/commit/0.4.27-48-gff3e049> 2026-03-03
cherry-picked/0.4.27-49-ga1fad43.fix-test-for-apache-parquet-files-for-file-5-47.patch Fix test for Apache Parquet files for file 5.47
The output for Parquet files changed in 5.47. This commit edits the test
to accept both the old and new output.

```sh
# Old
$ file example.parquet
example.parquet: Apache Parquet
$ file --mime example.parquet
example.parquet: application/octet-stream; charset=binary

# New
$ file example.parquet
example.parquet: Apache Parquet file
$ file --mime example.parquet
example.parquet: application/vnd.apache.parquet; charset=binary
```
Adam Thompson-Sharpe <adamthompsonsharpe@gmail.com> not-needed upstream, commit 0.4.27-49-ga1fad43 <https://github.com/ahupp/python-magic/commit/0.4.27-49-ga1fad43> 2026-05-06
cherry-picked/0.4.27-50-g71301b0.add-python-3-14-to-ci.patch Add python 3.14 to CI ddelange <14880945+ddelange@users.noreply.github.com> not-needed upstream, commit 0.4.27-50-g71301b0 <https://github.com/ahupp/python-magic/commit/0.4.27-50-g71301b0> 2025-10-14
cherry-picked/0.4.27-51-g8e7d98e.move-lock-to-global-scope.patch Move lock to global scope ddelange <14880945+ddelange@users.noreply.github.com> not-needed upstream, commit 0.4.27-51-g8e7d98e <https://github.com/ahupp/python-magic/commit/0.4.27-51-g8e7d98e> 2025-10-14
cherry-picked/0.4.27-52-g892543d.add-test.patch Add test ddelange <14880945+ddelange@users.noreply.github.com> not-needed upstream, commit 0.4.27-52-g892543d <https://github.com/ahupp/python-magic/commit/0.4.27-52-g892543d> 2025-10-14
cherry-picked/0.4.27-53-gf3cef27.apply-suggestions-from-code-review.patch Apply suggestions from code review ddelange <14880945+ddelange@users.noreply.github.com> not-needed upstream, commit 0.4.27-53-gf3cef27 <https://github.com/ahupp/python-magic/commit/0.4.27-53-gf3cef27> 2025-10-14
cherry-picked/0.4.27-54-g4043553.revert-move-lock-to-global-scope.patch Revert "Move lock to global scope"
This reverts commit f2ac98d8aa7464165984068de9e484d0321cd4f3.
ddelange <14880945+ddelange@users.noreply.github.com> not-needed debian upstream, commit 0.4.27-54-g4043553 <https://github.com/ahupp/python-magic/commit/0.4.27-54-g4043553> 2025-10-17

All known versions for source package 'python-magic'

Links