Closed olemke closed 4 years ago
Access to an uninitialized user created variable is not caught by the API.
from typhon.arts.workspace import Workspace # from arts.workspace import Workspace ws = Workspace() ws.IndexCreate("myindex") print("1st try:") print(ws.myindex.value) ws.Print(ws.myindex, 0) print("2nd try:") ws = Workspace() print(ws.myindex.value) ws.Print(ws.myindex, 0)
1st try: 8070450532247928832 - Print 8070450532247928832 2nd try: Traceback (most recent call last): File "./uninitialized-user-var.py", line 16, in <module> print(ws.myindex.value) File "/Users/u237002/Hacking/git/typhon/typhon/arts/workspace/variables.py", line 281, in value raise Exception("WorkspaceVariable " + self.name + " is uninitialized.") Exception: WorkspaceVariable myindex is uninitialized.
Already on the 1st try, the Exception should be thrown.
ARTS interface has been migrated to ARTS.
Bug report
Bug summary
Access to an uninitialized user created variable is not caught by the API.
Code for reproduction
Actual outcome
Expected outcome
Already on the 1st try, the Exception should be thrown.
Version information