8000 PYTHONOPTIMIZE 2 is breaking import of pottery · Issue #702 · brainix/pottery · GitHub
[go: up one dir, main page]

Skip to content
  • PYTHONOPTIMIZE 2 is breaking import of pottery #702

    Open

    Description

    @FairyTail2000

    Describe the bug
    The code crashes when importing pottery with PYTHONOPTIMIZE=2 set.

    To Reproduce
    Steps to reproduce the behavior:

    1. import pottery
    2. set enviroment variable PYTHONOPTIMIZE=2
    3. run the script
    4. See error

    Expected behavior
    Successful import

    Environment (please complete the following information):

    • OS: Linux
    • Python version: 3.11.5
    • Redis version: not applicable

    Activity

    1. FairyTail2000 commented on Sep 22, 2023

      @FairyTail2000
      Author

      Suggested patch:
      init.py: 36
      - __description__: Final[str] = __doc__.split(sep='\n\n', maxsplit=1)[0]
      + __description__: Final[str] = __doc__.split(sep='\n\n', maxsplit=1)[0] if __doc__ else ''

    2. self-assigned this
      on Sep 22, 2023
    3. gourneau commented on Sep 22, 2023

      @gourneau
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

    • 0