Python utils for everyday use. See the docs at

webyneter, updated 🕥 2022-12-26 21:30:48

Python Humble Utils

.. image:: https://travis-ci.org/webyneter/python-humble-utils.svg?branch=master :target: https://travis-ci.org/webyneter/python-humble-utils :alt: Build Status

.. image:: https://badgen.net/dependabot/webyneter/python-humble-utils/?icon=dependabot :target: https://badgen.net/dependabot/webyneter/python-humble-utils/?icon=dependabot :alt: dependabot

.. image:: https://codecov.io/gh/webyneter/python-humble-utils/branch/master/graph/badge.svg :target: https://codecov.io/gh/webyneter/python-humble-utils :alt: Coverage

.. image:: https://codeclimate.com/github/webyneter/python-humble-utils/badges/gpa.svg :target: https://codeclimate.com/github/webyneter/python-humble-utils :alt: Code Climate

.. image:: https://badge.fury.io/py/python-humble-utils.svg :target: https://pypi.python.org/pypi/python-humble-utils :alt: Latest Version

.. image:: https://img.shields.io/pypi/pyversions/python-humble-utils.svg :target: https://pypi.python.org/pypi/python-humble-utils :alt: Supported Python Versions

.. image:: https://readthedocs.org/projects/python-humble-utils/badge/?version=stable :target: http://python-humble-utils.readthedocs.io/en/stable/?badge=stable :alt: Documentation Status

.. image:: https://img.shields.io/badge/License-MIT-green.svg :target: https://opensource.org/licenses/MIT :alt: MIT License

.. image:: https://img.shields.io/gitter/room/webyneter/python-humble-utils.svg :target: https://gitter.im/webyneter/python-humble-utils?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge :alt: Join the chat at https://gitter.im/webyneter/python-humble-utils

Python utils for everyday use.

  • Documentation_.
  • Please, open issues_ before sending emails to the maintainers: You will get a much faster response!

.. open issues: https://github.com/webyneter/python-humble-utils/issues/new .. Documentation: https://python-humble-utils.readthedocs.io/en/stable/installation.html

Feature Areas

  • File operations.
  • File/directory paths extraction.
  • File/directory paths randomization.
  • String case conversions.
  • Python class convenience shortcuts.
  • py.test_ fixtures and helpers.

.. _py.test: https://docs.pytest.org/en/stable/

Installation

.. code-block:: console

$ pip install python-humble-utils

or install from sources:

.. code-block:: console

$ python setup.py install

Refer to Installation_ for detailed instructions.

.. _Installation: https://python-humble-utils.readthedocs.io/en/stable/installation.html

Usage

.. code-block:: python

import os
from pathlib import Path

from python_humble_utils.filesystem import yield_file_paths
from python_humble_utils.strings import camel_or_pascal_case_to_snake_case


# ...

file_paths = yield_file_paths(
    dir_path=Path("dir") / "with" / "scripts",
    allowed_file_extensions=(".sh", ".bash"),
    recursively=True
)
assert set(file_paths) == set(("s1.sh", "s2.bash", "s3.bash"))

s = camel_or_pascal_case_to_snake_case("camelCasedString")
assert s == "camel_cased_string"

s = camel_or_pascal_case_to_snake_case("PascalCasedString")
assert s == "pascal_cased_string"

# ...

Contributing

Your contributions are very much welcome! Refer to Contributing_ for more details.

.. _Contributing: https://python-humble-utils.readthedocs.io/en/stable/contributing.html

Code of Conduct

All those using python-humble-utils, including its codebase and project management ecosystem are expected to follow the Python Community Code of Conduct_.

.. _Python Community Code of Conduct: https://www.python.org/psf/codeofconduct/

Acknowledgements

This package was initially scaffolded via Cookiecutter with audreyr/cookiecutter-pypackage template.

.. Cookiecutter: https://github.com/audreyr/cookiecutter .. audreyr/cookiecutter-pypackage: https://github.com/audreyr/cookiecutter-pypackage

Issues

Bump wheel from 0.34.2 to 0.38.1

opened on 2022-12-26 21:30:48 by dependabot[bot]

Bumps wheel from 0.34.2 to 0.38.1.

Changelog

Sourced from wheel's changelog.

Release Notes

UNRELEASED

  • Updated vendored packaging to 22.0

0.38.4 (2022-11-09)

  • Fixed PKG-INFO conversion in bdist_wheel mangling UTF-8 header values in METADATA (PR by Anderson Bravalheri)

0.38.3 (2022-11-08)

  • Fixed install failure when used with --no-binary, reported on Ubuntu 20.04, by removing setup_requires from setup.cfg

0.38.2 (2022-11-05)

  • Fixed regression introduced in v0.38.1 which broke parsing of wheel file names with multiple platform tags

0.38.1 (2022-11-04)

  • Removed install dependency on setuptools
  • The future-proof fix in 0.36.0 for converting PyPy's SOABI into a abi tag was faulty. Fixed so that future changes in the SOABI will not change the tag.

0.38.0 (2022-10-21)

  • Dropped support for Python < 3.7
  • Updated vendored packaging to 21.3
  • Replaced all uses of distutils with setuptools
  • The handling of license_files (including glob patterns and default values) is now delegated to setuptools>=57.0.0 (#466). The package dependencies were updated to reflect this change.
  • Fixed potential DoS attack via the WHEEL_INFO_RE regular expression
  • Fixed ValueError: ZIP does not support timestamps before 1980 when using SOURCE_DATE_EPOCH=0 or when on-disk timestamps are earlier than 1980-01-01. Such timestamps are now changed to the minimum value before packaging.

0.37.1 (2021-12-22)

  • Fixed wheel pack duplicating the WHEEL contents when the build number has changed (#415)
  • Fixed parsing of file names containing commas in RECORD (PR by Hood Chatham)

0.37.0 (2021-08-09)

  • Added official Python 3.10 support
  • Updated vendored packaging library to v20.9

... (truncated)

Commits
  • 6f1608d Created a new release
  • cf8f5ef Moved news item from PR #484 to its proper place
  • 9ec2016 Removed install dependency on setuptools (#483)
  • 747e1f6 Fixed PyPy SOABI parsing (#484)
  • 7627548 [pre-commit.ci] pre-commit autoupdate (#480)
  • 7b9e8e1 Test on Python 3.11 final
  • a04dfef Updated the pypi-publish action
  • 94bb62c Fixed docs not building due to code style changes
  • d635664 Updated the codecov action to the latest version
  • fcb94cd Updated version to match the release
  • Additional commits viewable in compare view


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) - `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language - `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language - `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language - `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/webyneter/python-humble-utils/network/alerts).

Bump codecov from 2.0.15 to 2.0.16

opened on 2022-07-15 18:41:53 by dependabot[bot]

Bumps codecov from 2.0.15 to 2.0.16.

Changelog

Sourced from codecov's changelog.

2.0.16

  • fixed reported command injection vulnerability.
Commits


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) - `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language - `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language - `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language - `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/webyneter/python-humble-utils/network/alerts).

Bump ipython from 7.12.0 to 7.16.3

opened on 2022-01-21 20:05:54 by dependabot[bot]

Bumps ipython from 7.12.0 to 7.16.3.

Commits


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) - `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language - `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language - `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language - `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/webyneter/python-humble-utils/network/alerts).

Consider migrating to hypothesis'es `@given` from pytest's `@pytest.mark.parametrize`

opened on 2019-10-22 13:49:19 by webyneter None

Automatic changelog creation

opened on 2019-10-18 14:35:41 by webyneter

Related to #19

Check out poetry

opened on 2019-10-16 10:08:59 by webyneter None

Releases

2019-11-04 19:18:51

Functional:

Non-functional:

2019-10-16 21:37:11

2019-10-16 21:13:36

Breaking changes

Other changes

2017-10-24 21:40:39

Breaking changes - Move tests to the root. - Pick another naming scheme for tests.

Other changes - Convert NamedTuple's to classes and document them. - Clean up docstrings. - Stop indexing tests in docs.

2017-10-24 19:13:43

2017-10-24 19:01:16

Nikita Shupeyko

Expert DevOps and Cloud Architect with Python/Django Background. Consultant. Core Contributor at Cookiecutter Django

GitHub Repository Homepage

python python-3 utility utilities util utils humble helper helpers