Releases: Erotemic/ubelt
Version 1.4.0
- Removed support for 3.6 and 3.7
ub.hash_datacan how hash dataclasses by default- Add experimental support for "interpreter" backend in Executor.
What's Changed
Full Changelog: v1.3.8...v1.4.0
Version 1.3.6
For new stuff: there is a quality of life improvements in ub.Path.chmod, you can use string-codes like ub.Path(...).chmod('+x') now! I think that's pretty neat. There isalso new functionality in ub.IndexableWalker.diff, which lets you compare similar, nested structures.
This update also vendors part of jaraco.windows so no-dependency versions of ubelt can now be installed on windows. The jaraco.windows can still be used, but it is now a truly optional dependency.
For fixed stuff: It looks like editable installs now use type annotations in their MAPPER files, so modname_to_modpath has been updated to account for this. This fixes several issues in experienced by consumers of this package.
There is also a fix that almost nobody will ever notice, but it blocked the above update from getting released for several weeks by causing a single CI job to fail. The library now handles new corner cases on pypy on windows with path related things (getting tests to pass was here far too much work - I nearly dropped pypy or windows support in frustration).
Version 1.3.6 - Released 2024-06-08
Added:
- Add
ub.IndexableWalker.diff
Fixed:
- Added workarounds for copy / symlinks via
ub.Pathandub.symlinkon pypy. ub.import_module_from_pathnow correctly acceptsPathLikeobjects.ub.modname_to_modpathfixed in cases where editable installs use type
annotations in their MAPPING definition.
Added
- Support for UNIX special permission (suid/sgid/svtx) codes in
Path.chmod.
Changed
- Moved windows dependencies from requires to optional. Windows users that make
use of these will need to update their ubelt install or explicitly depend on
them as well.
What's Changed
Full Changelog: v1.3.5...refs/heads/release
Version 1.3.5
Added:
- New wrapper around
pathlib.Path.chmodinubelt.Path.chmod. Can now
specify string codes like "u+x" or "+rw". Old stat logic works as it
previously did.
Changed:
- Allow the argument to
ubelt.cmdto be aPathLikeobject, which we will
expect to be an executable.
Fixed
ub.modname_to_modpathnow handles cases where editable packages have modules where the name is different than the package.- Fixed deprecated usage of
ast.Num
What's Changed
Full Changelog: v1.3.4...v1.3.5
Version 1.3.4
Added
- Add backend option to
highlight_codewhich can be "pygments" or "rich". - Support for Python 3.12
Changed
- Improve speed of inplace dictionary set operations.
Fixed
- Align in the case of
nobraces=1forubelt.urepr.
Version 1.3.3
Fixed
- Bug where the first call to
ub.hash_datawould error if it was given a
ndarray with object type. - Actually exposed
ChDir.
Changed
- Docs and typing improvements
Version 1.3.2
Fixed
- Bug where the first call to
ub.hash_datawould error if it was given a
ndarray with object type.
Notes
- Skipped a release version due to a bad github tag.
Version 1.3.0
Version 1.3.0 - 2022-06-14
Changed
- Removed experimental warning from
Path.copyandPath.move; they are now well enough tested. - The
util_formatsubmodule has been renamed toutil_repr. The
util_formatis now a deprecated alias forutil_repr. - Stub out merge methods for SetDict.
- Renamed
FormatterExtensionstoReprExtensions, with the former now being a deprecated alias. ubelt.cmdnow returns an object that ducktypessubprocess.CompletedProcess.ubelt.cmdnow contains acaptureargument which will disable capturing of output.ubelt.cmd...detaching now only prints if verbosity is > 1
Version 1.2.4
Version 1.2.4
Added
- Added
ChDirtoutil_path. - Add transient option to
JobPoolso references to futures are released after they are yielded to the user. - Added "base32" as an option for
hash_data. Note that it is unpadded, hence non-RFC compliant. - Added
patternas a convenience option toubelt.Path.ls.
Changed
- Updated vendored ProgIter to match progiter 1.3.0
- The download progress bar now gives more relevant information and updates less frequently.
IndexableWalker.allclosecan now take unwrapped objects.
Fixed
ubelt.cmdnow respectscwdwhensystem=True.
Version 1.2.3
Added
- Support for FreeBSD in
util_platform ub.Path.copyandub.Path.move- Tentative Python 3.11 support
ub.utextwhich is a repr2 with new defaults.ub.IndexableWalker.allclosemethod to replaceindexable_allclose
Changed
ub.schedule_deprecationcan now accept the strings "soon" or "now" for "when" arguments.ub.schedule_deprecationcan now acceptstacklevelas as an argument.ub.Path.apppdircan now be called without arguments.- Deprecate
TempDir ub.Timercan now acceptnsas a keyword to enable nanosecond resolution.ProgIter.format_messagereturn value has changed.ub.Path.mkdirnow returns itself- Speedup
dict_histin the basic case by 2x
Fixed
- Issue in
indexable_allclosewhere tolerances were not respected. - Issue in
modname_to_modpathwith exclude and editable installs. - Incompatibility with pathlib in
PythonPathContext - Fixed issue in progiter with line clears
- Issue in
import_module_from_modnamewith editable installs where it would try to match modules that had the requested module as a prefix. - The
timeoutargument is now respected in the thread / process case ofJobPool
Version 1.2.2
Added
- Add
ubelt.util_dict.UDict.take. - Added
__add__,__radd__,startswith, andendswithmethods toubelt.Pathto make
it a better drop-in replacement for string based paths.
Changed
- Reverse dunder methods of
ubelt.SetDictnow promote the type. - Add
clskeyword argument toubelt.SetDictmethods. - Deprecate:
ensure_app_cache_dir,ensure_app_config_dir,ensure_app_data_dir,
get_app_cache_dir,get_app_config_dir,get_app_data_dir,readfrom,writeto,ensure_unicode. - Initial work on new Path methods for move and copy.
- CacheStamp.renew now does nothing and returns None if the stamp is disabled.
- AutoDict, SetDict, and UDict are now always ordered. In Python 3.6 it inherits from OrderedDict. Otherwise it uses regular dict, which will be ordered in 3.7+
- AutoDict now inherits from UDict.
- PathLike objects can now be used in args to ub.cmd when the command is an iterable.
Deprecated
- deprecate AutoOrderedDict, which is now indistinguishable from AutoDict
Fixed
- Tentative fixes for new
__editable__based install path withub.modname_to_modpath