Uploaded image for project: 'Livy'
  1. Livy
  2. LIVY-795

Can't work with PySpark with Python >= 3.8 due to https://bugs.python.org/issue35894

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Blocker
    • Resolution: Unresolved
    • Affects Version/s: 0.7.0
    • Fix Version/s: None
    • Component/s: REPL
    • Labels:
    • Environment:
      EMR 6.1.0

      Description

       

      When working with PySpark with Python >= 3.8, below error is raised:

      TypeError: required field "type_ignores" missing from Module

      The error points to code in https://github.com/apache/incubator-livy/blob/4d8a912699683b973eee76d4e91447d769a0cb0d/repl/src/main/resources/fake_shell.py#L223

       

      The error is caused by an API change in Python 3.8: https://github.com/python/cpython/pull/11645/files and was reported here https://bugs.python.org/issue35894

      IPython has faced similar issue: https://github.com/ipython/ipython/issues/11590

      IPython solved the issue in this PR: https://github.com/ipython/ipython/pull/11593  

       

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              shiquanwang Shiquan Wang
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 20m
                20m