refactor(examples): rename pixels_per_unit to pricing_unit_size#28
refactor(examples): rename pixels_per_unit to pricing_unit_size#28rickstaa wants to merge 1 commit into
Conversation
Align user-facing pricing terminology with go-livepeer, which renames the -pixelsPerUnit flag to -pricingUnitSize. The value is the size of one pricing unit in work units, not pixels; "pixels" is transcoding-era legacy that confuses non-video / BYOC / general-runner workloads. Output dict key pixels_per_unit -> pricing_unit_size and text "per N pixel(s)" -> "per N work unit(s)". The wire/proto field (PriceInfo.pixelsPerUnit) is read as-is and left unchanged. Refs livepeer/go-livepeer#3942 Closes #27 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughIn ChangesPricing terminology rename
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
What
Renames the user-facing pricing term
pixels_per_unittopricing_unit_sizeinexamples/get_orchestrator_info.py, aligning the SDK with go-livepeer's flag rename (-pixelsPerUnit->-pricingUnitSize, livepeer/go-livepeer#3942).pixelsPerUnitis really just a pricing scale factor: the number of work units one quoted price covers (price_per_work_unit = pricePerUnit / pixelsPerUnit). "pixels" is transcoding-era legacy and is misleading for non-video / BYOC / general-runner workloads.Changes
pixels_per_unit->pricing_unit_size(general + capability-specific pricing).... wei per N pixel(s)->... wei per N work unit(s).Compatibility
No wire changes. The generated proto field (
PriceInfo.pixelsPerUnit) is read as-is and left unchanged; only the example's display labels and output dict key change.Related
ja/live-runner) should adopt the samepricing_unit_sizename for consistency.Summary by CodeRabbit