[{"data":1,"prerenderedAt":1074},["ShallowReactive",2],{"doc-\u002Fglossary\u002Fwhat-is-an-exception-in-python":3},{"id":4,"title":5,"body":6,"description":1066,"extension":1067,"meta":1068,"navigation":1069,"path":1070,"seo":1071,"stem":1072,"__hash__":1073},"content\u002Fglossary\u002Fwhat-is-an-exception-in-python.md","What Is an Exception in Python?",{"type":7,"value":8,"toc":1048},"minimark",[9,13,22,29,32,56,61,64,144,147,156,159,187,191,194,211,217,233,241,245,248,268,271,328,357,382,441,445,448,483,492,495,558,560,569,572,589,603,607,610,630,633,654,657,661,664,677,680,694,704,708,711,746,749,778,781,813,817,820,837,840,844,847,862,865,887,894,909,912,928,934,951,954,958,963,966,970,978,982,985,989,1004,1008,1036,1044],[10,11,5],"h1",{"id":12},"what-is-an-exception-in-python",[14,15,16,17,21],"p",{},"An exception in Python is a problem that happens ",[18,19,20],"strong",{},"while your program is running",".",[14,23,24,25,28],{},"When an exception happens, Python usually stops the normal flow of the program and shows an error message. In many cases, you can also ",[18,26,27],{},"handle"," the exception so your program responds in a better way instead of crashing.",[14,30,31],{},"A simple way to think about it:",[33,34,35,39,42,45],"ul",{},[36,37,38],"li",{},"Your code starts running normally",[36,40,41],{},"Something unexpected happens",[36,43,44],{},"Python raises an exception",[36,46,47,48,52,53],{},"You can either let it stop the program or handle it with ",[49,50,51],"code",{},"try"," and ",[49,54,55],{},"except",[57,58,60],"h2",{"id":59},"a-quick-example","A quick example",[14,62,63],{},"Here is a small example of an exception being handled:",[65,66,71],"pre",{"className":67,"code":68,"language":69,"meta":70,"style":70},"language-python shiki shiki-themes material-theme-lighter github-light github-dark","try:\n    number = int(\"abc\")\nexcept ValueError:\n    print(\"That value cannot be converted to an integer\")\n","python","",[49,72,73,85,116,126],{"__ignoreMap":70},[74,75,78,81],"span",{"class":76,"line":77},"line",1,[74,79,51],{"class":80},"sVHd0",[74,82,84],{"class":83},"sP7_E",":\n",[74,86,88,92,96,100,103,107,111,113],{"class":76,"line":87},2,[74,89,91],{"class":90},"su5hD","    number ",[74,93,95],{"class":94},"smGrS","=",[74,97,99],{"class":98},"sZMiF"," int",[74,101,102],{"class":83},"(",[74,104,106],{"class":105},"sjJ54","\"",[74,108,110],{"class":109},"s_sjI","abc",[74,112,106],{"class":105},[74,114,115],{"class":83},")\n",[74,117,119,121,124],{"class":76,"line":118},3,[74,120,55],{"class":80},[74,122,123],{"class":98}," ValueError",[74,125,84],{"class":83},[74,127,129,133,135,137,140,142],{"class":76,"line":128},4,[74,130,132],{"class":131},"sptTA","    print",[74,134,102],{"class":83},[74,136,106],{"class":105},[74,138,139],{"class":109},"That value cannot be converted to an integer",[74,141,106],{"class":105},[74,143,115],{"class":83},[14,145,146],{},"Output:",[65,148,150],{"className":67,"code":149,"language":69,"meta":70,"style":70},"That value cannot be converted to an integer\n",[49,151,152],{"__ignoreMap":70},[74,153,154],{"class":76,"line":77},[74,155,149],{"class":90},[14,157,158],{},"What this does:",[33,160,161,171,177,184],{},[36,162,163,166,167,170],{},[49,164,165],{},"int(\"abc\")"," tries to turn the text ",[49,168,169],{},"\"abc\""," into an integer",[36,172,173,174],{},"That is not possible, so Python raises a ",[49,175,176],{},"ValueError",[36,178,179,180,183],{},"The ",[49,181,182],{},"except ValueError:"," block catches that exception",[36,185,186],{},"Instead of crashing, the program prints a helpful message",[57,188,190],{"id":189},"what-an-exception-means","What an exception means",[14,192,193],{},"An exception is:",[33,195,196,202,205,208],{},[36,197,198,199],{},"An error that happens ",[18,200,201],{},"while a program is running",[36,203,204],{},"Something that interrupts normal execution",[36,206,207],{},"A way for Python to report what went wrong",[36,209,210],{},"Usually shown with an exception name and a traceback",[14,212,213,214,21],{},"Exceptions are different from ",[18,215,216],{},"syntax errors",[33,218,219,226],{},[36,220,221,222,225],{},"A ",[18,223,224],{},"syntax error"," means the code itself is written incorrectly",[36,227,228,229,232],{},"An ",[18,230,231],{},"exception"," means the code starts running, but a problem happens during execution",[14,234,235,236,21],{},"For a broader introduction, see ",[237,238,240],"a",{"href":239},"\u002Flearn\u002Fpython-errors-and-exceptions-explained\u002F","Python errors and exceptions explained",[57,242,244],{"id":243},"when-exceptions-happen","When exceptions happen",[14,246,247],{},"Exceptions happen in very common situations, such as:",[33,249,250,253,259,262,265],{},[36,251,252],{},"Using a bad list index",[36,254,255,256],{},"Converting invalid text with ",[49,257,258],{},"int()",[36,260,261],{},"Opening a file that does not exist",[36,263,264],{},"Dividing by zero",[36,266,267],{},"Looking up a missing dictionary key",[14,269,270],{},"Examples:",[65,272,274],{"className":67,"code":273,"language":69,"meta":70,"style":70},"numbers = [10, 20, 30]\nprint(numbers[5])  # IndexError\n",[49,275,276,304],{"__ignoreMap":70},[74,277,278,281,283,286,290,293,296,298,301],{"class":76,"line":77},[74,279,280],{"class":90},"numbers ",[74,282,95],{"class":94},[74,284,285],{"class":83}," [",[74,287,289],{"class":288},"srdBf","10",[74,291,292],{"class":83},",",[74,294,295],{"class":288}," 20",[74,297,292],{"class":83},[74,299,300],{"class":288}," 30",[74,302,303],{"class":83},"]\n",[74,305,306,309,311,315,318,321,324],{"class":76,"line":87},[74,307,308],{"class":131},"print",[74,310,102],{"class":83},[74,312,314],{"class":313},"slqww","numbers",[74,316,317],{"class":83},"[",[74,319,320],{"class":288},"5",[74,322,323],{"class":83},"])",[74,325,327],{"class":326},"sutJx","  # IndexError\n",[65,329,331],{"className":67,"code":330,"language":69,"meta":70,"style":70},"print(int(\"hello\"))  # ValueError\n",[49,332,333],{"__ignoreMap":70},[74,334,335,337,339,342,344,346,349,351,354],{"class":76,"line":77},[74,336,308],{"class":131},[74,338,102],{"class":83},[74,340,341],{"class":98},"int",[74,343,102],{"class":83},[74,345,106],{"class":105},[74,347,348],{"class":109},"hello",[74,350,106],{"class":105},[74,352,353],{"class":83},"))",[74,355,356],{"class":326},"  # ValueError\n",[65,358,360],{"className":67,"code":359,"language":69,"meta":70,"style":70},"print(10 \u002F 0)  # ZeroDivisionError\n",[49,361,362],{"__ignoreMap":70},[74,363,364,366,368,370,373,376,379],{"class":76,"line":77},[74,365,308],{"class":131},[74,367,102],{"class":83},[74,369,289],{"class":288},[74,371,372],{"class":94}," \u002F",[74,374,375],{"class":288}," 0",[74,377,378],{"class":83},")",[74,380,381],{"class":326},"  # ZeroDivisionError\n",[65,383,385],{"className":67,"code":384,"language":69,"meta":70,"style":70},"data = {\"name\": \"Ana\"}\nprint(data[\"age\"])  # KeyError\n",[49,386,387,418],{"__ignoreMap":70},[74,388,389,392,394,397,399,402,404,407,410,413,415],{"class":76,"line":77},[74,390,391],{"class":90},"data ",[74,393,95],{"class":94},[74,395,396],{"class":83}," {",[74,398,106],{"class":105},[74,400,401],{"class":109},"name",[74,403,106],{"class":105},[74,405,406],{"class":83},":",[74,408,409],{"class":105}," \"",[74,411,412],{"class":109},"Ana",[74,414,106],{"class":105},[74,416,417],{"class":83},"}\n",[74,419,420,422,424,427,429,431,434,436,438],{"class":76,"line":87},[74,421,308],{"class":131},[74,423,102],{"class":83},[74,425,426],{"class":313},"data",[74,428,317],{"class":83},[74,430,106],{"class":105},[74,432,433],{"class":109},"age",[74,435,106],{"class":105},[74,437,323],{"class":83},[74,439,440],{"class":326},"  # KeyError\n",[57,442,444],{"id":443},"basic-example","Basic example",[14,446,447],{},"Here is code that raises an exception:",[65,449,451],{"className":67,"code":450,"language":69,"meta":70,"style":70},"number = int(\"abc\")\nprint(number)\n",[49,452,453,472],{"__ignoreMap":70},[74,454,455,458,460,462,464,466,468,470],{"class":76,"line":77},[74,456,457],{"class":90},"number ",[74,459,95],{"class":94},[74,461,99],{"class":98},[74,463,102],{"class":83},[74,465,106],{"class":105},[74,467,110],{"class":109},[74,469,106],{"class":105},[74,471,115],{"class":83},[74,473,474,476,478,481],{"class":76,"line":87},[74,475,308],{"class":131},[74,477,102],{"class":83},[74,479,480],{"class":313},"number",[74,482,115],{"class":83},[14,484,485,486,488,489,491],{},"If you run it, Python raises a ",[49,487,176],{}," because ",[49,490,169],{}," is not a valid integer.",[14,493,494],{},"Now compare that with a handled version:",[65,496,498],{"className":67,"code":497,"language":69,"meta":70,"style":70},"try:\n    number = int(\"abc\")\n    print(number)\nexcept ValueError:\n    print(\"Please enter a number using digits only\")\n",[49,499,500,506,524,534,542],{"__ignoreMap":70},[74,501,502,504],{"class":76,"line":77},[74,503,51],{"class":80},[74,505,84],{"class":83},[74,507,508,510,512,514,516,518,520,522],{"class":76,"line":87},[74,509,91],{"class":90},[74,511,95],{"class":94},[74,513,99],{"class":98},[74,515,102],{"class":83},[74,517,106],{"class":105},[74,519,110],{"class":109},[74,521,106],{"class":105},[74,523,115],{"class":83},[74,525,526,528,530,532],{"class":76,"line":118},[74,527,132],{"class":131},[74,529,102],{"class":83},[74,531,480],{"class":313},[74,533,115],{"class":83},[74,535,536,538,540],{"class":76,"line":128},[74,537,55],{"class":80},[74,539,123],{"class":98},[74,541,84],{"class":83},[74,543,545,547,549,551,554,556],{"class":76,"line":544},5,[74,546,132],{"class":131},[74,548,102],{"class":83},[74,550,106],{"class":105},[74,552,553],{"class":109},"Please enter a number using digits only",[74,555,106],{"class":105},[74,557,115],{"class":83},[14,559,146],{},[65,561,563],{"className":67,"code":562,"language":69,"meta":70,"style":70},"Please enter a number using digits only\n",[49,564,565],{"__ignoreMap":70},[74,566,567],{"class":76,"line":77},[74,568,562],{"class":90},[14,570,571],{},"How to read this:",[33,573,574,582],{},[36,575,576,578,579],{},[49,577,51],{}," means: ",[18,580,581],{},"run this code",[36,583,584,578,586],{},[49,585,55],{},[18,587,588],{},"if this specific error happens, do this instead",[14,590,591,592,52,595,598,599,21],{},"If you want to learn the full pattern, including ",[49,593,594],{},"else",[49,596,597],{},"finally",", read ",[237,600,602],{"href":601},"\u002Flearn\u002Fusing-try-except-else-and-finally-in-python\u002F","using try, except, else, and finally in Python",[57,604,606],{"id":605},"why-exceptions-are-useful","Why exceptions are useful",[14,608,609],{},"Exceptions are useful because:",[33,611,612,615,624,627],{},[36,613,614],{},"They prevent silent failures",[36,616,617,618,620,621],{},"They give clear names such as ",[49,619,176],{}," or ",[49,622,623],{},"IndexError",[36,625,626],{},"They let programs respond to problems",[36,628,629],{},"They help you debug by showing what caused the problem",[14,631,632],{},"Without exceptions, your program might fail in confusing ways. With exceptions, Python tells you:",[33,634,635,641,647],{},[36,636,637,640],{},[18,638,639],{},"what"," went wrong",[36,642,643,646],{},[18,644,645],{},"where"," it happened",[36,648,649,650,653],{},"often ",[18,651,652],{},"which type"," of problem it is",[14,655,656],{},"That makes fixing bugs much easier.",[57,658,660],{"id":659},"exception-vs-error-handling","Exception vs error handling",[14,662,663],{},"These two ideas are related, but they are not the same:",[33,665,666,671],{},[36,667,228,668,670],{},[18,669,231],{}," is the problem itself",[36,672,673,676],{},[18,674,675],{},"Error handling"," is the code you write to deal with that problem",[14,678,679],{},"For example:",[33,681,682,687],{},[36,683,684,686],{},[49,685,176],{}," is an exception",[36,688,689,52,691,693],{},[49,690,51],{},[49,692,55],{}," are part of error handling",[14,695,696,697,699,700,21],{},"This page focuses on the term ",[18,698,231],{},". For practical ways to catch and manage them, see ",[237,701,703],{"href":702},"\u002Fhow-to\u002Fhow-to-handle-exceptions-in-python\u002F","how to handle exceptions in Python",[57,705,707],{"id":706},"common-exception-types-beginners-see","Common exception types beginners see",[14,709,710],{},"These are some of the most common exceptions in Python:",[33,712,713,717,722,726,731,736,741],{},[36,714,715],{},[49,716,176],{},[36,718,719],{},[49,720,721],{},"TypeError",[36,723,724],{},[49,725,623],{},[36,727,728],{},[49,729,730],{},"KeyError",[36,732,733],{},[49,734,735],{},"NameError",[36,737,738],{},[49,739,740],{},"FileNotFoundError",[36,742,743],{},[49,744,745],{},"ZeroDivisionError",[14,747,748],{},"A few examples:",[33,750,751,758,763,768,773],{},[36,752,753,755,756],{},[49,754,176],{},": the value is the wrong form, such as ",[49,757,165],{},[36,759,760,762],{},[49,761,721],{},": the type is wrong, such as adding a string to an integer",[36,764,765,767],{},[49,766,623],{},": a list index does not exist",[36,769,770,772],{},[49,771,735],{},": you use a variable that has not been defined",[36,774,775,777],{},[49,776,740],{},": Python cannot find the file you asked for",[14,779,780],{},"You can read more about specific exceptions here:",[33,782,783,789,795,801,807],{},[36,784,785],{},[237,786,788],{"href":787},"\u002Ferrors\u002Fvalueerror-in-python-causes-and-fixes\u002F","ValueError in Python: causes and fixes",[36,790,791],{},[237,792,794],{"href":793},"\u002Ferrors\u002Ftypeerror-vs-valueerror-in-python-explained","TypeError in Python: causes and fixes",[36,796,797],{},[237,798,800],{"href":799},"\u002Ferrors\u002Findexerror-in-python-causes-and-fixes\u002F","IndexError in Python: causes and fixes",[36,802,803],{},[237,804,806],{"href":805},"\u002Ferrors\u002Fnameerror-in-python-causes-and-fixes\u002F","NameError in Python: causes and fixes",[36,808,809],{},[237,810,812],{"href":811},"\u002Ferrors\u002Ffilenotfounderror-in-python-causes-and-fixes","FileNotFoundError in Python: causes and fixes",[57,814,816],{"id":815},"common-causes","Common causes",[14,818,819],{},"Beginners often run into exceptions because of one of these problems:",[33,821,822,825,828,831,834],{},[36,823,824],{},"Using the wrong type of value in a function",[36,826,827],{},"Accessing data that does not exist",[36,829,830],{},"Working with missing files or invalid paths",[36,832,833],{},"Doing math that is not allowed, such as division by zero",[36,835,836],{},"Using variables before defining them",[14,838,839],{},"When you see an exception, read the exception name first. It usually gives the best clue about the problem.",[57,841,843],{"id":842},"helpful-debugging-commands","Helpful debugging commands",[14,845,846],{},"These commands and tools can help you understand exceptions:",[65,848,852],{"className":849,"code":850,"language":851,"meta":70,"style":70},"language-bash shiki shiki-themes material-theme-lighter github-light github-dark","python your_file.py\n","bash",[49,853,854],{"__ignoreMap":70},[74,855,856,859],{"class":76,"line":77},[74,857,69],{"class":858},"sbgvK",[74,860,861],{"class":109}," your_file.py\n",[14,863,864],{},"Runs your Python file so you can see the full error message.",[65,866,868],{"className":67,"code":867,"language":69,"meta":70,"style":70},"print(type(value))\n",[49,869,870],{"__ignoreMap":70},[74,871,872,874,876,879,881,884],{"class":76,"line":77},[74,873,308],{"class":131},[74,875,102],{"class":83},[74,877,878],{"class":98},"type",[74,880,102],{"class":83},[74,882,883],{"class":313},"value",[74,885,886],{"class":83},"))\n",[14,888,889,890,52,892,21],{},"Shows the type of a value, which helps with ",[49,891,721],{},[49,893,176],{},[65,895,897],{"className":67,"code":896,"language":69,"meta":70,"style":70},"print(value)\n",[49,898,899],{"__ignoreMap":70},[74,900,901,903,905,907],{"class":76,"line":77},[74,902,308],{"class":131},[74,904,102],{"class":83},[74,906,883],{"class":313},[74,908,115],{"class":83},[14,910,911],{},"Shows the actual value being used.",[65,913,915],{"className":67,"code":914,"language":69,"meta":70,"style":70},"help(int)\n",[49,916,917],{"__ignoreMap":70},[74,918,919,922,924,926],{"class":76,"line":77},[74,920,921],{"class":131},"help",[74,923,102],{"class":83},[74,925,341],{"class":98},[74,927,115],{"class":83},[14,929,930,931,933],{},"Displays help for ",[49,932,258],{}," so you can see how it works.",[65,935,937],{"className":67,"code":936,"language":69,"meta":70,"style":70},"dir(object)\n",[49,938,939],{"__ignoreMap":70},[74,940,941,944,946,949],{"class":76,"line":77},[74,942,943],{"class":131},"dir",[74,945,102],{"class":83},[74,947,948],{"class":98},"object",[74,950,115],{"class":83},[14,952,953],{},"Shows available attributes and methods on an object.",[57,955,957],{"id":956},"faq","FAQ",[959,960,962],"h3",{"id":961},"is-an-exception-the-same-as-a-syntax-error","Is an exception the same as a syntax error?",[14,964,965],{},"No. A syntax error means the code is written incorrectly. An exception happens while correct-looking code is running.",[959,967,969],{"id":968},"do-exceptions-always-crash-a-program","Do exceptions always crash a program?",[14,971,972,973,52,975,977],{},"Not always. If you handle the exception with ",[49,974,51],{},[49,976,55],{},", your program can continue or fail more clearly.",[959,979,981],{"id":980},"what-is-the-difference-between-an-exception-and-an-error","What is the difference between an exception and an error?",[14,983,984],{},"Beginners often use the words the same way. In Python, an exception usually means a runtime problem that Python can raise and you can handle.",[959,986,988],{"id":987},"what-is-the-most-common-exception-for-beginners","What is the most common exception for beginners?",[14,990,991,992,994,995,994,997,994,999,1001,1002,21],{},"Common ones include ",[49,993,176],{},", ",[49,996,721],{},[49,998,623],{},[49,1000,735],{},", and ",[49,1003,740],{},[57,1005,1007],{"id":1006},"see-also","See also",[33,1009,1010,1014,1019,1024,1028,1032],{},[36,1011,1012],{},[237,1013,240],{"href":239},[36,1015,1016],{},[237,1017,1018],{"href":601},"Using try, except, else, and finally in Python",[36,1020,1021],{},[237,1022,1023],{"href":702},"How to handle exceptions in Python",[36,1025,1026],{},[237,1027,788],{"href":787},[36,1029,1030],{},[237,1031,794],{"href":793},[36,1033,1034],{},[237,1035,800],{"href":799},[14,1037,1038,1039,52,1041,1043],{},"The next useful step is to learn how to catch exceptions with ",[49,1040,51],{},[49,1042,55],{},", then look up the specific error type you are seeing.",[1045,1046,1047],"style",{},"html pre.shiki code .sVHd0, html code.shiki .sVHd0{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#D73A49;--shiki-default-font-style:inherit;--shiki-dark:#F97583;--shiki-dark-font-style:inherit}html pre.shiki code .sP7_E, html code.shiki .sP7_E{--shiki-light:#39ADB5;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .su5hD, html code.shiki .su5hD{--shiki-light:#90A4AE;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .smGrS, html code.shiki .smGrS{--shiki-light:#39ADB5;--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sZMiF, html code.shiki .sZMiF{--shiki-light:#E2931D;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sjJ54, html code.shiki .sjJ54{--shiki-light:#39ADB5;--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .s_sjI, html code.shiki .s_sjI{--shiki-light:#91B859;--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .sptTA, html code.shiki .sptTA{--shiki-light:#6182B8;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .srdBf, html code.shiki .srdBf{--shiki-light:#F76D47;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .slqww, html code.shiki .slqww{--shiki-light:#6182B8;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sutJx, html code.shiki .sutJx{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#6A737D;--shiki-default-font-style:inherit;--shiki-dark:#6A737D;--shiki-dark-font-style:inherit}html pre.shiki code .sbgvK, html code.shiki .sbgvK{--shiki-light:#E2931D;--shiki-default:#6F42C1;--shiki-dark:#B392F0}",{"title":70,"searchDepth":87,"depth":87,"links":1049},[1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1065],{"id":59,"depth":87,"text":60},{"id":189,"depth":87,"text":190},{"id":243,"depth":87,"text":244},{"id":443,"depth":87,"text":444},{"id":605,"depth":87,"text":606},{"id":659,"depth":87,"text":660},{"id":706,"depth":87,"text":707},{"id":815,"depth":87,"text":816},{"id":842,"depth":87,"text":843},{"id":956,"depth":87,"text":957,"children":1060},[1061,1062,1063,1064],{"id":961,"depth":118,"text":962},{"id":968,"depth":118,"text":969},{"id":980,"depth":118,"text":981},{"id":987,"depth":118,"text":988},{"id":1006,"depth":87,"text":1007},"Master what is an exception in python in our comprehensive Python beginner guide.","md",{},true,"\u002Fglossary\u002Fwhat-is-an-exception-in-python",{"title":5,"description":1066},"glossary\u002Fwhat-is-an-exception-in-python","Qu1hz4UKGJnQxVSOv2tWNI-Gjg2AOOwrfviTc8l5Q6E",1777585468123]