From 87556d3699df3cf02294ec73b02256a9cf46bdd2 Mon Sep 17 00:00:00 2001 From: 7000pctAUTO Date: Wed, 4 Feb 2026 11:16:16 +0000 Subject: [PATCH] fix: resolve CI/CD issues for Python project --- shellgenius/history.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/shellgenius/history.py b/shellgenius/history.py index deace2f..bef65e5 100644 --- a/shellgenius/history.py +++ b/shellgenius/history.py @@ -1,6 +1,5 @@ """Command history learning system for ShellGenius.""" -import json import os from dataclasses import dataclass, field from datetime import datetime @@ -154,9 +153,9 @@ class HistoryStorage: description=entry["description"], commands=entry["commands"], shell_type=entry["shell_type"], - usage_count=e.get("usage_count", 1), - tags=e.get("tags", []), - success=e.get("success", True), + usage_count=entry.get("usage_count", 1), + tags=entry.get("tags", []), + success=entry.get("success", True), ) ) if len(results) >= limit: @@ -316,7 +315,7 @@ class HistoryLearner: """ entries = self.storage.get_entries(limit=100) - patterns = { + patterns: Dict[str, Dict[str, int]] = { "shell_types": {}, "common_commands": {}, "frequent_tags": {},