KX Community

Find answers, ask questions, and connect with our KX Community around the world.
KX Community Guidelines

Home Forums PyKX Multiprocessing with pykx hanging on trying to load db from disk

Tagged: 

  • Multiprocessing with pykx hanging on trying to load db from disk

    Posted by milk on January 2, 2025 at 8:00 pm

    Hi,

    I’m starting up a new process using multiprocess in python, where I feed in multithreading.queue into a custom function

     p = multithreading.Process(target=function, args=(queue,))

     p.start()

    However, in my function in the new process, I try to load a db using

    pykx.DB(path=”/home/user/test”)

    and this query hangs.  I can run other simple queries, but it seems the call to system loading a path doesn’t work.

    Is there something preventing pykx from using system functions in a separate process?  If it matters i’m using pykx 2.5.2 (with beta features enabled).  If I try this in the main process it works fine.

    • This discussion was modified 3 days, 23 hours ago by  milk.
    milk replied 1 hour, 14 minutes ago 2 Members · 2 Replies
  • 2 Replies
  • rocuinneagain

    Member
    January 6, 2025 at 3:10 pm

    What OS are you using?

    PyKX does not support multiprocessing on Windows.

    See also: Multithreaded Execution – PyKX

    • milk

      Member
      January 6, 2025 at 6:11 pm

      linux (centos)

      The link you provided is about multithreading?  Not multiprocessing? 

      • This reply was modified 1 hour, 7 minutes ago by  milk.

Log in to reply.