# Seg fault on python client

**URL:** <https://discuss.aerospike.com/t/seg-fault-on-python-client/2374>\
**Category:** General Discussion\
**Tags:** udf\
**Created:** [January 11, 2016, 5:49pm UTC](https://discuss.aerospike.com/t/seg-fault-on-python-client/2374 "2016-01-11T17:49:37Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mkrtich\_Soghomonyan](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/mkrtich_soghomonyan/32/426_2.png) [@Mkrtich\_Soghomonyan](https://discuss.aerospike.com/u/Mkrtich_Soghomonyan)\
**Post date:** [January 11, 2016, 5:49pm UTC](https://discuss.aerospike.com/t/seg-fault-on-python-client/2374/1 "2016-01-11T17:49:37Z")

</div>

Hi the following code in python results in segmentation fault.

```
import aerospike
AEROSPIKE_CONFIG = {'hosts': []} # no host provided
c = aerospike.client(AEROSPIKE_CONFIG).connect()
c.udf_put("some_existing_file.lua")

```

I guess in the udf\_put there is no check if the connection is valid.

---

<div class="post-metadata">

**Author:** ![rbotzer](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/rbotzer/32/2114_2.png) [@rbotzer](https://discuss.aerospike.com/u/rbotzer)\
**Post date:** [January 11, 2016, 6:30pm UTC](https://discuss.aerospike.com/t/seg-fault-on-python-client/2374/2 "2016-01-11T18:30:38Z")

</div>

If you checked `c.is_connected` after the `connect()` you’d see that it isn’t. That’s the safe thing to do. Thanks for reporting the segfault. I’ll open a ticket for that bug.
