Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-8889

[Python] Python 3.7 SIGSEGV when comparing RecordBatch to None

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 0.15.1, 0.17.1
    • 1.0.0
    • Python

    Description

      This seems to only happen for Python 3.6 and 3.7. It doesn't happen with 3.8. It seems to happen even when built from source, but I used the wheels for this reproduction.

      > uname -a
      Linux chaconne 5.6.13-arch1-1 #1 SMP PREEMPT Thu, 14 May 2020 06:52:53 +0000 x86_64 GNU/Linux
      > python --version
      Python 3.7.7
      > pip freeze
      numpy==1.18.4
      pyarrow==0.17.1

      Reproduction:

      import pyarrow as pa
      table = pa.Table.from_arrays([pa.array([1,2,3])], names=["a"])
      batches = table.to_batches()
      batches[0].equals(None)
      
      #0  0x00007fffdf9d34f0 in arrow::RecordBatch::num_columns() const () from /home/lidavidm/Code/twosigma/arrow/venv2/lib/python3.7/site-packages/pyarrow/libarrow.so.17
      #1  0x00007fffdf9d69e9 in arrow::RecordBatch::Equals(arrow::RecordBatch const&, bool) const () from /home/lidavidm/Code/twosigma/arrow/venv2/lib/python3.7/site-packages/pyarrow/libarrow.so.17
      #2  0x00007fffe084a6e0 in __pyx_pw_7pyarrow_3lib_11RecordBatch_31equals(_object*, _object*, _object*) () from /home/lidavidm/Code/twosigma/arrow/venv2/lib/python3.7/site-packages/pyarrow/lib.cpython-37m-x86_64-linux-gnu.so
      #3  0x00005555556b97e4 in _PyMethodDef_RawFastCallKeywords (method=0x7fffe0c1b760 <__pyx_methods_7pyarrow_3lib_RecordBatch+288>, self=0x7fffdefd7110, args=0x7ffff786f5c8, nargs=<optimized out>, kwnames=<optimized out>)
          at /tmp/build/80754af9/python_1585000375785/work/Objects/call.c:694
      #4  0x00005555556c06af in _PyMethodDescr_FastCallKeywords (descrobj=0x7fffdefa4050, args=0x7ffff786f5c0, nargs=2, kwnames=0x0) at /tmp/build/80754af9/python_1585000375785/work/Objects/descrobject.c:288
      #5  0x0000555555724add in call_function (kwnames=0x0, oparg=2, pp_stack=<synthetic pointer>) at /tmp/build/80754af9/python_1585000375785/work/Python/ceval.c:4593
      #6  _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at /tmp/build/80754af9/python_1585000375785/work/Python/ceval.c:3110
      #7  0x0000555555669289 in _PyEval_EvalCodeWithName (_co=0x7ffff78a68a0, globals=<optimized out>, locals=<optimized out>, args=<optimized out>, argcount=<optimized out>, kwnames=0x0, kwargs=0x0, kwcount=<optimized out>, kwstep=2, 
          defs=0x0, defcount=0, kwdefs=0x0, closure=0x0, name=0x0, qualname=0x0) at /tmp/build/80754af9/python_1585000375785/work/Python/ceval.c:3930
      #8  0x000055555566a1c4 in PyEval_EvalCodeEx (_co=<optimized out>, globals=<optimized out>, locals=<optimized out>, args=<optimized out>, argcount=<optimized out>, kws=<optimized out>, kwcount=0, defs=0x0, defcount=0, kwdefs=0x0, 
          closure=0x0) at /tmp/build/80754af9/python_1585000375785/work/Python/ceval.c:3959
      #9  0x000055555566a1ec in PyEval_EvalCode (co=<optimized out>, globals=<optimized out>, locals=<optimized out>) at /tmp/build/80754af9/python_1585000375785/work/Python/ceval.c:524
      #10 0x0000555555780cb4 in run_mod (mod=<optimized out>, filename=<optimized out>, globals=0x7ffff78d7c30, locals=0x7ffff78d7c30, flags=<optimized out>, arena=<optimized out>)
          at /tmp/build/80754af9/python_1585000375785/work/Python/pythonrun.c:1035
      #11 0x000055555578b0d1 in PyRun_FileExFlags (fp=0x5555558c24d0, filename_str=<optimized out>, start=<optimized out>, globals=0x7ffff78d7c30, locals=0x7ffff78d7c30, closeit=1, flags=0x7fffffffe1b0)
          at /tmp/build/80754af9/python_1585000375785/work/Python/pythonrun.c:988
      #12 0x000055555578b2c3 in PyRun_SimpleFileExFlags (fp=0x5555558c24d0, filename=<optimized out>, closeit=1, flags=0x7fffffffe1b0) at /tmp/build/80754af9/python_1585000375785/work/Python/pythonrun.c:429
      #13 0x000055555578c3f5 in pymain_run_file (p_cf=0x7fffffffe1b0, filename=0x5555558e51f0 L"repro.py", fp=0x5555558c24d0) at /tmp/build/80754af9/python_1585000375785/work/Modules/main.c:462
      #14 pymain_run_filename (cf=0x7fffffffe1b0, pymain=0x7fffffffe2c0) at /tmp/build/80754af9/python_1585000375785/work/Modules/main.c:1641
      #15 pymain_run_python (pymain=0x7fffffffe2c0) at /tmp/build/80754af9/python_1585000375785/work/Modules/main.c:2902
      #16 pymain_main (pymain=0x7fffffffe2c0) at /tmp/build/80754af9/python_1585000375785/work/Modules/main.c:3442
      #17 0x000055555578c51c in _Py_UnixMain (argc=<optimized out>, argv=<optimized out>) at /tmp/build/80754af9/python_1585000375785/work/Modules/main.c:3477
      #18 0x00007ffff7dcd002 in __libc_start_main () from /usr/lib/libc.so.6
      #19 0x000055555572fac0 in _start () at ../sysdeps/x86_64/elf/start.S:103
      

      Attachments

        Issue Links

          Activity

            People

              lidavidm David Li
              lidavidm David Li
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

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