python-epo-ops-client 4.0.0__tar.gz → 4.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-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/CHANGELOG.md +14 -1
- python-epo-ops-client-4.0.0/LICENSE.txt → python_epo_ops_client-4.2.0/LICENSE +0 -25
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/MANIFEST.in +2 -2
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/Makefile +22 -21
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/PKG-INFO +80 -143
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/README.md +38 -13
- python-epo-ops-client-4.0.0/AUTHORS.md → python_epo_ops_client-4.2.0/docs/authors.md +12 -3
- python_epo_ops_client-4.2.0/docs/backlog.md +35 -0
- python_epo_ops_client-4.2.0/docs/contributing.md +87 -0
- python_epo_ops_client-4.2.0/docs/release.md +19 -0
- python_epo_ops_client-4.2.0/docs/sandbox.md +89 -0
- python_epo_ops_client-4.2.0/epo_ops/__version__.py +6 -0
- python_epo_ops_client-4.2.0/epo_ops/api.py +470 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/cache/dogpile/dogpile.py +5 -2
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/cache/dogpile/helpers.py +1 -1
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/throttle/storages/sqlite.py +23 -8
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/models.py +10 -5
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/utils.py +3 -1
- python_epo_ops_client-4.2.0/pyproject.toml +111 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/python_epo_ops_client.egg-info/PKG-INFO +80 -143
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/python_epo_ops_client.egg-info/SOURCES.txt +12 -7
- python_epo_ops_client-4.2.0/python_epo_ops_client.egg-info/requires.txt +21 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/setup.cfg +0 -3
- python_epo_ops_client-4.2.0/setup.py +78 -0
- python_epo_ops_client-4.2.0/tests/test_api.py +120 -0
- python_epo_ops_client-4.2.0/tests/test_models.py +87 -0
- python_epo_ops_client-4.2.0/tests/test_ops_quota.py +69 -0
- python_epo_ops_client-4.2.0/tests/test_utils.py +23 -0
- python-epo-ops-client-4.0.0/CONTRIBUTING.md +0 -138
- python-epo-ops-client-4.0.0/TODOS.md +0 -23
- python-epo-ops-client-4.0.0/__version__.py +0 -1
- python-epo-ops-client-4.0.0/epo_ops/__version__.py +0 -1
- python-epo-ops-client-4.0.0/epo_ops/api.py +0 -242
- python-epo-ops-client-4.0.0/python_epo_ops_client.egg-info/requires.txt +0 -3
- python-epo-ops-client-4.0.0/setup.py +0 -63
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/__init__.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/exceptions.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/__init__.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/cache/__init__.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/cache/dogpile/__init__.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/middleware.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/throttle/__init__.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/throttle/storages/__init__.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/throttle/storages/storage.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/throttle/throttler.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/epo_ops/middlewares/throttle/utils.py +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/python_epo_ops_client.egg-info/dependency_links.txt +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/python_epo_ops_client.egg-info/not-zip-safe +0 -0
- {python-epo-ops-client-4.0.0 → python_epo_ops_client-4.2.0}/python_epo_ops_client.egg-info/top_level.txt +0 -0
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 4.2.0 (2025-07-26)
|
|
4
|
+
|
|
5
|
+
- Added support for the "legal" service endpoint, providing legal status
|
|
6
|
+
information for patents as documented in chapter 3.5 of the OPS v3.2
|
|
7
|
+
documentation. Thanks, @MartiONE.
|
|
8
|
+
|
|
9
|
+
## 4.1.0 (2024-01-25)
|
|
10
|
+
|
|
11
|
+
- Configure HTTP client to use a network timeout of 10 seconds
|
|
12
|
+
- Verify support for Python 3.10, 3.11, and 3.12
|
|
13
|
+
- Project: Use `versioningit` for versioning
|
|
14
|
+
- Tests: Remove dependency on Apiary Mock Server API
|
|
15
|
+
|
|
3
16
|
## 4.0.0 (2021-09-19)
|
|
4
17
|
|
|
5
18
|
- Upgrade dependencies
|
|
@@ -17,7 +30,7 @@
|
|
|
17
30
|
## 3.1.1 (2019-10-28)
|
|
18
31
|
|
|
19
32
|
- GET instead of POST for family services, thanks to [amotl][]. See
|
|
20
|
-
[#33](https://github.com/
|
|
33
|
+
[#33](https://github.com/ip-tools/python-epo-ops-client/issues/33) for more
|
|
21
34
|
info.
|
|
22
35
|
|
|
23
36
|
## 3.1.0 (2019-10-27)
|
|
@@ -174,28 +174,3 @@
|
|
|
174
174
|
of your accepting any such warranty or additional liability.
|
|
175
175
|
|
|
176
176
|
END OF TERMS AND CONDITIONS
|
|
177
|
-
|
|
178
|
-
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
-
|
|
180
|
-
To apply the Apache License to your work, attach the following
|
|
181
|
-
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
-
replaced with your own identifying information. (Don't include
|
|
183
|
-
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
-
comment syntax for the file format. We also recommend that a
|
|
185
|
-
file or class name and description of purpose be included on the
|
|
186
|
-
same "printed page" as the copyright notice for easier
|
|
187
|
-
identification within third-party archives.
|
|
188
|
-
|
|
189
|
-
Copyright [yyyy] [name of copyright owner]
|
|
190
|
-
|
|
191
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
-
you may not use this file except in compliance with the License.
|
|
193
|
-
You may obtain a copy of the License at
|
|
194
|
-
|
|
195
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
-
|
|
197
|
-
Unless required by applicable law or agreed to in writing, software
|
|
198
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
-
See the License for the specific language governing permissions and
|
|
201
|
-
limitations under the License.
|
|
@@ -15,53 +15,54 @@ help: ## Display this help message
|
|
|
15
15
|
@echo "Please use \`make <target>' where <target> is one of the following:"
|
|
16
16
|
@perl -nle'print $& if m{^[\.a-zA-Z_-]+:.*?## .*$$}' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m %-25s\033[0m %s\n", $$1, $$2}'
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
pip-compile: ## Update compiled requirement files
|
|
22
|
-
bin/pip-compile.sh
|
|
18
|
+
install-develop: ## Install project into sandbox.
|
|
19
|
+
pip install --use-pep517 --prefer-binary --editable=.[develop,docs,test]
|
|
23
20
|
|
|
24
21
|
clean: clean-build clean-pyc
|
|
25
22
|
|
|
26
23
|
clean-build:
|
|
27
24
|
rm -fr build/
|
|
28
25
|
rm -fr dist/
|
|
29
|
-
rm -fr *.egg-info
|
|
30
26
|
|
|
31
27
|
clean-pyc:
|
|
32
28
|
find . -name '*.pyc' -exec rm -f {} +
|
|
33
29
|
find . -name '*.pyo' -exec rm -f {} +
|
|
34
30
|
find . -name '*~' -exec rm -f {} +
|
|
35
31
|
|
|
36
|
-
|
|
37
|
-
|
|
32
|
+
check: lint test ## Run linter and software tests
|
|
33
|
+
check-ci: lint test-ci ## Run linter and software tests on CI
|
|
34
|
+
|
|
35
|
+
lint: ## lint the project
|
|
36
|
+
ruff check .
|
|
37
|
+
ruff format --check .
|
|
38
|
+
|
|
39
|
+
format: ## Run code formatting
|
|
40
|
+
ruff format .
|
|
41
|
+
# Configure Ruff not to auto-fix (remove!):
|
|
42
|
+
# Ignore unused imports (F401), unused variables (F841), `print` statements (T201), and commented-out code (ERA001).
|
|
43
|
+
ruff check --fix --ignore=ERA --ignore=F401 --ignore=F841 --ignore=T20 --ignore=ERA001 .
|
|
38
44
|
|
|
39
45
|
test: clean ## Run tests with virtualenv Python
|
|
40
|
-
|
|
46
|
+
pytest --lf
|
|
41
47
|
|
|
42
48
|
test-ci: clean ## Run tests in CI environment with virtualenv Python
|
|
43
|
-
|
|
49
|
+
pytest
|
|
44
50
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
coverage: clean ## Check code coverage locally
|
|
49
|
-
py.test -s -v --cov-report html --cov-report term --cov epo_ops tests
|
|
51
|
+
coverage: clean test-ci ## Check code coverage locally
|
|
52
|
+
coverage html
|
|
50
53
|
open htmlcov/index.html
|
|
51
54
|
|
|
52
55
|
release: clean # Package and upload a release to PyPI
|
|
53
|
-
python
|
|
54
|
-
python setup.py bdist_wheel
|
|
56
|
+
python -m build
|
|
55
57
|
twine check dist/*
|
|
56
58
|
twine upload --repository pypi dist/*
|
|
57
|
-
open https://pypi.
|
|
59
|
+
open https://pypi.org/project/python-epo-ops-client/
|
|
58
60
|
|
|
59
61
|
release-test: clean # Package and upload a release to testpypi
|
|
60
|
-
python
|
|
61
|
-
python setup.py bdist_wheel
|
|
62
|
+
python -m build
|
|
62
63
|
twine check dist/*
|
|
63
64
|
twine upload --repository testpypi dist/*
|
|
64
|
-
open https://
|
|
65
|
+
open https://test.pypi.org/project/python-epo-ops-client/
|
|
65
66
|
|
|
66
67
|
sdist: clean
|
|
67
68
|
python setup.py sdist
|
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: python-epo-ops-client
|
|
3
|
-
Version: 4.
|
|
4
|
-
Summary: Python
|
|
5
|
-
Home-page: https://github.com/
|
|
3
|
+
Version: 4.2.0
|
|
4
|
+
Summary: Python client for EPO OPS, the European Patent Office's Open Patent Services API.
|
|
5
|
+
Home-page: https://github.com/ip-tools/python-epo-ops-client
|
|
6
|
+
Download-URL: https://pypi.org/project/python-epo-ops-client/#files
|
|
6
7
|
Author: George Song
|
|
7
8
|
Author-email: george@monozuku.com
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
Maintainer: Andreas Motl
|
|
10
|
+
Maintainer-email: andreas.motl@ip-tools.org
|
|
11
|
+
Keywords: ops,epo,epo-ops,patent-data,patent-office,patent-data-api,european patent office,open patent services
|
|
11
12
|
Classifier: Development Status :: 5 - Production/Stable
|
|
12
13
|
Classifier: Intended Audience :: Developers
|
|
13
14
|
Classifier: Natural Language :: English
|
|
@@ -17,32 +18,89 @@ Classifier: Programming Language :: Python :: 3.6
|
|
|
17
18
|
Classifier: Programming Language :: Python :: 3.7
|
|
18
19
|
Classifier: Programming Language :: Python :: 3.8
|
|
19
20
|
Classifier: Programming Language :: Python :: 3.9
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
23
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
24
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
20
25
|
Classifier: Topic :: Software Development :: Libraries
|
|
21
26
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
22
27
|
Description-Content-Type: text/markdown
|
|
23
|
-
License-File: LICENSE
|
|
24
|
-
|
|
28
|
+
License-File: LICENSE
|
|
29
|
+
Requires-Dist: dogpile.cache<1.5
|
|
30
|
+
Requires-Dist: importlib-metadata; python_version < "3.8"
|
|
31
|
+
Requires-Dist: python-dateutil<2.10
|
|
32
|
+
Requires-Dist: requests<3,>=2.27
|
|
33
|
+
Requires-Dist: six<2
|
|
34
|
+
Provides-Extra: develop
|
|
35
|
+
Requires-Dist: ruff<0.13; python_version >= "3.7" and extra == "develop"
|
|
36
|
+
Requires-Dist: twine<7; extra == "develop"
|
|
37
|
+
Requires-Dist: wheel<1; extra == "develop"
|
|
38
|
+
Provides-Extra: test
|
|
39
|
+
Requires-Dist: pytest<9; extra == "test"
|
|
40
|
+
Requires-Dist: pytest-cache<2; extra == "test"
|
|
41
|
+
Requires-Dist: pytest-cov<6.3; extra == "test"
|
|
42
|
+
Requires-Dist: python-dotenv<1.2; extra == "test"
|
|
43
|
+
Requires-Dist: responses<0.26; extra == "test"
|
|
44
|
+
Dynamic: author
|
|
45
|
+
Dynamic: author-email
|
|
46
|
+
Dynamic: classifier
|
|
47
|
+
Dynamic: description
|
|
48
|
+
Dynamic: description-content-type
|
|
49
|
+
Dynamic: download-url
|
|
50
|
+
Dynamic: home-page
|
|
51
|
+
Dynamic: keywords
|
|
52
|
+
Dynamic: license-file
|
|
53
|
+
Dynamic: maintainer
|
|
54
|
+
Dynamic: maintainer-email
|
|
55
|
+
Dynamic: provides-extra
|
|
56
|
+
Dynamic: requires-dist
|
|
57
|
+
Dynamic: summary
|
|
25
58
|
|
|
26
59
|
# python-epo-ops-client
|
|
27
60
|
|
|
28
61
|
[](https://pypi.org/project/python-epo-ops-client/)
|
|
29
62
|
[](https://pypi.org/project/python-epo-ops-client/)
|
|
30
|
-
[](https://github.com/ip-tools/python-epo-ops-client/actions/workflows/main.yml)
|
|
64
|
+
[](https://codecov.io/gh/ip-tools/python-epo-ops-client)
|
|
32
65
|
|
|
33
66
|
python-epo-ops-client is an [Apache2 licensed][apache license] client library
|
|
34
67
|
for accessing the [European Patent Office][epo]'s ("EPO") [Open Patent
|
|
35
|
-
Services][ops] ("OPS")
|
|
68
|
+
Services][ops] ("OPS") v3.2 (based on [v1.3.16 of the reference guide][ops guide]).
|
|
36
69
|
|
|
37
70
|
```python
|
|
38
71
|
import epo_ops
|
|
39
72
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
73
|
+
# Instantiate client.
|
|
74
|
+
client = epo_ops.Client(key="abc", secret="xyz")
|
|
75
|
+
|
|
76
|
+
# Retrieve bibliography data.
|
|
77
|
+
response = client.published_data(
|
|
78
|
+
|
|
79
|
+
# publication, application, priority
|
|
80
|
+
reference_type="publication",
|
|
81
|
+
|
|
82
|
+
# docdb, epodoc
|
|
83
|
+
input=epo_ops.models.Docdb("1000000", "EP", "A1"),
|
|
84
|
+
|
|
85
|
+
# optional, defaults to biblio in case of published_data
|
|
86
|
+
endpoint="biblio",
|
|
87
|
+
|
|
88
|
+
# optional, list of constituents
|
|
89
|
+
constituents=[],
|
|
90
|
+
)
|
|
91
|
+
|
|
92
|
+
# Retrieve description.
|
|
93
|
+
response = client.published_data(
|
|
94
|
+
reference_type="publication",
|
|
95
|
+
input=epo_ops.models.Docdb("1000000", "EP", "A1"),
|
|
96
|
+
endpoint="description",
|
|
97
|
+
)
|
|
98
|
+
|
|
99
|
+
# Retrieve claims.
|
|
100
|
+
response = client.published_data(
|
|
101
|
+
reference_type="publication",
|
|
102
|
+
input=epo_ops.models.Docdb("1000000", "EP", "A1"),
|
|
103
|
+
endpoint="claims",
|
|
46
104
|
)
|
|
47
105
|
```
|
|
48
106
|
|
|
@@ -89,12 +147,12 @@ Currently the Client knows how to issue request for the following services:
|
|
|
89
147
|
| ----------------------------------------------------------------------------- | --------------------- | --------- |
|
|
90
148
|
| `family(reference_type, input, endpoint=None, constituents=None)` | family | inpadoc |
|
|
91
149
|
| `image(path, range=1, extension='tiff')` | published-data/images | images |
|
|
150
|
+
| `legal(reference_type, input)` | legal | other |
|
|
92
151
|
| `number(reference_type, input, output_format)` | number-service | other |
|
|
93
152
|
| `published_data(reference_type, input, endpoint='biblio', constituents=None)` | published-data | retrieval |
|
|
94
153
|
| `published_data_search(cql, range_begin=1, range_end=25, constituents=None)` | published-data/search | search |
|
|
95
154
|
| `register(reference_type, input, constituents=['biblio'])` | register | other |
|
|
96
155
|
| `register_search(cql, range_begin=1, range_end=25)` | register/search | other |
|
|
97
|
-
| `register_search(cql, range_begin=1, range_end=25)` | register/search | other |
|
|
98
156
|
|
|
99
157
|
Bulk operations can be achieved by passing a list of valid models to the
|
|
100
158
|
published_data input field.
|
|
@@ -187,130 +245,9 @@ details.
|
|
|
187
245
|
|
|
188
246
|
[apache license]: http://www.apache.org/licenses/LICENSE-2.0
|
|
189
247
|
[developer's area]: https://developers.epo.org/ops-v3-2/apis
|
|
190
|
-
[dogpile.cache region]:
|
|
191
|
-
[dogpile.cache]: https://
|
|
248
|
+
[dogpile.cache region]: https://dogpilecache.sqlalchemy.org/en/latest/api.html#module-dogpile.cache.region
|
|
249
|
+
[dogpile.cache]: https://github.com/sqlalchemy/dogpile.cache
|
|
192
250
|
[epo]: http://epo.org
|
|
193
|
-
[ops guide]:
|
|
251
|
+
[ops guide]: https://link.epo.org/web/ops_v3.2_documentation_-_version_1.3.19_en.pdf
|
|
194
252
|
[ops]: https://www.epo.org/searching-for-patents/data/web-services/ops.html
|
|
195
253
|
[requests.response]: http://requests.readthedocs.org/en/latest/user/advanced/#request-and-response-objects
|
|
196
|
-
|
|
197
|
-
# Change Log
|
|
198
|
-
|
|
199
|
-
## 4.0.0 (2021-09-19)
|
|
200
|
-
|
|
201
|
-
- Upgrade dependencies
|
|
202
|
-
- Drop support for Python 2.7 and Python 3.5
|
|
203
|
-
- Add support for Python 3.9
|
|
204
|
-
|
|
205
|
-
## 3.1.3 (2020-09-23)
|
|
206
|
-
|
|
207
|
-
- Upgrade dependencies
|
|
208
|
-
|
|
209
|
-
## 3.1.2 (2020-07-04)
|
|
210
|
-
|
|
211
|
-
- Upgrade dependencies
|
|
212
|
-
|
|
213
|
-
## 3.1.1 (2019-10-28)
|
|
214
|
-
|
|
215
|
-
- GET instead of POST for family services, thanks to [amotl][]. See
|
|
216
|
-
[#33](https://github.com/gsong/python-epo-ops-client/issues/33) for more
|
|
217
|
-
info.
|
|
218
|
-
|
|
219
|
-
## 3.1.0 (2019-10-27)
|
|
220
|
-
|
|
221
|
-
- Add support for bulk retrieval, thanks to [mmath][]
|
|
222
|
-
|
|
223
|
-
## 3.0.0 (2019-10-27)
|
|
224
|
-
|
|
225
|
-
- Drop support for PyPy, Python 3.4 (probably still works)
|
|
226
|
-
- Add support for Python 3.7, 3.8
|
|
227
|
-
- Invalid and expired tokens are now treated the same, since OPS doesn't
|
|
228
|
-
distinguish between the two use cases.
|
|
229
|
-
|
|
230
|
-
## 2.3.2 (2018-01-15)
|
|
231
|
-
|
|
232
|
-
- Bug fix: Cache 4xx results as well, thanks to [amotl][]
|
|
233
|
-
|
|
234
|
-
## 2.3.1 (2017-11-10)
|
|
235
|
-
|
|
236
|
-
- Bug fix: explicitly declare content-type during request
|
|
237
|
-
|
|
238
|
-
## 2.3.0 (2017-10-22)
|
|
239
|
-
|
|
240
|
-
- Drop support for Python 2.6
|
|
241
|
-
- Officially support Python 3.6
|
|
242
|
-
- Update to latest dependencies
|
|
243
|
-
- Add image retrieval service, thanks to [rfaga][]
|
|
244
|
-
|
|
245
|
-
## 2.2.0 (2017-03-30)
|
|
246
|
-
|
|
247
|
-
- EPO OPS v3.2 compatibility, thanks to [eltermann][]
|
|
248
|
-
|
|
249
|
-
## 2.1.0 (2016-02-21)
|
|
250
|
-
|
|
251
|
-
- Add number service, thanks to [eltermann][]
|
|
252
|
-
|
|
253
|
-
## 2.0.0 (2015-12-11)
|
|
254
|
-
|
|
255
|
-
- Dropping support for Python 3.3 (although it probably still works).
|
|
256
|
-
- Update to latest dependencies, no new features.
|
|
257
|
-
|
|
258
|
-
## 1.0.0 (2015-09-20)
|
|
259
|
-
|
|
260
|
-
- Allow no middleware to be specified
|
|
261
|
-
- Minor tweaks to development infrastructure, no new features.
|
|
262
|
-
- This has been working for a while now, let's call it 1.0!
|
|
263
|
-
|
|
264
|
-
## 0.1.9 (2015-07-21)
|
|
265
|
-
|
|
266
|
-
- No new features, just updating third party dependencies
|
|
267
|
-
|
|
268
|
-
## 0.1.8 (2015-01-24)
|
|
269
|
-
|
|
270
|
-
- No new features, just updating third party dependencies
|
|
271
|
-
|
|
272
|
-
## 0.1.7 (2015-01-24)
|
|
273
|
-
|
|
274
|
-
- Created default Dogpile DBM path if it doesn't exist
|
|
275
|
-
|
|
276
|
-
## 0.1.6 (2014-12-12)
|
|
277
|
-
|
|
278
|
-
- Fixed bug with how service URL is constructed
|
|
279
|
-
|
|
280
|
-
## 0.1.5 (2014-10-17)
|
|
281
|
-
|
|
282
|
-
- Added support for register retrieval and search
|
|
283
|
-
|
|
284
|
-
## 0.1.4 (2014-10-10)
|
|
285
|
-
|
|
286
|
-
- Verified PyPy3 support
|
|
287
|
-
- Updated various dependency pacakges
|
|
288
|
-
|
|
289
|
-
## 0.1.3 (2014-05-21)
|
|
290
|
-
|
|
291
|
-
- Python 3.4 compatibility
|
|
292
|
-
- Updated `requests` dependency to 2.3.0
|
|
293
|
-
|
|
294
|
-
## 0.1.2 (2014-03-04)
|
|
295
|
-
|
|
296
|
-
- Python 2.6 and 3.3 compatibility
|
|
297
|
-
|
|
298
|
-
## 0.1.1 (2014-03-01)
|
|
299
|
-
|
|
300
|
-
- Allow configuration of which HTTP responses (based on status code) to cache
|
|
301
|
-
|
|
302
|
-
## 0.1.0 (2014-02-20)
|
|
303
|
-
|
|
304
|
-
- Introduced dogpile.cache for caching http200 resopnses
|
|
305
|
-
- Introduced the concept of middleware
|
|
306
|
-
|
|
307
|
-
## 0.0.1 (2014-01-21)
|
|
308
|
-
|
|
309
|
-
- Initial release
|
|
310
|
-
|
|
311
|
-
[amotl]: https://github.com/amotl
|
|
312
|
-
[eltermann]: https://github.com/eltermann
|
|
313
|
-
[mmath]: https://github.com/mmath
|
|
314
|
-
[rfaga]: https://github.com/rfaga
|
|
315
|
-
|
|
316
|
-
|
|
@@ -2,22 +2,47 @@
|
|
|
2
2
|
|
|
3
3
|
[](https://pypi.org/project/python-epo-ops-client/)
|
|
4
4
|
[](https://pypi.org/project/python-epo-ops-client/)
|
|
5
|
-
[](https://github.com/ip-tools/python-epo-ops-client/actions/workflows/main.yml)
|
|
6
|
+
[](https://codecov.io/gh/ip-tools/python-epo-ops-client)
|
|
7
7
|
|
|
8
8
|
python-epo-ops-client is an [Apache2 licensed][apache license] client library
|
|
9
9
|
for accessing the [European Patent Office][epo]'s ("EPO") [Open Patent
|
|
10
|
-
Services][ops] ("OPS")
|
|
10
|
+
Services][ops] ("OPS") v3.2 (based on [v1.3.16 of the reference guide][ops guide]).
|
|
11
11
|
|
|
12
12
|
```python
|
|
13
13
|
import epo_ops
|
|
14
14
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
# Instantiate client.
|
|
16
|
+
client = epo_ops.Client(key="abc", secret="xyz")
|
|
17
|
+
|
|
18
|
+
# Retrieve bibliography data.
|
|
19
|
+
response = client.published_data(
|
|
20
|
+
|
|
21
|
+
# publication, application, priority
|
|
22
|
+
reference_type="publication",
|
|
23
|
+
|
|
24
|
+
# docdb, epodoc
|
|
25
|
+
input=epo_ops.models.Docdb("1000000", "EP", "A1"),
|
|
26
|
+
|
|
27
|
+
# optional, defaults to biblio in case of published_data
|
|
28
|
+
endpoint="biblio",
|
|
29
|
+
|
|
30
|
+
# optional, list of constituents
|
|
31
|
+
constituents=[],
|
|
32
|
+
)
|
|
33
|
+
|
|
34
|
+
# Retrieve description.
|
|
35
|
+
response = client.published_data(
|
|
36
|
+
reference_type="publication",
|
|
37
|
+
input=epo_ops.models.Docdb("1000000", "EP", "A1"),
|
|
38
|
+
endpoint="description",
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
# Retrieve claims.
|
|
42
|
+
response = client.published_data(
|
|
43
|
+
reference_type="publication",
|
|
44
|
+
input=epo_ops.models.Docdb("1000000", "EP", "A1"),
|
|
45
|
+
endpoint="claims",
|
|
21
46
|
)
|
|
22
47
|
```
|
|
23
48
|
|
|
@@ -64,12 +89,12 @@ Currently the Client knows how to issue request for the following services:
|
|
|
64
89
|
| ----------------------------------------------------------------------------- | --------------------- | --------- |
|
|
65
90
|
| `family(reference_type, input, endpoint=None, constituents=None)` | family | inpadoc |
|
|
66
91
|
| `image(path, range=1, extension='tiff')` | published-data/images | images |
|
|
92
|
+
| `legal(reference_type, input)` | legal | other |
|
|
67
93
|
| `number(reference_type, input, output_format)` | number-service | other |
|
|
68
94
|
| `published_data(reference_type, input, endpoint='biblio', constituents=None)` | published-data | retrieval |
|
|
69
95
|
| `published_data_search(cql, range_begin=1, range_end=25, constituents=None)` | published-data/search | search |
|
|
70
96
|
| `register(reference_type, input, constituents=['biblio'])` | register | other |
|
|
71
97
|
| `register_search(cql, range_begin=1, range_end=25)` | register/search | other |
|
|
72
|
-
| `register_search(cql, range_begin=1, range_end=25)` | register/search | other |
|
|
73
98
|
|
|
74
99
|
Bulk operations can be achieved by passing a list of valid models to the
|
|
75
100
|
published_data input field.
|
|
@@ -162,9 +187,9 @@ details.
|
|
|
162
187
|
|
|
163
188
|
[apache license]: http://www.apache.org/licenses/LICENSE-2.0
|
|
164
189
|
[developer's area]: https://developers.epo.org/ops-v3-2/apis
|
|
165
|
-
[dogpile.cache region]:
|
|
166
|
-
[dogpile.cache]: https://
|
|
190
|
+
[dogpile.cache region]: https://dogpilecache.sqlalchemy.org/en/latest/api.html#module-dogpile.cache.region
|
|
191
|
+
[dogpile.cache]: https://github.com/sqlalchemy/dogpile.cache
|
|
167
192
|
[epo]: http://epo.org
|
|
168
|
-
[ops guide]:
|
|
193
|
+
[ops guide]: https://link.epo.org/web/ops_v3.2_documentation_-_version_1.3.19_en.pdf
|
|
169
194
|
[ops]: https://www.epo.org/searching-for-patents/data/web-services/ops.html
|
|
170
195
|
[requests.response]: http://requests.readthedocs.org/en/latest/user/advanced/#request-and-response-objects
|
|
@@ -1,14 +1,23 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Authors
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
The following people contributed to the software in one way or another,
|
|
4
|
+
thank you so much. The list is alphabetically sorted.
|
|
5
|
+
|
|
6
|
+
## Development Leads
|
|
4
7
|
|
|
5
8
|
- [George Song](https://github.com/gsong)
|
|
6
9
|
|
|
7
|
-
##
|
|
10
|
+
## Maintainers
|
|
8
11
|
|
|
9
12
|
- [Andreas Motl](https://github.com/amotl)
|
|
13
|
+
|
|
14
|
+
## Contributors
|
|
15
|
+
|
|
16
|
+
- [Alexander Meinhardt Scheurer](https://github.com/BeneCollyridam)
|
|
10
17
|
- [Daniel Blasco](https://github.com/dablak)
|
|
18
|
+
- [fe60](https://github.com/fe60)
|
|
11
19
|
- [Felipe Eltermann](https://github.com/eltermann)
|
|
20
|
+
- [Geoffrey Cline](https://github.com/geoffcline)
|
|
12
21
|
- [Hiro Kobashi](https://github.com/kobaski)
|
|
13
22
|
- [Mike Matheson](https://github.com/mmath)
|
|
14
23
|
- [Roberto Faga](https://github.com/rfaga)
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Backlog
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## Iteration +1
|
|
5
|
+
|
|
6
|
+
- Improve and clean up README
|
|
7
|
+
- Set up project documentation on Read the Docs
|
|
8
|
+
- Switch to `pyproject.toml`
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
## Iteration +2
|
|
12
|
+
|
|
13
|
+
This is the content of the original `TODOS.md` file.
|
|
14
|
+
|
|
15
|
+
- Feature: Should the non-standard oAuth be coded as a requests plug-in?
|
|
16
|
+
- Dogpile caching
|
|
17
|
+
- Generate the key based on a SortedDict of some kind to make sure the exact
|
|
18
|
+
same request with different argument order are still a hit
|
|
19
|
+
- Additional services
|
|
20
|
+
- Legal service
|
|
21
|
+
- Makefile: Comma in `echo` statements?
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
## Done
|
|
25
|
+
|
|
26
|
+
- Use new organization name `ip-tools`
|
|
27
|
+
- CI: Add GHA recipe, dissolve Travis configuration
|
|
28
|
+
- Dissolve `requirements` files, and inline them into `setup.py`
|
|
29
|
+
- Add support for Python 3.10 and 3.11
|
|
30
|
+
- Use `ruff` linter, dissolve `flake8` and `isort`
|
|
31
|
+
- Use `versioningit` for versioning, dissolve `bumpversion`
|
|
32
|
+
- Replace Apiary Mock server
|
|
33
|
+
https://github.com/ip-tools/python-epo-ops-client/issues/65
|
|
34
|
+
- Testing: Replace Apiary tests with monkeypatch? Or
|
|
35
|
+
<https://pypi.python.org/pypi/pytest-localserver>.
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
Contributions are welcome, and they are greatly appreciated. Every bit
|
|
4
|
+
helps, and credit will always be given. You can contribute in many ways.
|
|
5
|
+
|
|
6
|
+
## Types of Contributions
|
|
7
|
+
|
|
8
|
+
### Report Bugs
|
|
9
|
+
|
|
10
|
+
Report bugs at <https://github.com/ip-tools/python-epo-ops-client/issues>.
|
|
11
|
+
|
|
12
|
+
If you are reporting a bug, please include:
|
|
13
|
+
|
|
14
|
+
- Your operating system name and version.
|
|
15
|
+
- Any details about your local setup that might be helpful in troubleshooting.
|
|
16
|
+
- Detailed steps to reproduce the bug.
|
|
17
|
+
|
|
18
|
+
### Fix Bugs
|
|
19
|
+
|
|
20
|
+
Look through the GitHub issues for bugs. Anything tagged with "bug" is open to
|
|
21
|
+
whoever wants to fix it.
|
|
22
|
+
|
|
23
|
+
### Implement Features
|
|
24
|
+
|
|
25
|
+
We are tracking all sorts of tasks within the [backlog](backlog.md) file and
|
|
26
|
+
as issues on GitHub. Just pick one, submit a corresponding patch, or start
|
|
27
|
+
a discussion around it. Anything tagged with "feature" is open to whoever wants
|
|
28
|
+
to implement it.
|
|
29
|
+
|
|
30
|
+
### Write Documentation
|
|
31
|
+
|
|
32
|
+
python-epo-ops-client could always use more documentation, whether as part of
|
|
33
|
+
the official python-epo-ops-client docs, in docstrings, or even on the web in
|
|
34
|
+
blog posts, articles, and such.
|
|
35
|
+
|
|
36
|
+
### Submit Feedback
|
|
37
|
+
|
|
38
|
+
The best way to send feedback is to file an issue at
|
|
39
|
+
https://github.com/ip-tools/python-epo-ops-client/issues.
|
|
40
|
+
|
|
41
|
+
If you are proposing a feature:
|
|
42
|
+
|
|
43
|
+
- Explain in detail how it would work.
|
|
44
|
+
- Keep the scope as narrow as possible, to make it easier to implement.
|
|
45
|
+
- Remember that this is a volunteer-driven project, and that contributions are
|
|
46
|
+
welcome. 😊
|
|
47
|
+
|
|
48
|
+
## Get Started!
|
|
49
|
+
|
|
50
|
+
Ready to contribute? Here's how to set up `python-epo-ops-client` for local
|
|
51
|
+
development. Before going into the forking process, you should first [install
|
|
52
|
+
a development sandbox](sandbox.md).
|
|
53
|
+
|
|
54
|
+
1. Fork the `python-epo-ops-client` repository on GitHub and clone your fork.
|
|
55
|
+
```shell
|
|
56
|
+
git clone git@github.com:[your_name_here]/python-epo-ops-client.git
|
|
57
|
+
cd python-epo-ops-client/
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
4. Create a branch for local development:
|
|
61
|
+
```shell
|
|
62
|
+
git switch -c <branchname>
|
|
63
|
+
```
|
|
64
|
+
Now, make your changes within your working tree.
|
|
65
|
+
|
|
66
|
+
5. After making changes to the code base, you may want to check that your
|
|
67
|
+
changes pass test and linting procedures. For that purpose, run
|
|
68
|
+
`make check`.
|
|
69
|
+
|
|
70
|
+
6. Commit your changes and push your branch to GitHub.
|
|
71
|
+
|
|
72
|
+
```shell
|
|
73
|
+
git add .
|
|
74
|
+
git commit -m "A detailed description of your changes."
|
|
75
|
+
git push origin <branchname>
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
7. Submit a pull request through the GitHub website.
|
|
79
|
+
|
|
80
|
+
## Pull Request Guidelines
|
|
81
|
+
|
|
82
|
+
Before you submit a pull request, check that it meets these guidelines:
|
|
83
|
+
|
|
84
|
+
1. The pull request should include tests.
|
|
85
|
+
2. If the pull request adds functionality, the docs should be updated. Put your
|
|
86
|
+
new functionality into a function with a docstring, and add the feature to
|
|
87
|
+
the list in README.md.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Release
|
|
2
|
+
|
|
3
|
+
Building Python packages and publishing to PyPI is automated
|
|
4
|
+
using the GHA workflow `release-pypi.yml`.
|
|
5
|
+
|
|
6
|
+
To release the package, exercise those steps:
|
|
7
|
+
|
|
8
|
+
- Edit `CHANGELOG.md`, designating a new version. Commit the file
|
|
9
|
+
using a commit message like `Release 4.1.1`.
|
|
10
|
+
|
|
11
|
+
- Create a tag using the new version, including a `v` prefix, e.g.
|
|
12
|
+
```shell
|
|
13
|
+
git tag v4.1.1
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
- Push to remote.
|
|
17
|
+
```shell
|
|
18
|
+
git push --follow-tags
|
|
19
|
+
```
|