-
Notifications
You must be signed in to change notification settings - Fork 284
/
CHANGELOG
97 lines (68 loc) · 3.2 KB
/
CHANGELOG
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
Changes to 0.4.29:
- support MAGIC_SYMLINK (via follow_symlink flag on Magic constructor)
- correctly throw FileNotFoundException depending on flag
Changes to 0.4.28:
- support "magic-1.dll" on Windows, which is produced by vcpkg
- add python 3.10 to tox config
- update test for upstream gzip extensions
Changes to 0.4.27:
- remove spurious pyproject.toml that breaks source builds
Changes to 0.4.26:
- Use tox for all multi-version testing
- Fix use of pytest, use it via tox
Changes to 0.4.25:
- Support os.PathLike values in Magic.from_file and magic.from_file
- Handle some versions of libmagic that return mime string without charset
- Fix tests for file 5.41
- Include typing stub in package
Changes to 0.4.24:
- Fix regression in library loading on some Alpine docker images.
Changes to 0.4.23
- Include a `py.typed` sentinel to enable type checking
- Improve fix for attribute error during destruction
- Cleanup library loading logic
- Add new homebrew library dir for OSX
Changes to 0.4.21, 0.4.22
- Unify dll loader between the standard and compat library, fixing load
failures on some previously supported platforms.
Changes to 0.4.20
- merge in a compatibility layer for the upstream libmagic python binding.
Since both this package and that one are called 'magic', this compat layer
removes a very common source of runtime errors. Use of that libmagic API will
produce a deprecation warning.
- support python 3.9 in tests and pypi metadata
- add support for magic_descriptor functions, which take a file descriptor
rather than a filename.
- sometimes the returned description includes snippets of the file, e.g a title
for MS Word docs. Since this is in an unknown encoding, we would throw a
unicode decode error trying to decode. Now, it decodes with
'backslashreplace' to handle this more gracefully. The undecodable characters
are replaced with hex escapes.
- add support for MAGIC_EXTENSION, to return possible file extensions.
- add mypy typing stubs file, for type checking
Changes in 0.4.18
- Make bindings for magic\_[set|get]param optional, and throw NotImplementedError
if they are used but not supported. Only call setparam() in the constructor if
it's supported. This prevents breakage on CentOS7 which uses an old version of
libmagic.
- Add tests for CentOS 7 & 8
Changes in 0.4.16 and 0.4.17
- add MAGIC_MIME_TYPE constant, use that in preference to MAGIC_MIME internally.
This sets up for a breaking change in a future major version bump where
MAGIC_MIME will change to match magic.h.
- add magic.version() function to return library version
- add setparam/getparam to control internal behavior
- increase internal limits with setparam to prevent spurious error on some jpeg files
- various setup.py improvements to declare modern python support
- support MSYS2 magic dlls
- fix warning about using 'is' on an int in python 3.8
- include tests in source distribution
- many test improvements:
-- tox runner support
-- remove deprecated test_suite field from setup.py
-- docker tests that cover all LTS ubuntu versions
-- add test for snapp file identification
- doc improvements
-- document dependency install process for debian
-- various typos
-- document test running process