summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-05-31 07:45:44 +0000
committerCoprDistGit <infra@openeuler.org>2023-05-31 07:45:44 +0000
commit0486fd65e78005dbec661e8395bfc753387ac511 (patch)
treed90925e7322cedcff9ca932327e9a06886161d61
parentecbf80ccb47eab00b4aba0e64c102ac7f08df9c6 (diff)
automatic import of python-pybeatsaver
-rw-r--r--.gitignore1
-rw-r--r--python-pybeatsaver.spec262
-rw-r--r--sources1
3 files changed, 264 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..78d5f96 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/PyBeatSaver-0.1.15.tar.gz
diff --git a/python-pybeatsaver.spec b/python-pybeatsaver.spec
new file mode 100644
index 0000000..9745fde
--- /dev/null
+++ b/python-pybeatsaver.spec
@@ -0,0 +1,262 @@
+%global _empty_manifest_terminate_build 0
+Name: python-PyBeatSaver
+Version: 0.1.15
+Release: 1
+Summary: Beat Saver API wrapper
+License: MIT License
+URL: https://github.com/Kiyomi-Parents/PyBeatSaver
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/0a/83/ededce13512e8263e8d3655e48cf125a0451c31c2d13ed0315d0503670ff/PyBeatSaver-0.1.15.tar.gz
+BuildArch: noarch
+
+Requires: python3-OutCache
+Requires: python3-dateutil
+Requires: python3-marshmallow
+Requires: python3-dataclasses-json
+Requires: python3-aiohttp
+Requires: python3-Faker
+Requires: python3-coverage
+Requires: python3-pytest
+Requires: python3-pytest-asyncio
+Requires: python3-pytest-cov
+
+%description
+[![GitHub license](https://img.shields.io/github/license/Kiyomi-Parents/PyBeatSaver)](https://github.com/Kiyomi-Parents/PyBeatSaver/blob/master/LICENSE)
+[![PyPI version](https://badge.fury.io/py/PyBeatSaver.svg)](https://pypi.org/project/PyBeatSaver)
+[![codecov](https://codecov.io/gh/Kiyomi-Parents/PyBeatSaver/branch/master/graph/badge.svg?token=IUFZTBDVEE)](https://codecov.io/gh/Kiyomi-Parents/PyBeatSaver)
+[![PyPI supported Python versions](https://img.shields.io/pypi/pyversions/pybeatsaver.svg)](https://pypi.org/project/PyBeatSaver)
+[![PyPI downloads](https://img.shields.io/pypi/dm/pybeatsaver?color=blueviolet&logo=pypi)](https://pypi.org/project/PyBeatSaver)
+# PyBeatSaver
+Beat Saver API wrapper
+
+### Features
+* Rate Limit handling
+* Query Caching
+* Everything is ``async``
+* Additional helper methods and async generators
+* Faker data provider
+
+The faker data mode can be activated with the following ```beatsaver = BeatSaverAPI(test_mode=True)```.
+This will return random data instead of making API requests to Beat Saver.
+
+### Usage:
+```python
+import asyncio
+from pybeatsaver import BeatSaverAPI, BeatSaver
+
+
+async def main():
+ async with BeatSaverAPI() as beatsaver:
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+# Without "async with" syntax
+async def main2():
+ beatsaver = BeatSaver()
+ await beatsaver.start()
+
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+# Get fake data instead
+async def main_fake():
+ async with BeatSaverAPI(test_mode=True) as beatsaver:
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+asyncio.run(main())
+asyncio.run(main2())
+asyncio.run(main_fake())
+```
+
+### Faker provider:
+```python
+from faker import Faker
+from pybeatsaver import BeatSaverProvider
+
+
+faker = Faker()
+faker.add_provider(BeatSaverProvider)
+
+beatmap = faker.map_detail()
+print(beatmap)
+```
+
+
+%package -n python3-PyBeatSaver
+Summary: Beat Saver API wrapper
+Provides: python-PyBeatSaver
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-PyBeatSaver
+[![GitHub license](https://img.shields.io/github/license/Kiyomi-Parents/PyBeatSaver)](https://github.com/Kiyomi-Parents/PyBeatSaver/blob/master/LICENSE)
+[![PyPI version](https://badge.fury.io/py/PyBeatSaver.svg)](https://pypi.org/project/PyBeatSaver)
+[![codecov](https://codecov.io/gh/Kiyomi-Parents/PyBeatSaver/branch/master/graph/badge.svg?token=IUFZTBDVEE)](https://codecov.io/gh/Kiyomi-Parents/PyBeatSaver)
+[![PyPI supported Python versions](https://img.shields.io/pypi/pyversions/pybeatsaver.svg)](https://pypi.org/project/PyBeatSaver)
+[![PyPI downloads](https://img.shields.io/pypi/dm/pybeatsaver?color=blueviolet&logo=pypi)](https://pypi.org/project/PyBeatSaver)
+# PyBeatSaver
+Beat Saver API wrapper
+
+### Features
+* Rate Limit handling
+* Query Caching
+* Everything is ``async``
+* Additional helper methods and async generators
+* Faker data provider
+
+The faker data mode can be activated with the following ```beatsaver = BeatSaverAPI(test_mode=True)```.
+This will return random data instead of making API requests to Beat Saver.
+
+### Usage:
+```python
+import asyncio
+from pybeatsaver import BeatSaverAPI, BeatSaver
+
+
+async def main():
+ async with BeatSaverAPI() as beatsaver:
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+# Without "async with" syntax
+async def main2():
+ beatsaver = BeatSaver()
+ await beatsaver.start()
+
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+# Get fake data instead
+async def main_fake():
+ async with BeatSaverAPI(test_mode=True) as beatsaver:
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+asyncio.run(main())
+asyncio.run(main2())
+asyncio.run(main_fake())
+```
+
+### Faker provider:
+```python
+from faker import Faker
+from pybeatsaver import BeatSaverProvider
+
+
+faker = Faker()
+faker.add_provider(BeatSaverProvider)
+
+beatmap = faker.map_detail()
+print(beatmap)
+```
+
+
+%package help
+Summary: Development documents and examples for PyBeatSaver
+Provides: python3-PyBeatSaver-doc
+%description help
+[![GitHub license](https://img.shields.io/github/license/Kiyomi-Parents/PyBeatSaver)](https://github.com/Kiyomi-Parents/PyBeatSaver/blob/master/LICENSE)
+[![PyPI version](https://badge.fury.io/py/PyBeatSaver.svg)](https://pypi.org/project/PyBeatSaver)
+[![codecov](https://codecov.io/gh/Kiyomi-Parents/PyBeatSaver/branch/master/graph/badge.svg?token=IUFZTBDVEE)](https://codecov.io/gh/Kiyomi-Parents/PyBeatSaver)
+[![PyPI supported Python versions](https://img.shields.io/pypi/pyversions/pybeatsaver.svg)](https://pypi.org/project/PyBeatSaver)
+[![PyPI downloads](https://img.shields.io/pypi/dm/pybeatsaver?color=blueviolet&logo=pypi)](https://pypi.org/project/PyBeatSaver)
+# PyBeatSaver
+Beat Saver API wrapper
+
+### Features
+* Rate Limit handling
+* Query Caching
+* Everything is ``async``
+* Additional helper methods and async generators
+* Faker data provider
+
+The faker data mode can be activated with the following ```beatsaver = BeatSaverAPI(test_mode=True)```.
+This will return random data instead of making API requests to Beat Saver.
+
+### Usage:
+```python
+import asyncio
+from pybeatsaver import BeatSaverAPI, BeatSaver
+
+
+async def main():
+ async with BeatSaverAPI() as beatsaver:
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+# Without "async with" syntax
+async def main2():
+ beatsaver = BeatSaver()
+ await beatsaver.start()
+
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+# Get fake data instead
+async def main_fake():
+ async with BeatSaverAPI(test_mode=True) as beatsaver:
+ beatmap = await beatsaver.beatmap("16d22")
+ print(beatmap)
+
+asyncio.run(main())
+asyncio.run(main2())
+asyncio.run(main_fake())
+```
+
+### Faker provider:
+```python
+from faker import Faker
+from pybeatsaver import BeatSaverProvider
+
+
+faker = Faker()
+faker.add_provider(BeatSaverProvider)
+
+beatmap = faker.map_detail()
+print(beatmap)
+```
+
+
+%prep
+%autosetup -n PyBeatSaver-0.1.15
+
+%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-PyBeatSaver -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.15-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..92e2d93
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+36cc9f929d131cd17bf9ec3bd377625b PyBeatSaver-0.1.15.tar.gz