Revision history  [back]

Python threads in PSSE

I tried to implement wxPython aplication with additional thread for calculations and update wxPython progress dialog within that thread. But psse crashes all the time.

So after that i tried to run really simple multithread python script in psse and it also caused psse crash. There is simple multithread psse script

import threading
import time

class TestThread(threading.Thread):
    def __init__(self):
        threading.Thread.__init__(self)

    def run(self):
        for i in range(0, 60, 3):
            print "T2: ", i
            time.sleep(3)

TestThread().start()
for i in range(0, 60, 2):
    print "T1: ", i
    time.sleep(1)

So my question is does psse allow to use threads in python script?

Python threads in PSSE

I tried to implement wxPython aplication with additional thread for calculations and update wxPython progress dialog within that thread. But psse crashes all the time.

So after that i tried to run really simple multithread python script in psse and it also caused psse crash. There is simple multithread psse script

import threading
import time

class TestThread(threading.Thread):
    def __init__(self):
        threading.Thread.__init__(self)

    def run(self):
        for i in range(0, 60, 3):
            print "T2: ", i
            time.sleep(3)

TestThread().start()

for i in range(0, 60, 2):
    print "T1: ", i
    time.sleep(1)

So my question is does psse allow to use threads in python script?

Python threads in PSSE

I tried to implement wxPython aplication with additional thread for calculations and update wxPython progress dialog within that thread. But psse crashes all the time.

So after that i tried to run really simple multithread python script in psse and it also caused psse crash. There is simple multithread psse script

`` import threading import time

class TestThread(threading.Thread): def init(self): threading.Thread.init(self)

import threading
import time

class TestThread(threading.Thread):
    def __init__run(self):
        threading.Thread.__init__(self)

    def run(self):
        for i in range(0, 60, 3):
            print "T2: ", i
            time.sleep(3)
TestThread().start()

for i in range(0, 60, 2):
    print "T1: ", i
    time.sleep(1)

TestThread().start()

for i in range(0, 60, 2): print "T1: ", i time.sleep(1) ``

So my question is does psse allow to use threads in python script?