Skip to content

Commit

Permalink
fix: Encoding error in upload files example (#209)
Browse files Browse the repository at this point in the history
  • Loading branch information
mgmacias95 authored Feb 21, 2025
1 parent d7534f6 commit e53590d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/testing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ on: [push]
jobs:
build:

runs-on: ubuntu-latest
runs-on: 'ubuntu-latest'
strategy:
matrix:
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12']
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']

steps:
- uses: actions/checkout@v3
Expand Down
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 e53590d

Please sign in to comment.