python-ballchasing 0.1.22__tar.gz → 0.2.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/LICENSE +21 -21
- python_ballchasing-0.2.0/PKG-INFO +36 -0
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/README.md +19 -21
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/ballchasing/__init__.py +67 -49
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/ballchasing/api.py +427 -444
- python_ballchasing-0.2.0/ballchasing/constants.py +202 -0
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/ballchasing/stats_info.tsv +142 -142
- python_ballchasing-0.2.0/ballchasing/util.py +100 -0
- python_ballchasing-0.2.0/pyproject.toml +32 -0
- python_ballchasing-0.2.0/python_ballchasing.egg-info/PKG-INFO +36 -0
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/python_ballchasing.egg-info/SOURCES.txt +1 -1
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/python_ballchasing.egg-info/top_level.txt +1 -0
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/setup.cfg +4 -4
- python-ballchasing-0.1.22/PKG-INFO +0 -37
- python-ballchasing-0.1.22/ballchasing/constants.py +0 -166
- python-ballchasing-0.1.22/ballchasing/util.py +0 -73
- python-ballchasing-0.1.22/python_ballchasing.egg-info/PKG-INFO +0 -37
- python-ballchasing-0.1.22/setup.py +0 -27
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/python_ballchasing.egg-info/dependency_links.txt +0 -0
- {python-ballchasing-0.1.22 → python_ballchasing-0.2.0}/python_ballchasing.egg-info/requires.txt +0 -0
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2020 Rolv-Arild Braaten
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2020 Rolv-Arild Braaten
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: python-ballchasing
|
|
3
|
+
Version: 0.2.0
|
|
4
|
+
Summary: A Python wrapper around the Ballchasing API
|
|
5
|
+
Author-email: Rolv-Arild Braaten <rolv_arild@hotmail.com>
|
|
6
|
+
License: MIT License
|
|
7
|
+
Project-URL: Homepage, https://github.com/Rolv-Arild/python-ballchasing
|
|
8
|
+
Project-URL: Download, https://pypi.python.org/pypi/python-ballchasing
|
|
9
|
+
Classifier: Programming Language :: Python :: 3.8
|
|
10
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
11
|
+
Classifier: Operating System :: OS Independent
|
|
12
|
+
Requires-Python: >=3.9
|
|
13
|
+
Description-Content-Type: text/markdown
|
|
14
|
+
License-File: LICENSE
|
|
15
|
+
Requires-Dist: requests
|
|
16
|
+
Dynamic: license-file
|
|
17
|
+
|
|
18
|
+
# Python Ballchasing
|
|
19
|
+
Python wrapper for the ballchasing.com API.
|
|
20
|
+
|
|
21
|
+
# Installation
|
|
22
|
+
```
|
|
23
|
+
pip install python-ballchasing
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
# API
|
|
27
|
+
The API is exposed via the `ballchasing.Api` class.
|
|
28
|
+
|
|
29
|
+
Simple example:
|
|
30
|
+
```python
|
|
31
|
+
import ballchasing
|
|
32
|
+
api = ballchasing.Api("Your token here")
|
|
33
|
+
|
|
34
|
+
# Get a specific replay
|
|
35
|
+
replay = api.get_replay("2627e02a-aa46-4e13-b66b-b76a32069a07")
|
|
36
|
+
```
|
|
@@ -1,21 +1,19 @@
|
|
|
1
|
-
# Python Ballchasing
|
|
2
|
-
Python wrapper for the ballchasing.com API.
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
```
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
replay = api.get_replay("2627e02a-aa46-4e13-b66b-b76a32069a07")
|
|
21
|
-
```
|
|
1
|
+
# Python Ballchasing
|
|
2
|
+
Python wrapper for the ballchasing.com API.
|
|
3
|
+
|
|
4
|
+
# Installation
|
|
5
|
+
```
|
|
6
|
+
pip install python-ballchasing
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
# API
|
|
10
|
+
The API is exposed via the `ballchasing.Api` class.
|
|
11
|
+
|
|
12
|
+
Simple example:
|
|
13
|
+
```python
|
|
14
|
+
import ballchasing
|
|
15
|
+
api = ballchasing.Api("Your token here")
|
|
16
|
+
|
|
17
|
+
# Get a specific replay
|
|
18
|
+
replay = api.get_replay("2627e02a-aa46-4e13-b66b-b76a32069a07")
|
|
19
|
+
```
|
|
@@ -1,49 +1,67 @@
|
|
|
1
|
-
#!/usr/bin/env python
|
|
2
|
-
# MIT License
|
|
3
|
-
#
|
|
4
|
-
# Copyright (c) 2020 Rolv-Arild Braaten
|
|
5
|
-
#
|
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
|
11
|
-
# furnished to do so, subject to the following conditions:
|
|
12
|
-
#
|
|
13
|
-
# The above copyright notice and this permission notice shall be included in all
|
|
14
|
-
# copies or substantial portions of the Software.
|
|
15
|
-
#
|
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
|
-
# SOFTWARE.
|
|
23
|
-
|
|
24
|
-
"""A library that provides a Python interface to the Ballchasing API."""
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
1
|
+
#!/usr/bin/env python
|
|
2
|
+
# MIT License
|
|
3
|
+
#
|
|
4
|
+
# Copyright (c) 2020 Rolv-Arild Braaten
|
|
5
|
+
#
|
|
6
|
+
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
+
# of this software and associated documentation files (the "Software"), to deal
|
|
8
|
+
# in the Software without restriction, including without limitation the rights
|
|
9
|
+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
+
# copies of the Software, and to permit persons to whom the Software is
|
|
11
|
+
# furnished to do so, subject to the following conditions:
|
|
12
|
+
#
|
|
13
|
+
# The above copyright notice and this permission notice shall be included in all
|
|
14
|
+
# copies or substantial portions of the Software.
|
|
15
|
+
#
|
|
16
|
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
19
|
+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
|
+
# SOFTWARE.
|
|
23
|
+
|
|
24
|
+
"""A library that provides a Python interface to the Ballchasing API."""
|
|
25
|
+
import sys
|
|
26
|
+
|
|
27
|
+
# In Python 3.8+, importlib.metadata is in the standard library.
|
|
28
|
+
# For older versions, a backport is available as importlib_metadata.
|
|
29
|
+
if sys.version_info >= (3, 8):
|
|
30
|
+
from importlib.metadata import version, metadata
|
|
31
|
+
else:
|
|
32
|
+
from importlib_metadata import version, metadata
|
|
33
|
+
|
|
34
|
+
try:
|
|
35
|
+
# This will read the version from the installed package's metadata
|
|
36
|
+
# (which is defined in pyproject.toml)
|
|
37
|
+
__version__ = version("python-ballchasing")
|
|
38
|
+
|
|
39
|
+
# You can also get other metadata in a similar way
|
|
40
|
+
pkg_metadata = metadata("python-ballchasing")
|
|
41
|
+
__author__ = pkg_metadata.get("Author-Email")
|
|
42
|
+
__description__ = pkg_metadata.get("Summary")
|
|
43
|
+
except Exception:
|
|
44
|
+
# If the package is not installed (e.g., when running in a development
|
|
45
|
+
# environment without an editable install), you can fall back to defaults.
|
|
46
|
+
__version__ = "0.0.0-dev"
|
|
47
|
+
__description__ = 'A Python wrapper around the Ballchasing API'
|
|
48
|
+
__author__ = 'Rolv-Arild Braaten <rolv_arild@hotmail.com>'
|
|
49
|
+
|
|
50
|
+
# Import the main classes and constants to make them easily accessible to users.
|
|
51
|
+
from .api import BallchasingApi
|
|
52
|
+
|
|
53
|
+
Api = BallchasingApi # For importing like `import ballchasing; api = ballchasing.Api`
|
|
54
|
+
|
|
55
|
+
from .constants import (
|
|
56
|
+
Playlist,
|
|
57
|
+
Rank,
|
|
58
|
+
Season,
|
|
59
|
+
MatchResult,
|
|
60
|
+
ReplaySortBy,
|
|
61
|
+
GroupSortBy,
|
|
62
|
+
SortDir,
|
|
63
|
+
Visibility,
|
|
64
|
+
PlayerIdentification,
|
|
65
|
+
TeamIdentification,
|
|
66
|
+
Map
|
|
67
|
+
)
|