scrapely-python 0.1.50__tar.gz → 0.1.51__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_python-0.1.50 → scrapely_python-0.1.51}/CHANGELOG.md +4 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/PKG-INFO +1 -1
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/pyproject.toml +1 -1
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/__init__.py +1 -1
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/charging.py +7 -7
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely_python.egg-info/PKG-INFO +1 -1
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/LICENSE +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/LICENSE-APACHE +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/MANIFEST.in +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/NOTICE +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/README.md +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/setup.cfg +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/_browser_locations.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/actor.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/browser_configuration.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/cdp_retry.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/charging_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/configuration.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/crypto/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/crypto/_secrets.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/errors.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/events/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/events/_types.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/events/event_manager.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_capture.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_compat.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_detect.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_headers.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_options.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_policy.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_profiles.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_response.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_stats.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/_transport.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/http/profiles.json +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/log.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/patch_browser_pool.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/pricing_types.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/proxy_configuration.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/py.typed +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/request_loaders/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/request_loaders/_scrapely_request_list.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/resume_dedupe.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/_actor_runner.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/_async_thread.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/_logging_config.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/_serialization.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/_warnings.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/extensions/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/extensions/_graceful_stop.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/extensions/_httpcache.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/middlewares/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/middlewares/apify_proxy.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/pipelines/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/pipelines/actor_dataset_push.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/requests.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/scheduler.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/utils.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/solver.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/_file_system/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/_file_system/_key_value_store_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/_file_system/_storage_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/_metadata.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/api_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/patch_storage.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_dataset_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_kvs_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_rq_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_storage_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/smart_scrapely_storage_client.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/types.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/utils.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage_clients/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storages/__init__.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/types.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/webhook.py +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely_python.egg-info/SOURCES.txt +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely_python.egg-info/dependency_links.txt +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely_python.egg-info/requires.txt +0 -0
- {scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely_python.egg-info/top_level.txt +0 -0
|
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [0.1.51] - 2026-11-18
|
|
8
|
+
|
|
9
|
+
- **A charged push that fails is always voided.** `Actor.push_data(items, charged_event_name)` and `push_data(rows, charges={...})` charge before the push; when the push then fails, its charge is now voided also when the outcome is unknown: a read timeout or dropped connection after sending, an error after a re-send that may have been stored, or the API's `503 push-outcome-unknown`. Before, the charge stood in those cases because the rows might be in the dataset. A user is now never charged for rows that may not have been stored; rows that were stored anyway are free. Pushes that succeed are charged exactly as before.
|
|
10
|
+
|
|
7
11
|
## [0.1.50] - 2026-11-13
|
|
8
12
|
|
|
9
13
|
- **A charge accepted in full no longer reports the limit as reached.** `ChargeResult.event_charge_limit_reached` (from `Actor.charge()`, `Actor.push_data()` and `push_data(rows, charges={...})`) was `True` whenever the room left under `maxTotalChargeUsd` was below one more event, even when nothing had been refused. Actors stop on it and end with "stopped because the maximum charge for this run was reached", which the SDK words as "Stopped: reached the maximum charge you set ($0.05)", so a run that had saved everything it was asked for said it had been stopped by its maximum charge. It is now `True` only once the limit really refused or cut a charge or dropped rows; such a run ends with its own status message, and a run with more to do gets `True` from its next charge or push, which is refused. A charged push to a named dataset that the budget trims now also reports it. `chargeable_within_limit`, `calculate_max_event_charge_count_within_limit()` and `is_charge_limit_reached()` are unchanged. Charging is unchanged.
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "scrapely-python"
|
|
7
|
-
version = "0.1.
|
|
7
|
+
version = "0.1.51"
|
|
8
8
|
description = "Scrapely Python SDK - A toolkit for building Actors on the Scrapely platform"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
license = "MIT AND Apache-2.0"
|
|
@@ -2319,11 +2319,10 @@ async def _push_data_and_charge_one(
|
|
|
2319
2319
|
accepted_for_items,
|
|
2320
2320
|
push_err,
|
|
2321
2321
|
)
|
|
2322
|
-
#
|
|
2323
|
-
#
|
|
2324
|
-
#
|
|
2325
|
-
|
|
2326
|
-
raise
|
|
2322
|
+
# Every failed push is voided, also a timeout, a reset after
|
|
2323
|
+
# sending or an unknown outcome (_push_certainly_failed False):
|
|
2324
|
+
# the rows may be in the dataset, but a user is never charged
|
|
2325
|
+
# for rows that may not have been stored.
|
|
2327
2326
|
for i, ((name, _), op_id) in enumerate(zip(reserved_in_op, operation_ids)):
|
|
2328
2327
|
kept = min(accepted_for_items, results[i].charged_count)
|
|
2329
2328
|
if credit_used[i]:
|
|
@@ -2586,8 +2585,8 @@ async def _push_data_with_charges_one(
|
|
|
2586
2585
|
await _gated_push(push_fn, kept)
|
|
2587
2586
|
except Exception as push_err:
|
|
2588
2587
|
logger.error('Dataset push failed after charges accepted (rows=%s): %s; voiding the charges', rows, push_err)
|
|
2589
|
-
|
|
2590
|
-
|
|
2588
|
+
# Voided also when the outcome is unknown: never charge for rows that may not be stored.
|
|
2589
|
+
await undo(ops)
|
|
2591
2590
|
raise
|
|
2592
2591
|
_log_atomic_refusal(shorts, len(rows_in), len(kept), given_back)
|
|
2593
2592
|
return ChargeResult(
|
|
@@ -2651,6 +2650,7 @@ def _push_certainly_failed(err: BaseException) -> bool:
|
|
|
2651
2650
|
resets after sending are not proof: the write may have landed,
|
|
2652
2651
|
and neither is any error of a push one of whose earlier attempts may have been
|
|
2653
2652
|
applied (``outcome_unknown``, set by the storage client's retries).
|
|
2653
|
+
Charging does not use it: a failed push is voided either way.
|
|
2654
2654
|
"""
|
|
2655
2655
|
import httpx
|
|
2656
2656
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/extensions/__init__.py
RENAMED
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/extensions/_graceful_stop.py
RENAMED
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/extensions/_httpcache.py
RENAMED
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/middlewares/__init__.py
RENAMED
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/scrapy/middlewares/apify_proxy.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/_file_system/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_dataset_client.py
RENAMED
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_kvs_client.py
RENAMED
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_rq_client.py
RENAMED
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely/storage/scrapely_storage_client.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely_python.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
{scrapely_python-0.1.50 → scrapely_python-0.1.51}/src/scrapely_python.egg-info/top_level.txt
RENAMED
|
File without changes
|