Pywbt

Latest version: v0.2.9

Safety actively analyzes 722491 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

0.2.9

Added

- For `dem_utils.get_3dep` use `seamless-3dep` package to support any resolution not
only 10, 30, and 60 meters. This Python library is more performant and caches
downloaded intermediate files to avoid downloading the same files multiple times.
This change requires adding optional `seamless-3dep` as a new dependency for the
`dem_utils` module.
- For `dem_utils.get_nasadem` use `tiny-retriever` package for a more performant and
reliable way to download the NASADEM data. Similarly, it caches downloaded
intermediate files to avoid downloading the same files multiple times. This change
requires adding `tiny-retriever` as a optional new dependency for the `dem_utils`
module.

Fixed

- In `whitebox_tools` function when `files_to_save` is not provided, before moving the
output files to `save_dir`, check if the output files already exist in the
`save_dir` and remove them before moving the new output files. This is to avoid an
issue with `shutil.move` which fails to overwrite existing files.

0.2.8

This release adds `filelock` as a dependency and `tomli` as an optional dependency.

Added

- Add a command line interface to allow invoking `pywbt` from the command line. It only
requires specifying path to a configuration file written in TOML format. This adds
`tomli` as a new optional dependency for parsing the TOML configuration file if
Python version is less than 3.11. Otherwise, Python's built-in `tomllib` module is
used to parse the configuration file.An example configuration file can be found
[here](https://raw.githubusercontent.com/cheginit/pywbt/main/tests/config.toml).

bash
pywbt path/to/config.toml


- Make `prepare_wbt` public so users can run this function once to download the WBT
executable and then use the `whitebox_tools` function to run the tools. This can
help avoid downloading the WBT executable multiple times when running `pywbt` in
parallel or in different scripts.

- Use `filelock` library so only one instances of `prepare_wbt` can download the WBT
executable at a time. This is to avoid race conditions when multiple processes try
to setup the WBT executable at the same time.

0.2.7

Fixed

- Fix an issue when a Shapefile exists as input or output in the `arg_dict`. The issue
would have caused an infinite loop when trying to copy the Shapefile and its
auxiliary files. ({{ issue(3) }})

0.2.6

Fixed

- Fix a bug in extracting WBT executable from the zip file. The bug impacted mostly
users who run PyWBT on cluster environments where the `tempfile` modules uses
system's temporary directory which in most cases is not reliable. The fix is to use
the `tempfile.TemporaryDirectory` context manager to create a temporary directory in
the current working directory.

0.2.5

Fixed

- Automatically add auxiliary files of Shapefile when they exist in `arg_dict`. This
ensures that the auxiliary files are also stored to `save_dir` when `files_to_save`
is provided.

0.2.4

Added

- Add a new module called `dem_utils` that contains utilities for downloading and
reading DEM data from 3DEP and NASADEM. Note that the module has some additional
dependencies that need to be installed. To install these dependencies, use:

bash
pip install pywbt[dem]


or using `micromamba`:

bash
micromamba install -c conda-forge pywbt 'geopandas-base>=1' planetary-computer pystac-client rioxarray

Page 1 of 2

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.