Skip to content

tracerite>=1.1.2 cannot be used with python 3.8 #3072

@WilliamBergamin

Description

@WilliamBergamin

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

Summary

sanic/pages/error.py executes import tracerite.html and sanic requires tracerite with minimum version tracerite>=1.0.0 without an upper bound

tracerite does not specify a minimum python version for their package, but as of tracerite>1.1.2, tracerite.html executes from importlib.resources import files which is only supported by Python>=3.9. This creates a syntax error when importing Sanic with python 3.8

Workaround

I was able to work around this by installing tracerite<1.1.2 before installing sanic when using Python 3.8 (see slackapi/bolt-python#1320)

Suggestion

Sanic could set an upper bound for the tracerite requirement ex: tracerite>=1.0.0,<1.1.2

Code snippet

No response

Expected Behavior

Since sanic 25.3.0 supports python 3.8 I would expect no syntax error from sanic import Sanic

Suggestion: sanic could set an upper bound for the tracerite requirement ex: tracerite>=1.0.0,<1.1.2

How do you run Sanic?

As a module

Operating System

Linux

Sanic Version

23.12.2

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions