humps
humps copied to clipboard
Convert strings (and dictionary keys) between snake case, camel case and pascal case in Python. Inspired by Humps for Node
## Status **READY** ## Description `mypy` complains that the symbols don't exist, it says `error: Module has no attribute "camelize"; maybe "decamelize"?`. Explicitly exposing all the functions in `__all__` correctly...
Bumps [flake8](https://github.com/pycqa/flake8) from 4.0.1 to 5.0.4. Commits 6027577 Release 5.0.4 213e006 Merge pull request #1653 from asottile/lower-bound-importlib-metadata e94ee2b require sufficiently new importlib-metadata 318a86a Merge pull request #1646 from televi/main 7b8b374...
## Status **READY** ## Description Without this file, one would get the following error when `implicit_reexport` is disabled. ``` path:10: error: Module has no attribute "camelize"; maybe "decamelize"? [attr-defined] ```...
## Status **READY** ## Description There was a mismatch for the name and module. `humps` is the name which is used to import but the module name is [`pyhumps`](https://pypi.org/project/pyhumps/). Ref:...
**Describe the bug** After installation and removing the 'humps' package, the `humps` module is seemed not loaded. **To Reproduce** Steps to reproduce the behavior: ```sh ❯ python --version Python 3.8.8...
## Status **READY** ## Description * Simplified regex and improved performance by 50-60% * Allow acronyms to end in digits * fixes #258 ## Impacted Areas in Application * Regular...
If lower and upper case characters are separated by punctuation, decamelize should not insert an underscore as well. **To Reproduce** ``` >>> for c in '.,/?;:\'"[]{}\\|`~!@#$%^&*()-_=+': ... print(f"humps.decamelize(foo{c}Bar): " +...
`decamelize` treats a sequence of upper case characters followed by lowercase characters as two words, one being all but the last upper case character (presumably an acronym), the rest being...
**Describe the bug** Dashes are replaced and treated as underscores. Is this intentional? It seems to be based on: https://github.com/nficano/humps/blob/2bbaf1e7504654e24c8dabc1e5ada7a46727cf3b/humps/main.py#L27 My use case is to convert dictionaries with snake case...
## Status **READY** ## Description This can then be combined with the other functions to convert kebab-case to any other supported case. Note the character casing is preserved in conversion...