<type 'exceptions.UnboundLocalError'> | Python 2.7.12: /usr/bin/python Sat Nov 9 10:49:28 2024 |
A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.
/home/sandbox/public_html/cgi-bin/Story01.py in |
510 |
511 displayData( db, project, account, pwd, node, NetworkLimit ) |
512 |
513 |
=> 514 main() |
main = <function main> |
/home/sandbox/public_html/cgi-bin/Story01.py in main() |
509 if ( NetworkLimit < 1 ): NetworkLimit = 100 |
510 |
=> 511 displayData( db, project, account, pwd, node, NetworkLimit ) |
512 |
513 |
global displayData = <function displayData>, db = 'hanyang2023', project = 'hanyang', account = 'guest', pwd = 'guest', node = 'E2022-R3-04E ', NetworkLimit = 100 |
/home/sandbox/public_html/cgi-bin/Story01.py in displayData(database='hanyang2023', project='hanyang', account='guest', password='guest', node='E2022-R3-04E ', NetworkLimit=100) |
483 |
484 if( count <= NetworkLimit ): |
=> 485 displayNetwork( nodelist, edgelist, database, project, account, password, node ) |
486 else: |
487 displayList( nodelist, edgelist, database, project, account, password, node ) |
global displayNetwork = <function displayNetwork>, nodelist = [{'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/sundial.png', 'id': u'\uada4\uc2dd', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uada4\uc2dd', 'label': u'\uada4\uc2dd(\u994b\u98df)'}, {'class': u'Object', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/tree.png', 'id': u'\uc465\uacfc_\uc11c\uc9c1', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc465\uacfc_\uc11c\uc9c1', 'label': u'\uc465\uacfc_\uc11c\uc9c1(\uc465\uacfc_\u9ecd\u7a37)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'label': u'\uacf5\uc2e0\ub2f9(\u529f\u81e3\u5802)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uce60\uc0ac\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uce60\uc0ac\ub2f9', 'label': u'\uc885\ubb18 \uce60\uc0ac\ub2f9(\u4e03\u7940\u5802)'}, {'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/concept2.png', 'id': u'\uc9c4\ucc2c', 'infoUrl': None, 'label': u'\uc9c4\ucc2c(\u9032\u994c)'}, {'class': u'Food', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/2022/3D\uc74c\uc2dd/\uc74c\uc2dd-087_\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219.png', 'id': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'label': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219(\u85a6\u4fce-\u725b\u719f \u7f8a\u719f \u8c55\u719f)'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04D', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04D', 'label': u'\uc2e0\uad00\ub840 \ub54c \uc4f0\ub294 \ud5a5\uacfc \uc220'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04E', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04E', 'label': u'\uc9c4\ucc2c\uacfc \uada4\uc2dd'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/storyline.png', 'id': u'S2022-R3-04 ', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/S2022-R3-04', 'label': u'\uc885\ubb18\uc81c\ub840\uc758 \uc21c\uc11c'}], edgelist = [{'attribute': None, 'relation': u'isRelatedTo', 'source': u'\uc465\uacfc_\uc11c\uc9c1', 'target': u'\uada4\uc2dd'}, {'attribute': None, 'relation': u'isPreviousInSequenceTo', 'source': u'E2022-R3-04D', 'target': u'E2022-R3-04E'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uada4\uc2dd'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc465\uacfc_\uc11c\uc9c1'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc885\ubb18_\uacf5\uc2e0\ub2f9'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc885\ubb18_\uce60\uc0ac\ub2f9'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc9c4\ucc2c'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219'}, {'attribute': u'\uc2e0\uad00\ub840 \ub54c \uc4f0\ub294 \ud5a5\uacfc \uc220', 'relation': u'hasPart', 'source': u'S2022-R3-04 ', 'target': u'E2022-R3-04D '}, {'attribute': u'\uc9c4\ucc2c\uacfc \uada4\uc2dd', 'relation': u'hasPart', 'source': u'S2022-R3-04 ', 'target': u'E2022-R3-04E '}], database = 'hanyang2023', project = 'hanyang', account = 'guest', password = 'guest', node = 'E2022-R3-04E ' |
/home/sandbox/public_html/cgi-bin/Story01.py in displayNetwork(nodelist=[{'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/sundial.png', 'id': u'\uada4\uc2dd', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uada4\uc2dd', 'label': u'\uada4\uc2dd(\u994b\u98df)'}, {'class': u'Object', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/tree.png', 'id': u'\uc465\uacfc_\uc11c\uc9c1', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc465\uacfc_\uc11c\uc9c1', 'label': u'\uc465\uacfc_\uc11c\uc9c1(\uc465\uacfc_\u9ecd\u7a37)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'label': u'\uacf5\uc2e0\ub2f9(\u529f\u81e3\u5802)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uce60\uc0ac\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uce60\uc0ac\ub2f9', 'label': u'\uc885\ubb18 \uce60\uc0ac\ub2f9(\u4e03\u7940\u5802)'}, {'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/concept2.png', 'id': u'\uc9c4\ucc2c', 'infoUrl': None, 'label': u'\uc9c4\ucc2c(\u9032\u994c)'}, {'class': u'Food', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/2022/3D\uc74c\uc2dd/\uc74c\uc2dd-087_\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219.png', 'id': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'label': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219(\u85a6\u4fce-\u725b\u719f \u7f8a\u719f \u8c55\u719f)'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04D', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04D', 'label': u'\uc2e0\uad00\ub840 \ub54c \uc4f0\ub294 \ud5a5\uacfc \uc220'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04E', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04E', 'label': u'\uc9c4\ucc2c\uacfc \uada4\uc2dd'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/storyline.png', 'id': u'S2022-R3-04 ', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/S2022-R3-04', 'label': u'\uc885\ubb18\uc81c\ub840\uc758 \uc21c\uc11c'}], edgelist=[{'attribute': None, 'relation': u'isRelatedTo', 'source': u'\uc465\uacfc_\uc11c\uc9c1', 'target': u'\uada4\uc2dd'}, {'attribute': None, 'relation': u'isPreviousInSequenceTo', 'source': u'E2022-R3-04D', 'target': u'E2022-R3-04E'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uada4\uc2dd'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc465\uacfc_\uc11c\uc9c1'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc885\ubb18_\uacf5\uc2e0\ub2f9'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc885\ubb18_\uce60\uc0ac\ub2f9'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\uc9c4\ucc2c'}, {'attribute': None, 'relation': u'isRelatedTo', 'source': u'E2022-R3-04E', 'target': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219'}, {'attribute': u'\uc2e0\uad00\ub840 \ub54c \uc4f0\ub294 \ud5a5\uacfc \uc220', 'relation': u'hasPart', 'source': u'S2022-R3-04 ', 'target': u'E2022-R3-04D '}, {'attribute': u'\uc9c4\ucc2c\uacfc \uada4\uc2dd', 'relation': u'hasPart', 'source': u'S2022-R3-04 ', 'target': u'E2022-R3-04E '}], database='hanyang2023', project='hanyang', account='guest', password='guest', node='E2022-R3-04E ') |
342 if not line: break |
343 if( '#YourData' == line.strip()): |
=> 344 printNodes( nodelist, database, project, account, password, node ) |
345 printLinks( edgelist, node, account ) |
346 else: |
global printNodes = <function printNodes>, nodelist = [{'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/sundial.png', 'id': u'\uada4\uc2dd', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uada4\uc2dd', 'label': u'\uada4\uc2dd(\u994b\u98df)'}, {'class': u'Object', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/tree.png', 'id': u'\uc465\uacfc_\uc11c\uc9c1', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc465\uacfc_\uc11c\uc9c1', 'label': u'\uc465\uacfc_\uc11c\uc9c1(\uc465\uacfc_\u9ecd\u7a37)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'label': u'\uacf5\uc2e0\ub2f9(\u529f\u81e3\u5802)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uce60\uc0ac\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uce60\uc0ac\ub2f9', 'label': u'\uc885\ubb18 \uce60\uc0ac\ub2f9(\u4e03\u7940\u5802)'}, {'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/concept2.png', 'id': u'\uc9c4\ucc2c', 'infoUrl': None, 'label': u'\uc9c4\ucc2c(\u9032\u994c)'}, {'class': u'Food', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/2022/3D\uc74c\uc2dd/\uc74c\uc2dd-087_\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219.png', 'id': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'label': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219(\u85a6\u4fce-\u725b\u719f \u7f8a\u719f \u8c55\u719f)'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04D', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04D', 'label': u'\uc2e0\uad00\ub840 \ub54c \uc4f0\ub294 \ud5a5\uacfc \uc220'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04E', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04E', 'label': u'\uc9c4\ucc2c\uacfc \uada4\uc2dd'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/storyline.png', 'id': u'S2022-R3-04 ', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/S2022-R3-04', 'label': u'\uc885\ubb18\uc81c\ub840\uc758 \uc21c\uc11c'}], database = 'hanyang2023', project = 'hanyang', account = 'guest', password = 'guest', node = 'E2022-R3-04E ' |
/home/sandbox/public_html/cgi-bin/Story01.py in printNodes(nodelist=[{'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/sundial.png', 'id': u'\uada4\uc2dd', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uada4\uc2dd', 'label': u'\uada4\uc2dd(\u994b\u98df)'}, {'class': u'Object', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/tree.png', 'id': u'\uc465\uacfc_\uc11c\uc9c1', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc465\uacfc_\uc11c\uc9c1', 'label': u'\uc465\uacfc_\uc11c\uc9c1(\uc465\uacfc_\u9ecd\u7a37)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uacf5\uc2e0\ub2f9', 'label': u'\uacf5\uc2e0\ub2f9(\u529f\u81e3\u5802)'}, {'class': u'Architecture', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/architecture.png', 'id': u'\uc885\ubb18_\uce60\uc0ac\ub2f9', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\uc885\ubb18_\uce60\uc0ac\ub2f9', 'label': u'\uc885\ubb18 \uce60\uc0ac\ub2f9(\u4e03\u7940\u5802)'}, {'class': u'Concept', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/concept2.png', 'id': u'\uc9c4\ucc2c', 'infoUrl': None, 'label': u'\uc9c4\ucc2c(\u9032\u994c)'}, {'class': u'Food', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/2022/3D\uc74c\uc2dd/\uc74c\uc2dd-087_\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219.png', 'id': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219', 'label': u'\ucc9c\uc870-\uc6b0\uc219\uc591\uc219\uc2dc\uc219(\u85a6\u4fce-\u725b\u719f \u7f8a\u719f \u8c55\u719f)'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04D', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04D', 'label': u'\uc2e0\uad00\ub840 \ub54c \uc4f0\ub294 \ud5a5\uacfc \uc220'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/episode.png', 'id': u'E2022-R3-04E', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/E2022-R3-04E', 'label': u'\uc9c4\ucc2c\uacfc \uada4\uc2dd'}, {'class': u'Story', 'iconUrl': u'http://dh.aks.ac.kr/hanyang2/icon/storyline.png', 'id': u'S2022-R3-04 ', 'infoUrl': u'https://dh.aks.ac.kr/hanyang2/wiki/index.php/S2022-R3-04', 'label': u'\uc885\ubb18\uc81c\ub840\uc758 \uc21c\uc11c'}], database='hanyang2023', project='hanyang', account='guest', password='guest', subject='E2022-R3-04E ') |
225 |
226 #add show-all-story-nodes button |
=> 227 if( subjectClass == 'Story' ) : |
228 print " nodesArray.push({" |
229 print " id: 'switch1'," |
subjectClass undefined |
<type 'exceptions.UnboundLocalError'>: local variable 'subjectClass' referenced before assignment
args =
("local variable 'subjectClass' referenced before assignment",)
message =
"local variable 'subjectClass' referenced before assignment"