Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update minimal required Python to 3.10 #264

Closed
rmast opened this issue Aug 21, 2024 · 2 comments
Closed

Update minimal required Python to 3.10 #264

rmast opened this issue Aug 21, 2024 · 2 comments

Comments

@rmast
Copy link

rmast commented Aug 21, 2024

This error was caused by requiring Python 3.9 in the readme:

  You can now view your Streamlit app in your browser.

  Local URL: http://localhost:8501
  Network URL: http://10.11.0.4:8501

2024-08-21 12:57:35.364 Uncaught app exception
Traceback (most recent call last):
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/streamlit/runtime/scriptrunner/exec_code.py", line 85, in exec_func_with_error_handling
    result = func()
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 576, in code_to_exec
    exec(code, module.__dict__)
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/marker_app.py", line 14, in <module>
    from marker.convert import convert_single_pdf
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/marker/convert.py", line 12, in <module>
    from marker.tables.table import format_tables
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/marker/tables/table.py", line 3, in <module>
    from marker.schema.page import Page
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/marker/schema/page.py", line 6, in <module>
    from surya.schema import TextDetectionResult, LayoutResult, OrderResult
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/surya/schema.py", line 141, in <module>
    class OCRResult(BaseModel):
  File "/home/rmast/miniconda3/envs/marker/lib/python3.9/site-packages/surya/schema.py", line 143, in OCRResult
    languages: List[str] | None = None
TypeError: unsupported operand type(s) for |: '_GenericAlias' and 'NoneType'
Geëlimineerd
@Volkopat
Copy link

Same, doesn't seem to work for Python 3.9:

marker-api | Traceback (most recent call last):
marker-api | File "/app/api.py", line 10, in
marker-api | from marker.convert import convert_single_pdf
marker-api | File "/app/marker/convert.py", line 12, in
marker-api | from marker.tables.table import format_tables
marker-api | File "/app/marker/tables/table.py", line 3, in
marker-api | from marker.schema.page import Page
marker-api | File "/app/marker/schema/page.py", line 6, in
marker-api | from surya.schema import TextDetectionResult, LayoutResult, OrderResult
marker-api | File "/usr/local/lib/python3.9/dist-packages/surya/schema.py", line 141, in
marker-api | class OCRResult(BaseModel):
marker-api | File "/usr/local/lib/python3.9/dist-packages/surya/schema.py", line 143, in OCRResult
marker-api | languages: List[str] | None = None
marker-api | TypeError: unsupported operand type(s) for |: '_GenericAlias' and 'NoneType'
marker-api exited with code 1

@VikParuchuri
Copy link
Owner

Fixed - py3.9 support dropped

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants