Skip to content

Commit

Permalink
update import problems in python-lint.yml action.
Browse files Browse the repository at this point in the history
  • Loading branch information
moheladwy committed Dec 13, 2024
1 parent 6fbddd2 commit f466d1e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pylint
pip install pylint pillow pytesseract opencv-python-headless numpy
- name: Lint with pylint
run: |
Expand Down
4 changes: 2 additions & 2 deletions OCR4Linux.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def extract_text_with_lines(self, image):

# Group text by line
lines = {}
for i, level in enumerate(data['level']):
for i, _ in enumerate(data['level']):
if int(data['conf'][i]) > 60: # Filter low confidence results
page_num = data['page_num'][i]
block_num = data['block_num'][i]
Expand Down Expand Up @@ -100,7 +100,7 @@ def main(self):
return 0

except Exception as e:
print(f"Error processing image: {str(e)}")
print(f"Error processing image because: {str(e)}")
return 1


Expand Down

0 comments on commit f466d1e

Please sign in to comment.