I have written a small function that creates jdbc connection in python using jaydeebe api/module/library. I have tested it on my personal laptop which is a windows env and it created the connection object successfully. When I moved the code to my other laptop which is a macOS env and tried to do the same, I ran into this error. Anyways, here's all the information that I think matters, feel free to request more information if you think that may give more insights.
Code:
conn = jaydebeapi.connect(
properties['driverName'],
properties['url'],
[properties['username'], properties['password']],
driver
)
logger.info("Connection created successfully")
Error:
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGBUS (0xa) at pc=0x0000000106f02b18, pid=35834, tid=0x0000000000000103
#
# JRE version: (8.0_431) (build )
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.431-b10 mixed mode bsd-aarch64 compressed oops)
# Problematic frame:
# V [libjvm.dylib+0x23ab18] CodeHeap::allocate(unsigned long, bool)+0xe8
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /Users/abhinav/Workspace/hs_err_pid35834.log
#
# If you would like to submit a bug report, please visit:
# http://bugreport.java.com/bugreport/crash.jsp
Okay found the answer by trying to rerun the same on windows env. The problem was that the driver
variable pointing to a wrong location. The same when ran on a windows env clearly pointed out the error with the variable pointing to a wrong location, whereas in macOS it gave the SIGBUS error which is really hard to understand (at least for me).