vrex-flow-engine 0.2.1__tar.gz → 0.2.2__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.
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/PKG-INFO +1 -1
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/bridge/flow_client.py +9 -2
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/bridge/flow_sdk.py +3 -2
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/pyproject.toml +1 -1
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/PKG-INFO +1 -1
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/PYPI_README.md +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/__init__.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/bridge/__init__.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/bridge/ws_server.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/catalog.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/cli/__init__.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/cli/app.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/cli/config.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/cli/dashboard.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/cli/health.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/cli/processes.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/cli/supervisor.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/config.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/ingest.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/job_store.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/jobs.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/main.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/media.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/media_store.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/openai/__init__.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/openai/_util.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/openai/images.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/openai/models.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/openai/uploads.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/openai/videos.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/pool.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/posthog_client.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/session.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/video_context.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/flow_engine/video_context_store.py +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/setup.cfg +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/SOURCES.txt +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/dependency_links.txt +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/entry_points.txt +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/requires.txt +0 -0
- {vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/top_level.txt +0 -0
|
@@ -35,6 +35,13 @@ logger = logging.getLogger(__name__)
|
|
|
35
35
|
# need to plumb it through from the extension on every call.
|
|
36
36
|
_FLOW_API_KEY = "AIzaSyBtrm0o5ab1c-Ec8ZuLcGt3oJAA5VWt3pY"
|
|
37
37
|
_FLOW_CREDITS_URL = "https://aisandbox-pa.googleapis.com/v1/credits"
|
|
38
|
+
|
|
39
|
+
# Concrete paygate tiers Google returns that we accept as "resolved". Google
|
|
40
|
+
# periodically introduces tiers (ONE=Pro, TWO=Ultra, TIER1P5="Tier 1.5"); an
|
|
41
|
+
# unknown or `PAYGATE_TIER_UNSPECIFIED` value means the tier isn't resolved.
|
|
42
|
+
# Single source of truth — flow_sdk imports this for its dispatch-time guard so
|
|
43
|
+
# the two sites can never drift (a drift is what silently blocked TIER1P5).
|
|
44
|
+
VALID_PAYGATE_TIERS = ("PAYGATE_TIER_ONE", "PAYGATE_TIER_TWO", "PAYGATE_TIER_TIER1P5")
|
|
38
45
|
# Minimum gap between paygate-tier refreshes when the same Bearer token
|
|
39
46
|
# is re-delivered. Tier rarely changes; 60 s is fine for AccountPanel
|
|
40
47
|
# freshness and tames the credits-fetch storm an old extension can
|
|
@@ -182,9 +189,9 @@ class FlowClient:
|
|
|
182
189
|
logger.warning("fetch_paygate_tier: response was not JSON")
|
|
183
190
|
return False
|
|
184
191
|
tier = data.get("userPaygateTier")
|
|
185
|
-
if tier not in
|
|
192
|
+
if tier not in VALID_PAYGATE_TIERS:
|
|
186
193
|
logger.warning(
|
|
187
|
-
"fetch_paygate_tier:
|
|
194
|
+
"fetch_paygate_tier: unsupported userPaygateTier (got %r)",
|
|
188
195
|
tier,
|
|
189
196
|
)
|
|
190
197
|
return False
|
|
@@ -17,7 +17,7 @@ import time
|
|
|
17
17
|
import uuid
|
|
18
18
|
from typing import Any, Optional
|
|
19
19
|
|
|
20
|
-
from flow_engine.bridge.flow_client import FlowClient
|
|
20
|
+
from flow_engine.bridge.flow_client import FlowClient, VALID_PAYGATE_TIERS
|
|
21
21
|
|
|
22
22
|
logger = logging.getLogger(__name__)
|
|
23
23
|
|
|
@@ -1465,7 +1465,8 @@ def _extract_project_id(resp: Any) -> Optional[str]:
|
|
|
1465
1465
|
return None
|
|
1466
1466
|
|
|
1467
1467
|
|
|
1468
|
-
|
|
1468
|
+
# Dispatch-time guard shares flow_client's single tier list (no drift).
|
|
1469
|
+
_VALID_TIERS = set(VALID_PAYGATE_TIERS)
|
|
1469
1470
|
|
|
1470
1471
|
|
|
1471
1472
|
def _extract_uploaded_media_id(resp: Any) -> Optional[str]:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "vrex-flow-engine"
|
|
3
|
-
version = "0.2.
|
|
3
|
+
version = "0.2.2"
|
|
4
4
|
description = "Launcher + supervisor and OpenAI-compatible image/video generation service (Vrex Flow Engine)."
|
|
5
5
|
# Neutral public description (the in-repo README.md carries the full internal docs).
|
|
6
6
|
readme = "PYPI_README.md"
|
|
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
|
{vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
{vrex_flow_engine-0.2.1 → vrex_flow_engine-0.2.2}/vrex_flow_engine.egg-info/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|