hch
2018-12-27 affca29e7500fc8e2e65cf15d19496a370f6329e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#!/usr/bin/python
# -*- coding: GBK -*-
#
# @todo: 
#
# @author: Alee
# @date 2017-12-21 ÏÂÎç04:53:56
# @version 1.0
#
# @note: 
#
#---------------------------------------------------------------------
HaveDEBUG = False
 
 
#³õʼ»¯LogÄ£¿é
import logging
#import gc
from Utils.mylog import InitMyLog
import time
import os
import traceback
import sys
 
 
logname = ""
if len(sys.argv) == 2:
    logname = sys.argv[1]
if HaveDEBUG:
    #gc.set_debug(gc.DEBUG_LEAK)
    InitMyLog("RobotTest%s"%logname, True, logging.DEBUG)
else:
    #gc.set_debug(gc.DEBUG_LEAK)
    #gc.disable()
    InitMyLog("RobotTest%s"%logname, True, logging.INFO)
 
 
from framework.frame import StartApp
 
 
 
 
VERSION = "1.0.0"
BUILD_DATE = "2017-12-21"
 
 
 
 
if __name__ == "__main__":
    try:
 
        logging.info("InsideRobot %s %s" % (VERSION, BUILD_DATE))
        PyBaseRoot = os.getcwd() + "\\"
        logging.debug("Main: %s" % os.getcwd())
 
        StartApp(PyBaseRoot)
    except Exception, e:
        print str(e)
        print traceback.print_exc()
        logging.error(str(e))
        logging.error(traceback.print_exc())