示例#1
0
def prStock(mypipe):
    shutdown = False
    st = Stock()
    while not shutdown:
        if not st.doWork():
            time.sleep(1)
        if mypipe.poll():
            shutdown = mypipe.recv()
示例#2
0
文件: core2.py 项目: sridwan/meong
def prStock():
    global core2log
    shutdown = False
    st = Stock()
    while not shutdown:
        try:
            if not st.doWork():
                time.sleep(1)
        except:
            errorstr = traceback.format_exc()
            print errorstr
            core2log.error('<Stock>\n{0}'.format(errorstr))
            raw_input()