scrapely-client-python 1.0.2__tar.gz → 1.0.6__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.
- scrapely_client_python-1.0.6/CHANGELOG.md +30 -0
- scrapely_client_python-1.0.6/NOTICE +7 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/PKG-INFO +10 -9
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/README.md +2 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/pyproject.toml +15 -15
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/pyproject.toml.orig +15 -18
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/__init__.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_charging.py +3 -4
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_client_registry.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_consts.py +3 -1
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_docs.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_literals.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_logging.py +3 -1
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_models.py +39 -43
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_pagination.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/__init__.py +6 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/_resource_client.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/actor.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/actor_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/actor_env_var.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/actor_env_var_collection.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/actor_version.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/actor_version_collection.py +2 -0
- scrapely_client_python-1.0.6/src/scrapely_client/_resource_clients/automation.py +330 -0
- scrapely_client_python-1.0.6/src/scrapely_client/_resource_clients/automation_collection.py +169 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/build.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/build_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/dataset.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/dataset_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/key_value_store.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/key_value_store_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/log.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/request_queue.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/request_queue_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/run.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/run_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/schedule.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/schedule_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/store_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/task.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/task_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/user.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/webhook.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/webhook_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/webhook_dispatch.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_resource_clients/webhook_dispatch_collection.py +4 -2
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_scrapely_client.py +56 -26
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_status_message_watcher.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_streamed_log.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_typeddicts.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_utils/crypto.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_utils/encoding.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_utils/errors.py +3 -1
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_utils/http.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_utils/try_import.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/errors.py +5 -3
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_clients/__init__.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_clients/_base.py +7 -5
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_clients/_impit.py +6 -4
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_compressors/__init__.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_compressors/_brotli.py +3 -1
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_compressors/_gzip.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_compressors/_resolve.py +2 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/types.py +3 -1
- scrapely_client_python-1.0.2/CHANGELOG.md +0 -14
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/CONTRIBUTING.md +0 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/LICENSE +0 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_statistics.py +0 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_utils/__init__.py +0 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_utils/time.py +0 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/http_compressors/_base.py +0 -0
- {scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/py.typed +0 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
## [1.0.6] - 2026-10-20
|
|
6
|
+
|
|
7
|
+
- New Scrapely-only `client.automations()` (`list` with `actor_id`, `saved_input_id` and `search` filters, `create`) and `client.automation(id)` (`get`, `update`, `delete`, `run`, `list_runs`, `get_run`, `duplicate`) for `/v2/automations`, sync and async. They return the API's camelCase dictionaries; `update` sends fields as given, so `{'ai': None}` removes the AI step.
|
|
8
|
+
|
|
9
|
+
## [1.0.5] - 2026-10-20
|
|
10
|
+
|
|
11
|
+
- Removed `apify_margin_percentage` from `CommonActorPricingInfo` and `CurrentPricingInfo`; the API no longer returns it (models allow extra fields, so older payloads still parse).
|
|
12
|
+
|
|
13
|
+
## [1.0.4] - 2026-10-19
|
|
14
|
+
|
|
15
|
+
- The `User-Agent` header reports the installed client version. Older versions always sent `ScrapelyClient/0.0.0`.
|
|
16
|
+
|
|
17
|
+
## [1.0.3] - 2026-10-15
|
|
18
|
+
|
|
19
|
+
- The package ships the Apache-2.0 licence text and NOTICE.
|
|
20
|
+
|
|
21
|
+
## [1.0.2] - 2026-10-13
|
|
22
|
+
|
|
23
|
+
- Builds are owner-only: `build_id` on runs and metamorphs and `build` in run options are optional, since runs of someone else's Actor carry no build info. Older versions raise a validation error on those runs.
|
|
24
|
+
- `actor().update(default_non_owner_build=...)` sets the User Build (the build everyone else runs); `''` clears it.
|
|
25
|
+
|
|
26
|
+
## [1.0.0] - 2026-09-08
|
|
27
|
+
|
|
28
|
+
Initial release.
|
|
29
|
+
|
|
30
|
+
- Python client for the Scrapely API: Actors, runs, datasets, key-value stores, request queues, task management, and webhooks
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
scrapely-client-python
|
|
2
|
+
Copyright (c) 2025-2026 TeraShift GmbH (Scrape.ly)
|
|
3
|
+
|
|
4
|
+
Derived from apify-client-python (https://github.com/apify/apify-client-python),
|
|
5
|
+
Copyright Apify Technologies s.r.o., licensed under the Apache License,
|
|
6
|
+
Version 2.0 (see LICENSE). Modified by TeraShift GmbH; modified files carry
|
|
7
|
+
a notice at the top of the file.
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scrapely-client-python
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.6
|
|
4
4
|
Summary: Scrapely API client for Python
|
|
5
5
|
Keywords: scrapely,api,client,automation,crawling,scraping
|
|
6
|
-
Author:
|
|
6
|
+
Author: TeraShift GmbH (Scrape.ly)
|
|
7
7
|
License-Expression: Apache-2.0
|
|
8
8
|
License-File: LICENSE
|
|
9
|
+
License-File: NOTICE
|
|
9
10
|
Classifier: Development Status :: 5 - Production/Stable
|
|
10
11
|
Classifier: Environment :: Console
|
|
11
12
|
Classifier: Intended Audience :: Developers
|
|
@@ -22,11 +23,11 @@ Requires-Dist: pydantic[email]>=2.11.0
|
|
|
22
23
|
Requires-Dist: typing-extensions>=4.6.0
|
|
23
24
|
Requires-Dist: brotli>=1.0.9 ; extra == 'brotli'
|
|
24
25
|
Requires-Python: >=3.11
|
|
25
|
-
Project-URL: Homepage, https://
|
|
26
|
-
Project-URL: Changelog, https://github.com/
|
|
27
|
-
Project-URL: Documentation, https://
|
|
28
|
-
Project-URL: Issue Tracker, https://github.com/
|
|
29
|
-
Project-URL: Source Code, https://github.com/
|
|
26
|
+
Project-URL: Homepage, https://scrape.ly
|
|
27
|
+
Project-URL: Changelog, https://github.com/scrapely-app/scrapely-client-python/blob/main/CHANGELOG.md
|
|
28
|
+
Project-URL: Documentation, https://scrape.ly/docs/client-python
|
|
29
|
+
Project-URL: Issue Tracker, https://github.com/scrapely-app/scrapely-client-python/issues
|
|
30
|
+
Project-URL: Source Code, https://github.com/scrapely-app/scrapely-client-python
|
|
30
31
|
Provides-Extra: brotli
|
|
31
32
|
Description-Content-Type: text/markdown
|
|
32
33
|
|
|
@@ -89,7 +90,7 @@ Description-Content-Type: text/markdown
|
|
|
89
90
|
|
|
90
91
|
## Quick start
|
|
91
92
|
|
|
92
|
-
You'll need a Scrapely API token — find yours in the integrations section of the Scrapely
|
|
93
|
+
You'll need a Scrapely API token — find yours in the integrations section of the Scrapely dashboard. Pass it to the client and you're ready to go.
|
|
93
94
|
|
|
94
95
|
### Synchronous client
|
|
95
96
|
|
|
@@ -241,4 +242,4 @@ uv run poe check-code # lint, type-check, unit tests, docstring check
|
|
|
241
242
|
|
|
242
243
|
## License
|
|
243
244
|
|
|
244
|
-
Released under the [Apache License 2.0](./LICENSE).
|
|
245
|
+
Released under the [Apache License 2.0](./LICENSE); see [NOTICE](./NOTICE).
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
|
|
58
58
|
## Quick start
|
|
59
59
|
|
|
60
|
-
You'll need a Scrapely API token — find yours in the integrations section of the Scrapely
|
|
60
|
+
You'll need a Scrapely API token — find yours in the integrations section of the Scrapely dashboard. Pass it to the client and you're ready to go.
|
|
61
61
|
|
|
62
62
|
### Synchronous client
|
|
63
63
|
|
|
@@ -209,4 +209,4 @@ uv run poe check-code # lint, type-check, unit tests, docstring check
|
|
|
209
209
|
|
|
210
210
|
## License
|
|
211
211
|
|
|
212
|
-
Released under the [Apache License 2.0](./LICENSE).
|
|
212
|
+
Released under the [Apache License 2.0](./LICENSE); see [NOTICE](./NOTICE).
|
|
@@ -4,10 +4,13 @@ build-backend = "uv_build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "scrapely-client-python"
|
|
7
|
-
version = "1.0.
|
|
7
|
+
version = "1.0.6"
|
|
8
8
|
description = "Scrapely API client for Python"
|
|
9
9
|
license = "Apache-2.0"
|
|
10
|
-
license-files = [
|
|
10
|
+
license-files = [
|
|
11
|
+
"LICENSE",
|
|
12
|
+
"NOTICE",
|
|
13
|
+
]
|
|
11
14
|
readme = "README.md"
|
|
12
15
|
requires-python = ">=3.11"
|
|
13
16
|
classifiers = [
|
|
@@ -38,17 +41,17 @@ dependencies = [
|
|
|
38
41
|
]
|
|
39
42
|
|
|
40
43
|
[[project.authors]]
|
|
41
|
-
name = "
|
|
44
|
+
name = "TeraShift GmbH (Scrape.ly)"
|
|
42
45
|
|
|
43
46
|
[project.optional-dependencies]
|
|
44
47
|
brotli = ["brotli>=1.0.9"]
|
|
45
48
|
|
|
46
49
|
[project.urls]
|
|
47
|
-
Homepage = "https://
|
|
48
|
-
Changelog = "https://github.com/
|
|
49
|
-
Documentation = "https://
|
|
50
|
-
"Issue Tracker" = "https://github.com/
|
|
51
|
-
"Source Code" = "https://github.com/
|
|
50
|
+
Homepage = "https://scrape.ly"
|
|
51
|
+
Changelog = "https://github.com/scrapely-app/scrapely-client-python/blob/main/CHANGELOG.md"
|
|
52
|
+
Documentation = "https://scrape.ly/docs/client-python"
|
|
53
|
+
"Issue Tracker" = "https://github.com/scrapely-app/scrapely-client-python/issues"
|
|
54
|
+
"Source Code" = "https://github.com/scrapely-app/scrapely-client-python"
|
|
52
55
|
|
|
53
56
|
[dependency-groups]
|
|
54
57
|
dev = [
|
|
@@ -258,7 +261,7 @@ custom_file_header = "# generated by datamodel-codegen"
|
|
|
258
261
|
disable_timestamp = true
|
|
259
262
|
keep_model_order = true
|
|
260
263
|
|
|
261
|
-
[tool.
|
|
264
|
+
[tool.scrapely.openapi-spec]
|
|
262
265
|
version = "v2-2026-08-05T133145Z"
|
|
263
266
|
|
|
264
267
|
[tool.uv]
|
|
@@ -272,9 +275,6 @@ source-include = [
|
|
|
272
275
|
]
|
|
273
276
|
|
|
274
277
|
[tool.uv.exclude-newer-package]
|
|
275
|
-
apify-client = false
|
|
276
|
-
apify-shared = false
|
|
277
|
-
apify_fingerprint_datapoints = false
|
|
278
278
|
crawlee = false
|
|
279
279
|
|
|
280
280
|
[tool.poe.tasks]
|
|
@@ -284,9 +284,9 @@ build = "uv build"
|
|
|
284
284
|
publish-to-pypi = "uv publish --token ${SCRAPELY_PYPI_TOKEN}"
|
|
285
285
|
type-check = "uv run ty check"
|
|
286
286
|
unit-tests = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} tests/unit"
|
|
287
|
-
unit-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/
|
|
287
|
+
unit-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/scrapely_client --cov-report=xml:coverage-unit.xml tests/unit"
|
|
288
288
|
integration-tests = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} tests/integration"
|
|
289
|
-
integration-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/
|
|
289
|
+
integration-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/scrapely_client --cov-report=xml:coverage-integration.xml tests/integration"
|
|
290
290
|
check-docstrings = "uv run python -m scripts.check_docstrings"
|
|
291
291
|
fix-docstrings = "uv run python -m scripts.fix_docstrings"
|
|
292
292
|
check-code = [
|
|
@@ -324,7 +324,7 @@ uv run python -m scripts.openapi_spec fetch && uv run datamodel-codegen --input
|
|
|
324
324
|
|
|
325
325
|
[tool.poe.tasks.generate-models-from-file]
|
|
326
326
|
shell = """
|
|
327
|
-
uv run datamodel-codegen --input $input_file --alias-generator to_camel && uv run datamodel-codegen --input $input_file --output src/scrapely_client/_typeddicts.py --output-model-type typing.TypedDict --no-use-closed-typed-dict && python scripts/postprocess_generated_models.py && echo "Generated from $input_file - the version in [tool.
|
|
327
|
+
uv run datamodel-codegen --input $input_file --alias-generator to_camel && uv run datamodel-codegen --input $input_file --output src/scrapely_client/_typeddicts.py --output-model-type typing.TypedDict --no-use-closed-typed-dict && python scripts/postprocess_generated_models.py && echo "Generated from $input_file - the version in [tool.scrapely.openapi-spec] still names the published specification, so do not commit these models."
|
|
328
328
|
"""
|
|
329
329
|
|
|
330
330
|
[[tool.poe.tasks.generate-models-from-file.args]]
|
|
@@ -4,11 +4,11 @@ build-backend = "uv_build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "scrapely-client-python"
|
|
7
|
-
version = "1.0.
|
|
7
|
+
version = "1.0.6"
|
|
8
8
|
description = "Scrapely API client for Python"
|
|
9
|
-
authors = [{ name = "
|
|
9
|
+
authors = [{ name = "TeraShift GmbH (Scrape.ly)" }]
|
|
10
10
|
license = "Apache-2.0"
|
|
11
|
-
license-files = ["LICENSE"]
|
|
11
|
+
license-files = ["LICENSE", "NOTICE"]
|
|
12
12
|
readme = "README.md"
|
|
13
13
|
requires-python = ">=3.11"
|
|
14
14
|
classifiers = [
|
|
@@ -36,11 +36,11 @@ dependencies = [
|
|
|
36
36
|
brotli = ["brotli>=1.0.9"]
|
|
37
37
|
|
|
38
38
|
[project.urls]
|
|
39
|
-
"Homepage" = "https://
|
|
40
|
-
"Changelog" = "https://github.com/
|
|
41
|
-
"Documentation" = "https://
|
|
42
|
-
"Issue Tracker" = "https://github.com/
|
|
43
|
-
"Source Code" = "https://github.com/
|
|
39
|
+
"Homepage" = "https://scrape.ly"
|
|
40
|
+
"Changelog" = "https://github.com/scrapely-app/scrapely-client-python/blob/main/CHANGELOG.md"
|
|
41
|
+
"Documentation" = "https://scrape.ly/docs/client-python"
|
|
42
|
+
"Issue Tracker" = "https://github.com/scrapely-app/scrapely-client-python/issues"
|
|
43
|
+
"Source Code" = "https://github.com/scrapely-app/scrapely-client-python"
|
|
44
44
|
|
|
45
45
|
[dependency-groups]
|
|
46
46
|
dev = [
|
|
@@ -67,7 +67,7 @@ dev = [
|
|
|
67
67
|
]
|
|
68
68
|
|
|
69
69
|
[tool.uv.build-backend]
|
|
70
|
-
# The module, pyproject.toml, README, and LICENSE are included in the sdist by default.
|
|
70
|
+
# The module, pyproject.toml, README, and the license files (LICENSE, NOTICE) are included in the sdist by default.
|
|
71
71
|
module-name = "scrapely_client"
|
|
72
72
|
source-include = ["CHANGELOG.md", "CONTRIBUTING.md"]
|
|
73
73
|
|
|
@@ -248,13 +248,13 @@ keep_model_order = true
|
|
|
248
248
|
|
|
249
249
|
# Which published OpenAPI specification the committed `_models.py`, `_typeddicts.py`, and `_literals.py` were
|
|
250
250
|
# generated from. A coarse marker, not a content identity: the specification is served latest-only, so the version
|
|
251
|
-
# can't fetch that document back, and
|
|
251
|
+
# can't fetch that document back, and the docs repository bumps `components/version.yaml` in a follow-up `[skip ci]` commit,
|
|
252
252
|
# so a deploy can publish new content under the old stamp.
|
|
253
253
|
#
|
|
254
254
|
# `poe generate-models` records whatever it downloaded, unconditionally; what keeps the value honest is the nightly
|
|
255
255
|
# workflow committing nothing unless the models changed. A local regeneration that only moves this line is that
|
|
256
256
|
# same case - drop it rather than committing it alone.
|
|
257
|
-
[tool.
|
|
257
|
+
[tool.scrapely.openapi-spec]
|
|
258
258
|
version = "v2-2026-08-05T133145Z"
|
|
259
259
|
|
|
260
260
|
[tool.uv]
|
|
@@ -262,10 +262,7 @@ version = "v2-2026-08-05T133145Z"
|
|
|
262
262
|
exclude-newer = "24 hours"
|
|
263
263
|
|
|
264
264
|
[tool.uv.exclude-newer-package]
|
|
265
|
-
# Allow
|
|
266
|
-
apify-client = false
|
|
267
|
-
apify-shared = false
|
|
268
|
-
apify_fingerprint_datapoints = false
|
|
265
|
+
# Allow these packages to install immediately.
|
|
269
266
|
crawlee = false
|
|
270
267
|
|
|
271
268
|
# Run tasks with: uv run poe <task>
|
|
@@ -276,9 +273,9 @@ build = "uv build"
|
|
|
276
273
|
publish-to-pypi = "uv publish --token ${SCRAPELY_PYPI_TOKEN}"
|
|
277
274
|
type-check = "uv run ty check"
|
|
278
275
|
unit-tests = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} tests/unit"
|
|
279
|
-
unit-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/
|
|
276
|
+
unit-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/scrapely_client --cov-report=xml:coverage-unit.xml tests/unit"
|
|
280
277
|
integration-tests = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} tests/integration"
|
|
281
|
-
integration-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/
|
|
278
|
+
integration-tests-cov = "uv run pytest --numprocesses=${TESTS_CONCURRENCY:-auto} --cov=src/scrapely_client --cov-report=xml:coverage-integration.xml tests/integration"
|
|
282
279
|
check-docstrings = "uv run python -m scripts.check_docstrings"
|
|
283
280
|
fix-docstrings = "uv run python -m scripts.fix_docstrings"
|
|
284
281
|
check-code = ["lint", "type-check", "check-docstrings", "unit-tests"]
|
|
@@ -333,6 +330,6 @@ uv run datamodel-codegen --input $input_file \
|
|
|
333
330
|
--output-model-type typing.TypedDict \
|
|
334
331
|
--no-use-closed-typed-dict \
|
|
335
332
|
&& python scripts/postprocess_generated_models.py \
|
|
336
|
-
&& echo "Generated from $input_file - the version in [tool.
|
|
333
|
+
&& echo "Generated from $input_file - the version in [tool.scrapely.openapi-spec] still names the published specification, so do not commit these models."
|
|
337
334
|
"""
|
|
338
335
|
args = [{ name = "input-file", positional = true, required = true }]
|
{scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_charging.py
RENAMED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
"""Opt-in pay-per-event charging interception for dataset pushes.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Charging interception for dataset pushes, implemented in the client
|
|
4
4
|
itself, with the charging logic supplied by the host SDK via the
|
|
5
5
|
:class:`ChargingHooks` protocol (no SDK import — the SDK adapts its
|
|
6
6
|
``ChargingManager`` to these hooks later).
|
|
7
7
|
|
|
8
|
-
Without hooks (the default),
|
|
9
|
-
``apify-client``.
|
|
8
|
+
Without hooks (the default), dataset pushes are not intercepted.
|
|
10
9
|
"""
|
|
11
10
|
|
|
12
11
|
from __future__ import annotations
|
|
@@ -126,7 +125,7 @@ def _merge_context_charge_result(context: PpeAwarePushDataContext, hooks: Chargi
|
|
|
126
125
|
def wrap_dataset_client_with_charging(client: Any, hooks: ChargingHooks, *, is_async: bool) -> Any:
|
|
127
126
|
"""Wrap a dataset client's ``push_items`` with charging interception (method swap by design).
|
|
128
127
|
|
|
129
|
-
|
|
128
|
+
Normalize items →
|
|
130
129
|
``push_and_charge`` with a ``push_fn`` that pushes the accepted subset via the
|
|
131
130
|
original ``push_items``, and accumulate the charge result into the ambient
|
|
132
131
|
``push_data_charging_context`` when present.
|
{scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_consts.py
RENAMED
|
@@ -1,8 +1,10 @@
|
|
|
1
|
+
# Derived from apify-client-python (Copyright Apify Technologies s.r.o., Apache-2.0).
|
|
2
|
+
# Modified by TeraShift GmbH. See the LICENSE and NOTICE files.
|
|
1
3
|
from __future__ import annotations
|
|
2
4
|
|
|
3
5
|
from datetime import timedelta
|
|
4
6
|
|
|
5
|
-
DEFAULT_API_URL = 'https://api
|
|
7
|
+
DEFAULT_API_URL = 'https://api.scrape.ly'
|
|
6
8
|
"""Default base URL for the Scrapely API."""
|
|
7
9
|
|
|
8
10
|
API_VERSION = 'v2'
|
{scrapely_client_python-1.0.2 → scrapely_client_python-1.0.6}/src/scrapely_client/_logging.py
RENAMED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# Derived from apify-client-python (Copyright Apify Technologies s.r.o., Apache-2.0).
|
|
2
|
+
# Modified by TeraShift GmbH. See the LICENSE and NOTICE files.
|
|
1
3
|
from __future__ import annotations
|
|
2
4
|
|
|
3
5
|
import functools
|
|
@@ -108,7 +110,7 @@ def create_redirect_logger(name: str) -> logging.Logger:
|
|
|
108
110
|
"""Create a logger for redirecting logs from another Actor.
|
|
109
111
|
|
|
110
112
|
Args:
|
|
111
|
-
name: Logger name. Use dot notation for hierarchy (e.g., "
|
|
113
|
+
name: Logger name. Use dot notation for hierarchy (e.g., "scrapely.xyz" creates "xyz" under "scrapely").
|
|
112
114
|
|
|
113
115
|
Returns:
|
|
114
116
|
Configured logger with RedirectLogFormatter.
|