개정판 d5770d76
issue #000: add line clear opc test
Change-Id: I24583c3b9150d305f49b0544460f8146a197a514
DTI_PID/DTI_PID/LineNoTracer.py | ||
---|---|---|
581 | 581 |
message = 'error occurred({}) in {}:{}'.format(repr(ex), sys.exc_info()[-1].tb_frame.f_code.co_filename, |
582 | 582 |
sys.exc_info()[-1].tb_lineno) |
583 | 583 |
worker.display_message.emit(message) |
584 |
|
|
585 |
# clear line |
|
586 |
for line in lines: |
|
587 |
try: |
|
588 |
line.clear_attr_and_assoc_item() |
|
589 |
except Exception as ex: |
|
590 |
message = 'error occurred({}) in {}:{}'.format(repr(ex), sys.exc_info()[-1].tb_frame.f_code.co_filename, |
|
591 |
sys.exc_info()[-1].tb_lineno) |
|
592 |
worker.display_message.emit(message) |
|
584 | 593 |
|
585 | 594 |
""" try to connect label to valve """ |
586 | 595 |
labels = [symbol for symbol in symbols if symbol.iType == 19] # Labels - Symbol => Instrument |
... | ... | |
651 | 660 |
for symbol in symbols: |
652 | 661 |
try: |
653 | 662 |
if symbol.iType == 18 or symbol.iType == 31: |
654 |
pass |
|
655 |
#symbol.connectAttribute(texts) |
|
663 |
symbol.connectAttribute(texts) |
|
656 | 664 |
except Exception as ex: |
657 | 665 |
message = 'error occurred({}) in {}:{}'.format(repr(ex), sys.exc_info()[-1].tb_frame.f_code.co_filename, |
658 | 666 |
sys.exc_info()[-1].tb_lineno) |
minorTools/xmlTextSearcher.py | ||
---|---|---|
3 | 3 |
def finder(): |
4 | 4 |
print("finder start") |
5 | 5 |
|
6 |
targetText = ['>angle valve<']
|
|
7 |
path = 'W:\ID2_Project\CPChem\Temp'
|
|
6 |
targetText = ['>DE-SUPERHEATER']
|
|
7 |
path = 'W:\ID2_Project\RLPP\Temp'
|
|
8 | 8 |
|
9 | 9 |
print("target : " + str(len(targetText))) |
10 | 10 |
print("path : " + path) |
내보내기 Unified diff