diff options
author | CoprDistGit <infra@openeuler.org> | 2023-05-31 05:13:33 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2023-05-31 05:13:33 +0000 |
commit | 9c7678a306f19cb93151e71d40c90f98a55645d3 (patch) | |
tree | 6e80af574a638945181b8ef7d69312a69f1e5ad0 | |
parent | a033bdecfa18e90ae7ea85128bc5ffb184e2454b (diff) |
automatic import of python-ness
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | python-ness.spec | 326 | ||||
-rw-r--r-- | sources | 1 |
3 files changed, 328 insertions, 0 deletions
@@ -0,0 +1 @@ +/ness-0.1.5.tar.gz diff --git a/python-ness.spec b/python-ness.spec new file mode 100644 index 0000000..a252e8b --- /dev/null +++ b/python-ness.spec @@ -0,0 +1,326 @@ +%global _empty_manifest_terminate_build 0 +Name: python-ness +Version: 0.1.5 +Release: 1 +Summary: A Python datalake client. +License: MIT +URL: https://github.com/postpayio/ness +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/50/46/553614eae9025f85136dfde16ee5d0c8bf8fc2005cb10a7387562df27eed/ness-0.1.5.tar.gz +BuildArch: noarch + +Requires: python3-pandas +Requires: python3-click + +%description +# Ness + +<p align="center"> + <em>A Python datalake client.</em> +</p> +<p align="center"> + <a href="https://github.com/postpayio/ness/actions"> + <img src="https://github.com/postpayio/ness/actions/workflows/test-suite.yml/badge.svg" alt="Test"> + </a> + <a href="https://codecov.io/gh/postpayio/ness"> + <img src="https://img.shields.io/codecov/c/github/postpayio/ness?color=%2334D058" alt="Coverage"> + </a> + <a href="https://pypi.org/project/ness"> + <img src="https://img.shields.io/pypi/v/ness" alt="Package version"> + </a> +</p> + +## Requirements + +- [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) + +## Installation + +```sh +pip install pyarrow ness +``` + +## Quickstart + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake") +df = dl.read("mytable") +``` + +## Sync + +```py +# Sync all tables +dl.sync() + +# Sync a single table +dl.sync("mytable") + +# Sync and read a single table +df = dl.read("mytable", sync=True) +``` + +## Format + +Specify the input data source format, the default format is `parquet`: + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake", format="csv") +``` + +## AWS Profile + +Files are synced using `default` AWS profile, you can configure another one: + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake", profile="myprofile") +``` + +## Command Line + +``` +Usage: ness sync [OPTIONS] S3_URI + +Options: + --format TEXT Data lake source format. + --profile TEXT AWS profile. + --table TEXT Table name to sync. + --help Show this message and exit. +``` + +```sh +ness sync bucket/key --table mytable +``` + + +%package -n python3-ness +Summary: A Python datalake client. +Provides: python-ness +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-ness +# Ness + +<p align="center"> + <em>A Python datalake client.</em> +</p> +<p align="center"> + <a href="https://github.com/postpayio/ness/actions"> + <img src="https://github.com/postpayio/ness/actions/workflows/test-suite.yml/badge.svg" alt="Test"> + </a> + <a href="https://codecov.io/gh/postpayio/ness"> + <img src="https://img.shields.io/codecov/c/github/postpayio/ness?color=%2334D058" alt="Coverage"> + </a> + <a href="https://pypi.org/project/ness"> + <img src="https://img.shields.io/pypi/v/ness" alt="Package version"> + </a> +</p> + +## Requirements + +- [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) + +## Installation + +```sh +pip install pyarrow ness +``` + +## Quickstart + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake") +df = dl.read("mytable") +``` + +## Sync + +```py +# Sync all tables +dl.sync() + +# Sync a single table +dl.sync("mytable") + +# Sync and read a single table +df = dl.read("mytable", sync=True) +``` + +## Format + +Specify the input data source format, the default format is `parquet`: + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake", format="csv") +``` + +## AWS Profile + +Files are synced using `default` AWS profile, you can configure another one: + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake", profile="myprofile") +``` + +## Command Line + +``` +Usage: ness sync [OPTIONS] S3_URI + +Options: + --format TEXT Data lake source format. + --profile TEXT AWS profile. + --table TEXT Table name to sync. + --help Show this message and exit. +``` + +```sh +ness sync bucket/key --table mytable +``` + + +%package help +Summary: Development documents and examples for ness +Provides: python3-ness-doc +%description help +# Ness + +<p align="center"> + <em>A Python datalake client.</em> +</p> +<p align="center"> + <a href="https://github.com/postpayio/ness/actions"> + <img src="https://github.com/postpayio/ness/actions/workflows/test-suite.yml/badge.svg" alt="Test"> + </a> + <a href="https://codecov.io/gh/postpayio/ness"> + <img src="https://img.shields.io/codecov/c/github/postpayio/ness?color=%2334D058" alt="Coverage"> + </a> + <a href="https://pypi.org/project/ness"> + <img src="https://img.shields.io/pypi/v/ness" alt="Package version"> + </a> +</p> + +## Requirements + +- [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) + +## Installation + +```sh +pip install pyarrow ness +``` + +## Quickstart + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake") +df = dl.read("mytable") +``` + +## Sync + +```py +# Sync all tables +dl.sync() + +# Sync a single table +dl.sync("mytable") + +# Sync and read a single table +df = dl.read("mytable", sync=True) +``` + +## Format + +Specify the input data source format, the default format is `parquet`: + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake", format="csv") +``` + +## AWS Profile + +Files are synced using `default` AWS profile, you can configure another one: + +```py +import ness + +dl = ness.dl(bucket="mybucket", key="mydatalake", profile="myprofile") +``` + +## Command Line + +``` +Usage: ness sync [OPTIONS] S3_URI + +Options: + --format TEXT Data lake source format. + --profile TEXT AWS profile. + --table TEXT Table name to sync. + --help Show this message and exit. +``` + +```sh +ness sync bucket/key --table mytable +``` + + +%prep +%autosetup -n ness-0.1.5 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-ness -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Wed May 31 2023 Python_Bot <Python_Bot@openeuler.org> - 0.1.5-1 +- Package Spec generated @@ -0,0 +1 @@ +caf61435b554edeabcd99df13ddf7cbd ness-0.1.5.tar.gz |