summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-05-15 08:12:23 +0000
committerCoprDistGit <infra@openeuler.org>2023-05-15 08:12:23 +0000
commit9e6c41b41f90e3b3d888ae487066e5faaa08d71d (patch)
tree1b57643f84ae513a066345cc9e19a7a868874ee2
parented416a5b06309a34899cddf93e3c9721946bb73a (diff)
automatic import of python-bareclient
-rw-r--r--.gitignore1
-rw-r--r--python-bareclient.spec252
-rw-r--r--sources1
3 files changed, 254 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..0bc78d3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/bareclient-5.0.1.tar.gz
diff --git a/python-bareclient.spec b/python-bareclient.spec
new file mode 100644
index 0000000..c9cef7f
--- /dev/null
+++ b/python-bareclient.spec
@@ -0,0 +1,252 @@
+%global _empty_manifest_terminate_build 0
+Name: python-bareclient
+Version: 5.0.1
+Release: 1
+Summary: A lightweight asyncio HTTP client
+License: Apache-2.0
+URL: https://github.com/rob-blackbourn/bareClient
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/af/6b/23268543c1698b07fb5ab4765fa8e2d0f11c28cd9a0037cfc6a009b8621e/bareclient-5.0.1.tar.gz
+BuildArch: noarch
+
+Requires: python3-bareutils
+Requires: python3-h11
+Requires: python3-h2
+
+%description
+# bareClient
+
+An asyncio HTTP Python client package supporting HTTP versions 1.0, 1.1
+and 2 (read the [docs](https://rob-blackbourn.github.io/bareClient/)).
+
+This is the client companion to the ASGI server side web framework
+[bareASGI](https://github.com/rob-blackbourn/bareASGI) and follows the same
+"bare" approach. It provides only the essential functionality and makes little
+attempt to provide any helpful features which might do unnecessary work.
+
+This package is suitable for:
+
+- A foundation for async HTTP/2 clients,
+- Async REST client API's,
+- Containers requiring a small image size,
+- Integration with ASGI web servers requiring async HTTP client access.
+
+## Features
+
+The client has the following notable features:
+
+- Lightweight
+- Uses asyncio
+- Supports HTTP versions 1.0, 1.1, 2
+- Supports middleware
+
+## Installation
+
+The package can be installed with pip.
+
+```bash
+pip install bareclient
+```
+
+This is a Python3.7 and later package.
+
+It has dependencies on:
+
+- [bareUtils](https://github.com/rob-blackbourn/bareUtils)
+- [h11](https://github.com/python-hyper/h11)
+- [h2](https://github.com/python-hyper/hyper-h2)
+
+## Usage
+
+The basic usage is to create an `HttpClient`.
+
+```python
+import asyncio
+from typing import List, Optional
+from bareclient import HttpClient
+
+async def main(url: str) -> None:
+ async with HttpClient(url) as response:
+ if response.ok and response.more_body:
+ async for part in response.body:
+ print(part)
+
+asyncio.run(main('https://docs.python.org/3/library/cgi.html'))
+```
+
+
+%package -n python3-bareclient
+Summary: A lightweight asyncio HTTP client
+Provides: python-bareclient
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-bareclient
+# bareClient
+
+An asyncio HTTP Python client package supporting HTTP versions 1.0, 1.1
+and 2 (read the [docs](https://rob-blackbourn.github.io/bareClient/)).
+
+This is the client companion to the ASGI server side web framework
+[bareASGI](https://github.com/rob-blackbourn/bareASGI) and follows the same
+"bare" approach. It provides only the essential functionality and makes little
+attempt to provide any helpful features which might do unnecessary work.
+
+This package is suitable for:
+
+- A foundation for async HTTP/2 clients,
+- Async REST client API's,
+- Containers requiring a small image size,
+- Integration with ASGI web servers requiring async HTTP client access.
+
+## Features
+
+The client has the following notable features:
+
+- Lightweight
+- Uses asyncio
+- Supports HTTP versions 1.0, 1.1, 2
+- Supports middleware
+
+## Installation
+
+The package can be installed with pip.
+
+```bash
+pip install bareclient
+```
+
+This is a Python3.7 and later package.
+
+It has dependencies on:
+
+- [bareUtils](https://github.com/rob-blackbourn/bareUtils)
+- [h11](https://github.com/python-hyper/h11)
+- [h2](https://github.com/python-hyper/hyper-h2)
+
+## Usage
+
+The basic usage is to create an `HttpClient`.
+
+```python
+import asyncio
+from typing import List, Optional
+from bareclient import HttpClient
+
+async def main(url: str) -> None:
+ async with HttpClient(url) as response:
+ if response.ok and response.more_body:
+ async for part in response.body:
+ print(part)
+
+asyncio.run(main('https://docs.python.org/3/library/cgi.html'))
+```
+
+
+%package help
+Summary: Development documents and examples for bareclient
+Provides: python3-bareclient-doc
+%description help
+# bareClient
+
+An asyncio HTTP Python client package supporting HTTP versions 1.0, 1.1
+and 2 (read the [docs](https://rob-blackbourn.github.io/bareClient/)).
+
+This is the client companion to the ASGI server side web framework
+[bareASGI](https://github.com/rob-blackbourn/bareASGI) and follows the same
+"bare" approach. It provides only the essential functionality and makes little
+attempt to provide any helpful features which might do unnecessary work.
+
+This package is suitable for:
+
+- A foundation for async HTTP/2 clients,
+- Async REST client API's,
+- Containers requiring a small image size,
+- Integration with ASGI web servers requiring async HTTP client access.
+
+## Features
+
+The client has the following notable features:
+
+- Lightweight
+- Uses asyncio
+- Supports HTTP versions 1.0, 1.1, 2
+- Supports middleware
+
+## Installation
+
+The package can be installed with pip.
+
+```bash
+pip install bareclient
+```
+
+This is a Python3.7 and later package.
+
+It has dependencies on:
+
+- [bareUtils](https://github.com/rob-blackbourn/bareUtils)
+- [h11](https://github.com/python-hyper/h11)
+- [h2](https://github.com/python-hyper/hyper-h2)
+
+## Usage
+
+The basic usage is to create an `HttpClient`.
+
+```python
+import asyncio
+from typing import List, Optional
+from bareclient import HttpClient
+
+async def main(url: str) -> None:
+ async with HttpClient(url) as response:
+ if response.ok and response.more_body:
+ async for part in response.body:
+ print(part)
+
+asyncio.run(main('https://docs.python.org/3/library/cgi.html'))
+```
+
+
+%prep
+%autosetup -n bareclient-5.0.1
+
+%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-bareclient -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Mon May 15 2023 Python_Bot <Python_Bot@openeuler.org> - 5.0.1-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..54fcf54
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+43aab75cf7357229597b3321014d435d bareclient-5.0.1.tar.gz