Improve lint issues
This commit is contained in:
parent
ebbabe321c
commit
26d2a91192
@ -1,4 +1,4 @@
|
|||||||
from contextlib import AbstractContextManager, contextmanager
|
from contextlib import AbstractContextManager
|
||||||
|
|
||||||
|
|
||||||
class Step(AbstractContextManager):
|
class Step(AbstractContextManager):
|
||||||
@ -25,4 +25,4 @@ class Step(AbstractContextManager):
|
|||||||
|
|
||||||
def __exit__(self, exc_type, exc_val, exc_tb):
|
def __exit__(self, exc_type, exc_val, exc_tb):
|
||||||
# close the step
|
# close the step
|
||||||
print(f"\n```", flush=True)
|
print("\n```", flush=True)
|
||||||
|
@ -2,7 +2,6 @@ from abc import ABC, abstractmethod
|
|||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from typing import Any, Callable, Optional
|
from typing import Any, Callable, Optional
|
||||||
|
|
||||||
from openai import OpenAI
|
|
||||||
from tools.directory_viewer import mk_repo_file_criteria
|
from tools.directory_viewer import mk_repo_file_criteria
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import json
|
import json
|
||||||
from typing import List, Optional, Tuple
|
from typing import List, Optional
|
||||||
|
|
||||||
from model import FuncToTest
|
from model import FuncToTest
|
||||||
from openai_util import create_chat_completion_content
|
from openai_util import create_chat_completion_content
|
||||||
|
@ -1,13 +1,10 @@
|
|||||||
import json
|
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
from collections import defaultdict
|
from collections import defaultdict
|
||||||
from functools import partial
|
from typing import Dict, List, Optional, Set
|
||||||
from typing import Dict, Iterable, List, Optional, Set, Tuple
|
|
||||||
|
|
||||||
from assistants.recommend_test_context import get_recommended_symbols
|
from assistants.recommend_test_context import get_recommended_symbols
|
||||||
from model import FuncToTest
|
from model import FuncToTest
|
||||||
from tools.file_util import retrieve_file_content
|
|
||||||
from tools.symbol_util import (
|
from tools.symbol_util import (
|
||||||
find_symbol_nodes,
|
find_symbol_nodes,
|
||||||
get_symbol_content,
|
get_symbol_content,
|
||||||
|
@ -8,7 +8,7 @@ from tools.file_util import retrieve_file_content
|
|||||||
|
|
||||||
sys.path.append(os.path.join(os.path.dirname(__file__), "..", ".."))
|
sys.path.append(os.path.join(os.path.dirname(__file__), "..", ".."))
|
||||||
|
|
||||||
from libs.ide_services import IDEService, Location, Position, SymbolNode
|
from libs.ide_services import Position, SymbolNode
|
||||||
|
|
||||||
|
|
||||||
def split_tokens(text: str) -> Dict[str, List[int]]:
|
def split_tokens(text: str) -> Dict[str, List[int]]:
|
||||||
|
@ -42,7 +42,7 @@ def _mk_write_tests_msg(
|
|||||||
|
|
||||||
context_content = ""
|
context_content = ""
|
||||||
if symbol_context:
|
if symbol_context:
|
||||||
context_content += f"\n\nrelevant context\n```\n"
|
context_content += "\n\nrelevant context\n```\n"
|
||||||
context_content += "\n\n".join(symbol_context)
|
context_content += "\n\n".join(symbol_context)
|
||||||
context_content += "\n```\n"
|
context_content += "\n```\n"
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user