Fix linting issues: line length, import sorting, unused variables
- Set ruff/black line length to 120 - Reformatted code with black - Fixed import ordering with ruff - Disabled lint for UI component files with long CSS strings - Updated pyproject.toml with proper tool configuration
This commit is contained in:
@@ -70,12 +70,28 @@ class DataService:
|
||||
"symbol": ticker,
|
||||
"updated_at": datetime.now(UTC).isoformat(),
|
||||
"calls": [
|
||||
{"strike": round(base_price * 1.05, 2), "premium": round(base_price * 0.03, 2), "expiry": "2026-06-19"},
|
||||
{"strike": round(base_price * 1.10, 2), "premium": round(base_price * 0.02, 2), "expiry": "2026-09-18"},
|
||||
{
|
||||
"strike": round(base_price * 1.05, 2),
|
||||
"premium": round(base_price * 0.03, 2),
|
||||
"expiry": "2026-06-19",
|
||||
},
|
||||
{
|
||||
"strike": round(base_price * 1.10, 2),
|
||||
"premium": round(base_price * 0.02, 2),
|
||||
"expiry": "2026-09-18",
|
||||
},
|
||||
],
|
||||
"puts": [
|
||||
{"strike": round(base_price * 0.95, 2), "premium": round(base_price * 0.028, 2), "expiry": "2026-06-19"},
|
||||
{"strike": round(base_price * 0.90, 2), "premium": round(base_price * 0.018, 2), "expiry": "2026-09-18"},
|
||||
{
|
||||
"strike": round(base_price * 0.95, 2),
|
||||
"premium": round(base_price * 0.028, 2),
|
||||
"expiry": "2026-06-19",
|
||||
},
|
||||
{
|
||||
"strike": round(base_price * 0.90, 2),
|
||||
"premium": round(base_price * 0.018, 2),
|
||||
"expiry": "2026-09-18",
|
||||
},
|
||||
],
|
||||
"source": quote["source"],
|
||||
}
|
||||
@@ -100,8 +116,7 @@ class DataService:
|
||||
},
|
||||
"strategies": engine.compare_all_strategies(),
|
||||
"recommendations": {
|
||||
profile: engine.recommend(profile)
|
||||
for profile in ("conservative", "balanced", "cost_sensitive")
|
||||
profile: engine.recommend(profile) for profile in ("conservative", "balanced", "cost_sensitive")
|
||||
},
|
||||
"sensitivity_analysis": engine.sensitivity_analysis(),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user