Skip to content

Commit

Permalink
fix: Encoding error in upload files example
Browse files Browse the repository at this point in the history
closes #208
  • Loading branch information
mgmacias95 authored Feb 21, 2025
1 parent d7534f6 commit 09412a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/upload_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ async def upload_hashes(queue, apikey):
async with vt.Client(apikey) as client:
while not queue.empty():
file_path = await queue.get()
with open(file_path, encoding="utf-8") as f:
with open(file_path, 'rb') as f:
analysis = await client.scan_file_async(file=f)
print(f"File {file_path} uploaded.")
queue.task_done()
Expand Down

0 comments on commit 09412a7

Please sign in to comment.