Name | flowstep JSON |
Version |
0.0.1
JSON |
| download |
home_page | None |
Summary | Manages individual steps within a flow. |
upload_time | 2024-05-19 22:41:25 |
maintainer | None |
docs_url | None |
author | Bruno Peixoto |
requires_python | <4.0,>=3.8 |
license | MIT |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Flowstep
[![Version](https://img.shields.io/pypi/v/flowstep.svg)](https://pypi.python.org/pypi/flowstep)
[![downloads](https://img.shields.io/pypi/dm/flowstep)](https://pypi.org/project/flowstep/)
[![codecov](https://codecov.io/gh/trouchet/flowstep/branch/main/graph/badge.svg?token=PJMBaLIqar)](https://codecov.io/gh/trouchet/flowstep)
[![Lint workflow](https://github.com/trouchet/flowstep/actions/workflows/check-lint.yaml/badge.svg)](https://github.com/trouchet/flowstep/actions/workflows/check-lint.yaml)
Flowstep is a Python library that provides enhanced control flow functionalities for iterating over iterables. It allows you to pause, resume, skip, or stop the iteration process based on conditions and user interaction.
## Key Features:
- Pause and Resume Iteration: Temporarily halt the iteration and resume at your convenience.
- Conditional Skipping: Define custom logic to skip specific elements based on your criteria.
- User Interaction: Interact with the flow during pauses to choose the next action (resume, skip, or stop).
- Clear Messaging: Receive informative messages during pauses and actions (optional).
- Context Manager Integration: Use Flowstep within a with statement for easy flow management.
## Benefits:
- Streamline complex iteration logic: Easily manage complex workflows with conditional processing and user interaction.
- Improve code readability: Separate iteration logic from your core functionality for better maintainability.
- Enhance user experience: Provide users with control over the processing flow, especially for large datasets.
## Installation:
```bash
pip install flowstep
```
Use o código com cuidado.
## Usage:
Here's a basic example demonstrating how to use Flowstep to iterate over a list with conditional skipping and informative messages:
```Python
from flowstep import Flow
data = [1, 2, 3, 4, 5]
skip_condition = lambda x: x % 2 == 0 # Skip even numbers
with Flow(data, skip_condition=skip_condition, verbose=True) as flow:
for index, item in flow:
print(f"Processing item: {item} (Index: {index})")
```
This code iterates over the data list, skipping even numbers based on the provided skip_condition function. During pauses (triggered by user input), the library will display informative messages to guide the user's choice (resume, skip, or stop).
# Contributing:
We welcome contributions to Flowstep! Feel free to submit pull requests for bug fixes, new features, or improvements. Make sure to add appropriate tests and update the documentation request as needed.
# License:
Flowstep is distributed under the [License Name] License. See the LICENSE file for details.
Take control of your iterations with Flowstep!
Raw data
{
"_id": null,
"home_page": null,
"name": "flowstep",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.8",
"maintainer_email": null,
"keywords": null,
"author": "Bruno Peixoto",
"author_email": "brunolnetto@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/27/ec/a87805ecf6e917ea6db2617331f3d8984e47e5ce8e61b715e4bb91d95fd7/flowstep-0.0.1.tar.gz",
"platform": null,
"description": "# Flowstep\n\n[![Version](https://img.shields.io/pypi/v/flowstep.svg)](https://pypi.python.org/pypi/flowstep)\n[![downloads](https://img.shields.io/pypi/dm/flowstep)](https://pypi.org/project/flowstep/)\n\n[![codecov](https://codecov.io/gh/trouchet/flowstep/branch/main/graph/badge.svg?token=PJMBaLIqar)](https://codecov.io/gh/trouchet/flowstep)\n[![Lint workflow](https://github.com/trouchet/flowstep/actions/workflows/check-lint.yaml/badge.svg)](https://github.com/trouchet/flowstep/actions/workflows/check-lint.yaml)\n\nFlowstep is a Python library that provides enhanced control flow functionalities for iterating over iterables. It allows you to pause, resume, skip, or stop the iteration process based on conditions and user interaction.\n\n## Key Features:\n\n- Pause and Resume Iteration: Temporarily halt the iteration and resume at your convenience.\n- Conditional Skipping: Define custom logic to skip specific elements based on your criteria.\n- User Interaction: Interact with the flow during pauses to choose the next action (resume, skip, or stop).\n- Clear Messaging: Receive informative messages during pauses and actions (optional).\n- Context Manager Integration: Use Flowstep within a with statement for easy flow management.\n\n## Benefits:\n\n- Streamline complex iteration logic: Easily manage complex workflows with conditional processing and user interaction.\n- Improve code readability: Separate iteration logic from your core functionality for better maintainability.\n- Enhance user experience: Provide users with control over the processing flow, especially for large datasets.\n\n## Installation:\n\n```bash\npip install flowstep\n```\n\nUse o c\u00f3digo com cuidado.\n\n## Usage:\n\nHere's a basic example demonstrating how to use Flowstep to iterate over a list with conditional skipping and informative messages:\n\n```Python\nfrom flowstep import Flow\n\ndata = [1, 2, 3, 4, 5]\nskip_condition = lambda x: x % 2 == 0 # Skip even numbers\n\nwith Flow(data, skip_condition=skip_condition, verbose=True) as flow:\n for index, item in flow:\n print(f\"Processing item: {item} (Index: {index})\")\n```\n\nThis code iterates over the data list, skipping even numbers based on the provided skip_condition function. During pauses (triggered by user input), the library will display informative messages to guide the user's choice (resume, skip, or stop).\n\n\n# Contributing:\n\nWe welcome contributions to Flowstep! Feel free to submit pull requests for bug fixes, new features, or improvements. Make sure to add appropriate tests and update the documentation request as needed.\n\n# License:\n\nFlowstep is distributed under the [License Name] License. See the LICENSE file for details.\n\nTake control of your iterations with Flowstep!\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Manages individual steps within a flow.",
"version": "0.0.1",
"project_urls": null,
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "2475bb7ae793cb03633c37c1bc1d688eba654c6857968902844e4d44fdc9081e",
"md5": "5f866e4b1b03f6fea50827f46ca10f94",
"sha256": "fd49ca26b26de7589d24022b5a1905bfde88917b9689ca9e44f9f12ca18d3d99"
},
"downloads": -1,
"filename": "flowstep-0.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "5f866e4b1b03f6fea50827f46ca10f94",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.8",
"size": 8151,
"upload_time": "2024-05-19T22:41:23",
"upload_time_iso_8601": "2024-05-19T22:41:23.155406Z",
"url": "https://files.pythonhosted.org/packages/24/75/bb7ae793cb03633c37c1bc1d688eba654c6857968902844e4d44fdc9081e/flowstep-0.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "27eca87805ecf6e917ea6db2617331f3d8984e47e5ce8e61b715e4bb91d95fd7",
"md5": "ff152970457c571e4bf3334e5c9cbaa1",
"sha256": "22cb8e61fad669381918ec9617a8290c5bf2bbe2a9c136f8d24698f53dddcdbe"
},
"downloads": -1,
"filename": "flowstep-0.0.1.tar.gz",
"has_sig": false,
"md5_digest": "ff152970457c571e4bf3334e5c9cbaa1",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.8",
"size": 6294,
"upload_time": "2024-05-19T22:41:25",
"upload_time_iso_8601": "2024-05-19T22:41:25.507314Z",
"url": "https://files.pythonhosted.org/packages/27/ec/a87805ecf6e917ea6db2617331f3d8984e47e5ce8e61b715e4bb91d95fd7/flowstep-0.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-19 22:41:25",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "flowstep"
}