You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@arrow.apache.org by "dinse (via GitHub)" <gi...@apache.org> on 2025/06/06 15:02:39 UTC

[I] Skip test_gdb.py tests if PyArrow was built with non-debug build [arrow]

dinse opened a new issue, #46728:
URL: https://github.com/apache/arrow/issues/46728

   ### Describe the enhancement requested
   
   #12253 allowed test_gdb to skip if Arrow C++ had a non-debug build. If C++ _was_ built debug and PYARROW_BUILD_TYPE=debug is not set, PyArrow builds in release. pytest then attempts the full test_gdb suite because pa.cpp_build_info.build_type is 'debug'. All but a few gdb tests then fail.
   
   I think the gdb tests should skip in that scenario. If this change in behavior is agreed upon, I have a change that implements it prepared.
   
   ### Component(s)
   
   Python


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@arrow.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Python] Skip test_gdb.py tests if PyArrow was built with non-debug build [arrow]

Posted by "dinse (via GitHub)" <gi...@apache.org>.
dinse commented on issue #46728:
URL: https://github.com/apache/arrow/issues/46728#issuecomment-2952849817

   <details><summary>PyArrow release</summary>
   
   ```
   (pyarrow-dev) eric@Ubuntu:~/code2/arrow/python$ grep BUILD_TYPE build/temp.linux-x86_64-cpython-312/CMakeCache.txt 
   CMAKE_BUILD_TYPE:STRING=release
   (pyarrow-dev) eric@Ubuntu:~/code2/arrow/python$ python -m pytest pyarrow/tests/test_gdb.py
   ============================= test session starts ==============================
   platform linux -- Python 3.12.3, pytest-8.3.5, pluggy-1.6.0
   rootdir: /home/eric/code2/arrow/python
   configfile: setup.cfg
   plugins: hypothesis-6.132.0
   collected 21 items                                                             
    
   pyarrow/tests/test_gdb.py ..FFFFFFFFFFFFFFFFFFF                          [100%]
    
   =================================== FAILURES ===================================
   _________________________________ test_status __________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_status(gdb_arrow):
   >       check_stack_repr(gdb_arrow, "ok_status", "arrow::Status::OK()")
    
   pyarrow/tests/test_gdb.py:252: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'ok_status'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p ok_status
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "ok_status" in current context.
   ______________________________ test_buffer_stack _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_buffer_stack(gdb_arrow):
   >       check_stack_repr(gdb_arrow, "buffer_null",
                            "arrow::Buffer of size 0, read-only")
    
   pyarrow/tests/test_gdb.py:271: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'buffer_null'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p buffer_null
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "buffer_null" in current context.
   _______________________________ test_buffer_heap _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_buffer_heap(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "heap_buffer",
                           'arrow::Buffer of size 3, read-only, "abc"')
    
   pyarrow/tests/test_gdb.py:283: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*heap_buffer'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_buffer
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "heap_buffer" in current context.
   ________________________________ test_decimals _________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_decimals(gdb_arrow):
           v128 = "98765432109876543210987654321098765432"
   >       check_stack_repr(gdb_arrow, "decimal128_zero", "arrow::Decimal128(0)")
    
   pyarrow/tests/test_gdb.py:291: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'decimal128_zero'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p decimal128_zero
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "decimal128_zero" in current context.
   ________________________________ test_metadata _________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_metadata(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "empty_metadata.get()",
                           "arrow::KeyValueMetadata of size 0")
    
   pyarrow/tests/test_gdb.py:319: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*empty_metadata.get()'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *empty_metadata.get()
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "empty_metadata" in current context.
   _______________________________ test_types_stack _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_types_stack(gdb_arrow):
   >       check_stack_repr(gdb_arrow, "null_type", "arrow::null()")
    
   pyarrow/tests/test_gdb.py:328: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'null_type'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p null_type
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "null_type" in current context.
   _______________________________ test_types_heap ________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_types_heap(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "heap_null_type", "arrow::null()")
    
   pyarrow/tests/test_gdb.py:420: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*heap_null_type'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_null_type
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "heap_null_type" in current context.
   ______________________________ test_fields_stack _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_fields_stack(gdb_arrow):
   >       check_stack_repr(gdb_arrow, "int_field",
                            'arrow::field("ints", arrow::int64())')
    
   pyarrow/tests/test_gdb.py:458: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'int_field'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p int_field
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "int_field" in current context.
   _______________________________ test_fields_heap _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_fields_heap(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "heap_int_field",
                           'arrow::field("ints", arrow::int64())')
    
   pyarrow/tests/test_gdb.py:466: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*heap_int_field'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_int_field
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "heap_int_field" in current context.
   ______________________________ test_scalars_stack ______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_scalars_stack(gdb_arrow):
   >       check_stack_repr(gdb_arrow, "null_scalar", "arrow::NullScalar")
    
   pyarrow/tests/test_gdb.py:471: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'null_scalar'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p null_scalar
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "null_scalar" in current context.
   ______________________________ test_scalars_heap _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_scalars_heap(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "heap_null_scalar", "arrow::NullScalar")
    
   pyarrow/tests/test_gdb.py:731: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*heap_null_scalar'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_null_scalar
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "heap_null_scalar" in current context.
   _______________________________ test_array_data ________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_array_data(gdb_arrow):
   >       check_stack_repr(
               gdb_arrow, "int32_array_data",
               ("arrow::ArrayData of type arrow::int32(), length 4, offset 0, "
                "null count 1 = {[0] = -5, [1] = 6, [2] = null, [3] = 42}"))
    
   pyarrow/tests/test_gdb.py:754: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'int32_array_data'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p int32_array_data
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "int32_array_data" in current context.
   ______________________________ test_arrays_stack _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_arrays_stack(gdb_arrow):
   >       check_stack_repr(
               gdb_arrow, "int32_array",
               ("arrow::Int32Array of length 4, offset 0, null count 1 = "
                "{[0] = -5, [1] = 6, [2] = null, [3] = 42}"))
    
   pyarrow/tests/test_gdb.py:761: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'int32_array'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p int32_array
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "int32_array" in current context.
   _______________________________ test_arrays_heap _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_arrays_heap(gdb_arrow):
           # Null
   >       check_heap_repr(
               gdb_arrow, "heap_null_array",
               "arrow::NullArray of length 2, offset 0, null count 2")
    
   pyarrow/tests/test_gdb.py:773: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*heap_null_array'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_null_array
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "heap_null_array" in current context.
   _________________________________ test_schema __________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_schema(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "schema_empty",
                           "arrow::Schema with 0 fields")
    
   pyarrow/tests/test_gdb.py:1009: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*schema_empty'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *schema_empty
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "schema_empty" in current context.
   ______________________________ test_chunked_array ______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_chunked_array(gdb_arrow):
   >       check_stack_repr(
               gdb_arrow, "chunked_array",
               ("arrow::ChunkedArray of type arrow::int32(), length 5, null count 1 "
                "with 2 chunks = {[0] = length 2, offset 0, null count 0, "
                "[1] = length 3, offset 0, null count 1}"))
    
   pyarrow/tests/test_gdb.py:1022: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'chunked_array'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p chunked_array
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "chunked_array" in current context.
   ______________________________ test_record_batch _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_record_batch(gdb_arrow):
           expected_prefix = 'arrow::RecordBatch with 2 columns, 3 rows'
           expected_suffix = (
               '{["ints"] = arrow::ArrayData of type arrow::int32(), '
               'length 3, offset 0, null count 0 = '
               '{[0] = 1, [1] = 2, [2] = 3}, '
               '["strs"] = arrow::ArrayData of type arrow::utf8(), '
               'length 3, offset 0, null count 1 = '
               '{[0] = "abc", [1] = null, [2] = "def"}}')
    
           expected = f"{expected_prefix} = {expected_suffix}"
           # Representations may differ between those two because of
           # RecordBatch (base class) vs. SimpleRecordBatch (concrete class).
   >       check_heap_repr(gdb_arrow, "batch", expected)
    
   pyarrow/tests/test_gdb.py:1042: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*batch'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *batch
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "batch" in current context.
   __________________________________ test_table __________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_table(gdb_arrow):
           expected_table = (
               'arrow::Table with 2 columns, 5 rows = {'
               '["ints"] = arrow::ChunkedArray of type arrow::int32(), '
               'length 5, null count 0 with 2 chunks = '
               '{[0] = length 3, offset 0, null count 0, '
               '[1] = length 2, offset 0, null count 0}, '
               '["strs"] = arrow::ChunkedArray of type arrow::utf8(), '
               'length 5, null count 1 with 3 chunks = '
               '{[0] = length 2, offset 0, null count 1, '
               '[1] = length 1, offset 0, null count 0, '
               '[2] = length 2, offset 0, null count 0}}')
    
           # Same as RecordBatch above (Table vs. SimpleTable)
   >       check_heap_repr(gdb_arrow, "table", expected_table)
    
   pyarrow/tests/test_gdb.py:1063: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = '*table'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *table
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "table" in current context.
   __________________________________ test_datum __________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
    
       def test_datum(gdb_arrow):
   >       check_stack_repr(gdb_arrow, "empty_datum", "arrow::Datum (empty)")
    
   pyarrow/tests/test_gdb.py:1068: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:234: in check_stack_repr
       s = gdb.print_value(expr)
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x78f8282d8650>
   expr = 'empty_datum'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p empty_datum
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   No symbol "empty_datum" in current context.
   =========================== short test summary info ============================
   FAILED pyarrow/tests/test_gdb.py::test_status - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_buffer_stack - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_buffer_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_decimals - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_metadata - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_types_stack - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_types_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_fields_stack - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_fields_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_scalars_stack - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_scalars_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_array_data - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_arrays_stack - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_arrays_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_schema - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_chunked_array - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_record_batch - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_table - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_datum - AssertionError: 
   ======================== 19 failed, 2 passed in 29.64s =========================
   ```
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Python] Skip test_gdb.py tests if PyArrow was built with non-debug build [arrow]

Posted by "kou (via GitHub)" <gi...@apache.org>.
kou commented on issue #46728:
URL: https://github.com/apache/arrow/issues/46728#issuecomment-2953154527

   Thanks. Could you open a PR?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Python] Skip test_gdb.py tests if PyArrow was built with non-debug build [arrow]

Posted by "kou (via GitHub)" <gi...@apache.org>.
kou commented on issue #46728:
URL: https://github.com/apache/arrow/issues/46728#issuecomment-2951143547

   In general, +1 for this. But could you share the failed test logs?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Python] Skip test_gdb.py tests if PyArrow was built with non-debug build [arrow]

Posted by "pitrou (via GitHub)" <gi...@apache.org>.
pitrou closed issue #46728: [Python] Skip test_gdb.py tests if PyArrow was built with non-debug build
URL: https://github.com/apache/arrow/issues/46728


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Python] Skip test_gdb.py tests if PyArrow was built with non-debug build [arrow]

Posted by "dinse (via GitHub)" <gi...@apache.org>.
dinse commented on issue #46728:
URL: https://github.com/apache/arrow/issues/46728#issuecomment-2952846141

   <details><summary>PyArrow relwithdebinfo</summary>
   
   ```
   (pyarrow-dev) eric@Ubuntu:~/code2/arrow/python$ grep BUILD_TYPE build/temp.linux-x86_64-cpython-312/CMakeCache.txt 
   CMAKE_BUILD_TYPE:STRING=relwithdebinfo
    
   (pyarrow-dev) eric@Ubuntu:~/code2/arrow/python$ python -m pytest pyarrow/tests/test_gdb.py
   ============================= test session starts ==============================
   platform linux -- Python 3.12.3, pytest-8.3.5, pluggy-1.6.0
   rootdir: /home/eric/code2/arrow/python
   configfile: setup.cfg
   plugins: hypothesis-6.132.0
   collected 21 items                                                             
    
   pyarrow/tests/test_gdb.py ....FF..F...F.FF.....                          [100%]
    
   =================================== FAILURES ===================================
   _______________________________ test_buffer_heap _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
    
       def test_buffer_heap(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "heap_buffer",
                           'arrow::Buffer of size 3, read-only, "abc"')
    
   pyarrow/tests/test_gdb.py:283: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
   expr = '*heap_buffer'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_buffer
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   Attempt to take address of value not located in memory.
   ________________________________ test_decimals _________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
    
       def test_decimals(gdb_arrow):
           v128 = "98765432109876543210987654321098765432"
   >       check_stack_repr(gdb_arrow, "decimal128_zero", "arrow::Decimal128(0)")
    
   pyarrow/tests/test_gdb.py:291: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   gdb = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
   expr = 'decimal128_zero', expected = 'arrow::Decimal128(0)'
    
       def check_stack_repr(gdb, expr, expected):
           """
           Check printing a stack-located value.
           """
           s = gdb.print_value(expr)
           if isinstance(expected, re.Pattern):
               assert expected.match(s), s
           else:
   >           assert s == expected
   E           AssertionError: assert '<optimized out>' == 'arrow::Decimal128(0)'
   E             
   E             - arrow::Decimal128(0)
   E             + <optimized out>
    
   pyarrow/tests/test_gdb.py:238: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p decimal128_zero
   $12 = <optimized out>
   (gdb) 
   _______________________________ test_types_heap ________________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
    
       def test_types_heap(gdb_arrow):
   >       check_heap_repr(gdb_arrow, "heap_null_type", "arrow::null()")
    
   pyarrow/tests/test_gdb.py:420: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
   expr = '*heap_null_type'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_null_type
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   Attempt to take address of value not located in memory.
   ______________________________ test_scalars_heap _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
    
       def test_scalars_heap(gdb_arrow):
           check_heap_repr(gdb_arrow, "heap_null_scalar", "arrow::NullScalar")
   >       check_heap_repr(gdb_arrow, "heap_bool_scalar",
                           "arrow::BooleanScalar of value true")
    
   pyarrow/tests/test_gdb.py:732: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
   expr = '*heap_bool_scalar'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_null_scalar
   $134 = arrow::NullScalar
   (gdb) p *heap_bool_scalar
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   Attempt to take address of value not located in memory.
   ______________________________ test_arrays_stack _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
    
       def test_arrays_stack(gdb_arrow):
   >       check_stack_repr(
               gdb_arrow, "int32_array",
               ("arrow::Int32Array of length 4, offset 0, null count 1 = "
                "{[0] = -5, [1] = 6, [2] = null, [3] = 42}"))
    
   pyarrow/tests/test_gdb.py:761: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   gdb = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
   expr = 'int32_array'
   expected = 'arrow::Int32Array of length 4, offset 0, null count 1 = {[0] = -5, [1] = 6, [2] = null, [3] = 42}'
    
       def check_stack_repr(gdb, expr, expected):
           """
           Check printing a stack-located value.
           """
           s = gdb.print_value(expr)
           if isinstance(expected, re.Pattern):
               assert expected.match(s), s
           else:
   >           assert s == expected
   E           AssertionError: assert '<optimized out>' == 'arrow::Int32...ll, [3] = 42}'
   E             
   E             - arrow::Int32Array of length 4, offset 0, null count 1 = {[0] = -5, [1] = 6, [2] = null, [3] = 42}
   E             + <optimized out>
    
   pyarrow/tests/test_gdb.py:238: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p int32_array
   $136 = <optimized out>
   (gdb) 
   _______________________________ test_arrays_heap _______________________________
    
   gdb_arrow = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
    
       def test_arrays_heap(gdb_arrow):
           # Null
           check_heap_repr(
               gdb_arrow, "heap_null_array",
               "arrow::NullArray of length 2, offset 0, null count 2")
    
           # Primitive
           check_heap_repr(
               gdb_arrow, "heap_int32_array",
               ("arrow::Int32Array of length 4, offset 0, null count 1 = {"
                "[0] = -5, [1] = 6, [2] = null, [3] = 42}"))
           check_heap_repr(
               gdb_arrow, "heap_int32_array_no_nulls",
               ("arrow::Int32Array of length 4, offset 0, null count 0 = {"
                "[0] = -5, [1] = 6, [2] = 3, [3] = 42}"))
           check_heap_repr(
               gdb_arrow, "heap_int32_array_sliced_1_9",
               ("arrow::Int32Array of length 9, offset 1, unknown null count = {"
                "[0] = 2, [1] = -3, [2] = 4, [3] = null, [4] = -5, [5] = 6, "
                "[6] = -7, [7] = 8, [8] = null}"))
           check_heap_repr(
               gdb_arrow, "heap_int32_array_sliced_2_6",
               ("arrow::Int32Array of length 6, offset 2, unknown null count = {"
                "[0] = -3, [1] = 4, [2] = null, [3] = -5, [4] = 6, [5] = -7}"))
           check_heap_repr(
               gdb_arrow, "heap_int32_array_sliced_8_4",
               ("arrow::Int32Array of length 4, offset 8, unknown null count = {"
                "[0] = 8, [1] = null, [2] = -9, [3] = -10}"))
           check_heap_repr(
               gdb_arrow, "heap_int32_array_sliced_empty",
               "arrow::Int32Array of length 0, offset 6, unknown null count")
    
           check_heap_repr(
               gdb_arrow, "heap_double_array",
               ("arrow::DoubleArray of length 2, offset 0, null count 1 = {"
                "[0] = -1.5, [1] = null}"))
   >       check_heap_repr(
               gdb_arrow, "heap_float16_array",
               ("arrow::HalfFloatArray of length 2, offset 0, null count 0 = {"
                "[0] = 0.0, [1] = -1.5}"))
    
   pyarrow/tests/test_gdb.py:807: 
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
   pyarrow/tests/test_gdb.py:245: in check_heap_repr
       s = gdb.print_value(f"*{expr}")
   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
    
   self = <pyarrow.tests.test_gdb.GdbSession object at 0x7c9693e23aa0>
   expr = '*heap_float16_array'
    
       def print_value(self, expr):
           """
           Ask gdb to print the value of an expression and return the result.
           """
           out = self.run_command(f"p {expr}")
           out, n = re.subn(r"^\$\d+ = ", "", out)
   >       assert n == 1, out
   E       AssertionError: 
   E       assert 0 == 1
    
   pyarrow/tests/test_gdb.py:146: AssertionError
   ----------------------------- Captured stdout call -----------------------------
   p *heap_null_array
   $137 = arrow::NullArray of length 2, offset 0, null count 2
   (gdb) p *heap_int32_array
   $138 = arrow::Int32Array of length 4, offset 0, null count 1 = {[0] = -5, [1] = 6, [2] = null, [3] = 42}
   (gdb) p *heap_int32_array_no_nulls
   $139 = arrow::Int32Array of length 4, offset 0, null count 0 = {[0] = -5, [1] = 6, [2] = 3, [3] = 42}
   (gdb) p *heap_int32_array_sliced_1_9
   $140 = arrow::Int32Array of length 9, offset 1, unknown null count = {[0] = 2, [1] = -3, [2] = 4, [3] = null, [4] = -5, [5] = 6, [6] = -7, [7] = 8, [8] = null}
   (gdb) p *heap_int32_array_sliced_2_6
   $141 = arrow::Int32Array of length 6, offset 2, unknown null count = {[0] = -3, [1] = 4, [2] = null, [3] = -5, [4] = 6, [5] = -7}
   (gdb) p *heap_int32_array_sliced_8_4
   $142 = arrow::Int32Array of length 4, offset 8, unknown null count = {[0] = 8, [1] = null, [2] = -9, [3] = -10}
   (gdb) p *heap_int32_array_sliced_empty
   $143 = arrow::Int32Array of length 0, offset 6, unknown null count
   (gdb) p *heap_double_array
   $144 = arrow::DoubleArray of length 2, offset 0, null count 1 = {[0] = -1.5, [1] = null}
   (gdb) p *heap_float16_array
   (gdb) 
   ----------------------------- Captured stderr call -----------------------------
   Attempt to take address of value not located in memory.
   =========================== short test summary info ============================
   FAILED pyarrow/tests/test_gdb.py::test_buffer_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_decimals - AssertionError: assert '<optimized out>' == 'arrow::Decimal128(0)'
   FAILED pyarrow/tests/test_gdb.py::test_types_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_scalars_heap - AssertionError: 
   FAILED pyarrow/tests/test_gdb.py::test_arrays_stack - AssertionError: assert '<optimized out>' == 'arrow::Int32...ll, [3] = 42}'
   FAILED pyarrow/tests/test_gdb.py::test_arrays_heap - AssertionError: 
   ======================== 6 failed, 15 passed in 48.64s =========================
   ```
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Python] Skip test_gdb.py tests if PyArrow was built with non-debug build [arrow]

Posted by "pitrou (via GitHub)" <gi...@apache.org>.
pitrou commented on issue #46728:
URL: https://github.com/apache/arrow/issues/46728#issuecomment-3074269084

   Issue resolved by pull request 46755
   https://github.com/apache/arrow/pull/46755


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org