Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -2595,9 +2595,9 @@ def create_ui(manager: IssueManager) -> gr.Blocks:
|
|
2595 |
else:
|
2596 |
logger.warning(f"On-demand file path {file_path_str} not found or not a file during load for issue {selected_id}.")
|
2597 |
files_content[file_path_str] = f"# File not found or not a file: {file_path_str}"
|
2598 |
-
|
2599 |
-
|
2600 |
-
|
2601 |
if loaded_count == 0 and context_result["files"]:
|
2602 |
files_content["error_reading_files.txt"] = "# Context computation found file references, but failed to read any file content."
|
2603 |
else:
|
@@ -2672,6 +2672,7 @@ def create_ui(manager: IssueManager) -> gr.Blocks:
|
|
2672 |
# Add common code/issue terms (lowercase)
|
2673 |
stop_words.update({'issue', 'bug', 'error', 'fix', 'feat', 'chore', 'refactor', 'docs', 'test', 'file', 'line', 'code', 'when', 'user', 'report', 'problem', 'need', 'want', 'get', 'use', 'try', 'make', 'add', 'remove', 'change', 'update', 'create', 'build', 'run', 'start', 'stop', 'click', 'button', 'page', 'app', 'data', 'system', 'service', 'component', 'module', 'function', 'class', 'method', 'variable', 'value', 'string', 'number', 'list', 'dict', 'object', 'array', 'true', 'false', 'null', 'none', 'type', 'size', 'color', 'style', 'width', 'height', 'margin', 'padding', 'border', 'display', 'position', 'float', 'clear', 'overflow', 'index', 'key', 'value', 'id', 'name', 'text', 'html', 'css', 'js', 'py', 'java', 'c', 'cpp', 'h', 'hpp', 'go', 'rs', 'php', 'rb', 'json', 'yaml', 'xml', 'sql', 'log', 'config', 'setup', 'install', 'version', 'release', 'branch', 'commit', 'pull', 'request', 'merge', 'diff', 'patch', 'context', 'suggestion', 'analysis', 'missing', 'information', 'duplicate', 'potential', 'cluster', 'severity', 'label', 'assignee', 'state', 'title', 'body', 'url', 'created', 'updated', 'time', 'day', 'week', 'month', 'year', 'ago', 'now', 'new', 'old', 'different', 'same', 'similar', 'group', 'count', 'distribution', 'analytics', 'overview', 'studio', 'board', 'resolution', 'collaborative', 'editor', 'context', 'aware', 'assistance', 'tools', 'output', 'patch', 'steps', 'approach', 'plan', 'identify', 'propose', 'recommendation', 'workflow', 'standard', 'important', 'critical', 'high', 'medium', 'low', 'unknown', 'none', 'needed', 'analysis', 'hypothesis', 'preliminary', 'relevant', 'area', 'investigation', 'implementation', 'testing', 'next'})
|
2674 |
|
|
|
2675 |
def get_top_keywords(indices):
|
2676 |
text = ""
|
2677 |
for idx in indices:
|
|
|
2595 |
else:
|
2596 |
logger.warning(f"On-demand file path {file_path_str} not found or not a file during load for issue {selected_id}.")
|
2597 |
files_content[file_path_str] = f"# File not found or not a file: {file_path_str}"
|
2598 |
+
except Exception as e:
|
2599 |
+
logger.warning(f"Error reading on-demand file {full_path} for issue {selected_id}: {e}")
|
2600 |
+
files_content[file_path_str] = f"# Error reading file: {e}"
|
2601 |
if loaded_count == 0 and context_result["files"]:
|
2602 |
files_content["error_reading_files.txt"] = "# Context computation found file references, but failed to read any file content."
|
2603 |
else:
|
|
|
2672 |
# Add common code/issue terms (lowercase)
|
2673 |
stop_words.update({'issue', 'bug', 'error', 'fix', 'feat', 'chore', 'refactor', 'docs', 'test', 'file', 'line', 'code', 'when', 'user', 'report', 'problem', 'need', 'want', 'get', 'use', 'try', 'make', 'add', 'remove', 'change', 'update', 'create', 'build', 'run', 'start', 'stop', 'click', 'button', 'page', 'app', 'data', 'system', 'service', 'component', 'module', 'function', 'class', 'method', 'variable', 'value', 'string', 'number', 'list', 'dict', 'object', 'array', 'true', 'false', 'null', 'none', 'type', 'size', 'color', 'style', 'width', 'height', 'margin', 'padding', 'border', 'display', 'position', 'float', 'clear', 'overflow', 'index', 'key', 'value', 'id', 'name', 'text', 'html', 'css', 'js', 'py', 'java', 'c', 'cpp', 'h', 'hpp', 'go', 'rs', 'php', 'rb', 'json', 'yaml', 'xml', 'sql', 'log', 'config', 'setup', 'install', 'version', 'release', 'branch', 'commit', 'pull', 'request', 'merge', 'diff', 'patch', 'context', 'suggestion', 'analysis', 'missing', 'information', 'duplicate', 'potential', 'cluster', 'severity', 'label', 'assignee', 'state', 'title', 'body', 'url', 'created', 'updated', 'time', 'day', 'week', 'month', 'year', 'ago', 'now', 'new', 'old', 'different', 'same', 'similar', 'group', 'count', 'distribution', 'analytics', 'overview', 'studio', 'board', 'resolution', 'collaborative', 'editor', 'context', 'aware', 'assistance', 'tools', 'output', 'patch', 'steps', 'approach', 'plan', 'identify', 'propose', 'recommendation', 'workflow', 'standard', 'important', 'critical', 'high', 'medium', 'low', 'unknown', 'none', 'needed', 'analysis', 'hypothesis', 'preliminary', 'relevant', 'area', 'investigation', 'implementation', 'testing', 'next'})
|
2674 |
|
2675 |
+
|
2676 |
def get_top_keywords(indices):
|
2677 |
text = ""
|
2678 |
for idx in indices:
|