Skip to content

Commit

Permalink
append mode rather than write
Browse files Browse the repository at this point in the history
  • Loading branch information
hrshdhgd committed Feb 14, 2024
1 parent 7b4de54 commit 3bae590
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kg_microbe/utils/s3_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def _read_organisms_from_csv(file_path):
def _write_file(file_path, response, organism_id):
# Write response to file if it contains data
if len(response.text.strip().split("\n")) > 1:
with open(file_path, "w") as file:
with open(file_path, "a") as file:
file.write(response.text)
else:
# Append organism ID to the empty organisms file
Expand Down

0 comments on commit 3bae590

Please sign in to comment.