Skip to content

Commit b9bddc4

Browse files
author
anna.yamkovaya
committed
small changes
1 parent 8cf7095 commit b9bddc4

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

test2text/services/loaders/index_requirements.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,9 @@ def index_requirements_from_files(files: list):
1717
stringio = io.StringIO(file.getvalue().decode("utf-8"))
1818
reader = csv.reader(stringio)
1919

20-
if not list(reader):
21-
st.warning(f"The uploaded CSV file {file.name} is empty.")
22-
continue
23-
2420
if len(list(reader)) <= 3:
25-
st.warning(f"The uploaded CSV file {file.name}'s content is too short. There are only {len(list(reader))} lines.")
21+
st.warning(f"The uploaded CSV file {file.name}'s content is too short. "
22+
f"There are {len(list(reader))} lines inside.")
2623
continue
2724

2825
for _ in range(3):

0 commit comments

Comments
 (0)