Skip to content

Commit

Permalink
release 1.638.24140
Browse files Browse the repository at this point in the history
  • Loading branch information
klahnakoski committed May 19, 2024
2 parents 1580d3c + bb2475b commit ee49a78
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 23 deletions.
4 changes: 2 additions & 2 deletions packaging/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
description='More Streams! Chained function calls',
extras_require={"tests":["mo-files>=6.624.24125","mo-logs>=8.623.24125","zstandard>=0.22.0","boto3>=1.34.98","moto>=4.2.14","pandas>=2.0.3","mo-threads>=6.623.24125","mo-testing>=8.623.24125","mo-threads>=6.623.24125"]},
include_package_data=True,
install_requires=["mo-dots==10.623.24125","mo-files==6.624.24125","mo-future==7.584.24095","mo-json==6.624.24125"],
install_requires=["mo-dots==10.632.24139","mo-files==6.638.24140","mo-future==7.584.24095","mo-json==6.637.24140"],
license='MPL 2.0',
long_description='# More Streams!!\n\n[![PyPI Latest Release](https://img.shields.io/pypi/v/mo-streams.svg)](https://pypi.org/project/mo-streams/)\n [![Build Status](https://github.com/klahnakoski/mo-streams/actions/workflows/build.yml/badge.svg?branch=master)](https://github.com/klahnakoski/mo-streams/actions/workflows/build.yml)\n [![Coverage Status](https://coveralls.io/repos/github/klahnakoski/mo-streams/badge.svg?branch=dev)](https://coveralls.io/github/klahnakoski/mo-streams?branch=dev)\n[![Downloads](https://pepy.tech/badge/mo-streams/month)](https://pepy.tech/project/mo-streams)\n\n\nPython code is more elegant with method chaining!\n\n\n## Overview\n\nThere are two families of "streams" in this library, both are lazy:\n\n1. `ByteStream` - a traditional stream of bytes intended to pipe bytes through various byte transformers, like compression, encoding and encyrption. \n2. `ObjectStream`: An iterator/generator with a number of useful methods.\n\n### Example\n\nIn this case I am iterating through all files in a tar and parsing them:\n\n results = (\n File("tests/so_queries/so_queries.tar.zst")\n .content()\n .content()\n .exists()\n .utf8()\n .to_str()\n .map(parse)\n .to_list()\n )\n \n Each of the steps constructs a generator, and no work is done until the last step\n \n \n * `File().content()` - will unzst and untar the file content to an `ObjectStream` of file-like objects. It is short form for `stream(File().read_bytes()).from_zst().from_tar()`\n * The second `.content()` is applied to each of the file-like objects, returning `ByteStream` of the content for each\n * `.exists()` - some of the files (aka directories) in the tar file do not have content, we only include content that exists.\n * `.utf8` - convert to a `StringStream`\n * `.to_str` - convert to a Python `str`, we trust the content is not too large\n * `.map(parse)` - run the parser on each string\n * `.to_list()` - a "terminator", which executes the chain and returns a Python `list` with the results\n \n## Project Status\n\nAlive and in use, but \n\n* basic functions missing\n* inefficient - written using generators\n* generators not properly closed\n\n\n## Optional Reading\n\nThe method chaining style has two distinct benefits\n\n* functions are in the order they are applied \n* intermediate values need no temporary variables\n\nThe detriments are the same that we find in any declarative language: Incorrect code can be difficult to debug because you can not step through it to isolate the problem. For this reason, the majority of the code in this library is dedicated to validating the links in the function chain before they are run.\n\n### Lessons\n\nThe function chaining style, called "streams" in Java or "linq" in C#, leans heavly on the strict typed nature of those langauges. This is missing in Python, but type annotations help support this style of programming.\n\n',
long_description_content_type='text/markdown',
name='mo-streams',
packages=["mo_streams"],
url='https://github.com/klahnakoski/mo-streams',
version='1.625.24125',
version='1.638.24140',
zip_safe=False
)
6 changes: 3 additions & 3 deletions packaging/setuptools.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
]},
"include_package_data": true,
"install_requires": [
"mo-dots==10.623.24125", "mo-files==6.624.24125", "mo-future==7.584.24095",
"mo-json==6.624.24125"
"mo-dots==10.632.24139", "mo-files==6.638.24140", "mo-future==7.584.24095",
"mo-json==6.637.24140"
],
"license": "MPL 2.0",
"long_description": {
Expand Down Expand Up @@ -100,6 +100,6 @@
"name": "mo-streams",
"packages": ["mo_streams"],
"url": "https://github.com/klahnakoski/mo-streams",
"version": "1.625.24125",
"version": "1.638.24140",
"zip_safe": false
}
24 changes: 12 additions & 12 deletions tests/requirements.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Tests pass with python 3.8 on 2024-05-04 and with these versions
# Tests pass with python 3.8 on 2024-05-19 and with these versions
# pip install --no-deps -r tests/requirements.lock
boto3==1.34.98
botocore==1.34.98
boto3==1.34.108
botocore==1.34.108
certifi==2024.2.2
cffi==1.16.0
charset-normalizer==3.3.2
Expand All @@ -12,17 +12,17 @@ Jinja2==3.1.3
jmespath==1.0.1
MarkupSafe==2.1.5
mo-collections==5.623.24125
mo-dots==10.623.24125
mo-files==6.624.24125
mo-dots==10.632.24139
mo-files==6.638.24140
mo-future==7.584.24095
mo-imports==7.584.24095
mo-json==6.624.24125
mo-kwargs==7.623.24125
mo-logs==8.623.24125
mo-math==7.623.24125
mo-testing==8.623.24125
mo-threads==6.623.24125
mo-times==5.623.24125
mo-json==6.637.24140
mo-kwargs==7.632.24139
mo-logs==8.632.24139
mo-math==7.632.24139
mo-testing==8.633.24139
mo-threads==6.634.24139
mo-times==5.632.24139
moto==4.2.14
numpy # 1.24.4 version locking causes: No module named 'distutils'
pandas # 2.0.3 version locking causes: Could not build wheels for pandas
Expand Down
12 changes: 6 additions & 6 deletions tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
mo-files>=6.624.24125
mo-logs>=8.623.24125
mo-files>=6.638.24140
mo-logs>=8.632.24139
zstandard>=0.22.0
boto3>=1.34.98
boto3>=1.34.108
moto>=4.2.14,<5
pandas>=2.0.3
mo-threads>=6.623.24125
mo-testing>=8.623.24125
mo-threads>=6.623.24125
mo-threads>=6.634.24139
mo-testing>=8.633.24139
mo-threads>=6.634.24139

0 comments on commit ee49a78

Please sign in to comment.