mirror of
				https://github.com/python/cpython.git
				synced 2025-11-03 23:21:29 +00:00 
			
		
		
		
	gh-102832: IDLE - update stackviewer open (#105528)
Use 'last_exc' instead of 'last_value' in 3.12/3.
This commit is contained in:
		
							parent
							
								
									3ee921d84f
								
							
						
					
					
						commit
						bb3454c1a7
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
					@ -1369,11 +1369,11 @@ def open_stack_viewer(self, event=None):  # -n mode only
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        from idlelib.stackviewer import StackBrowser
 | 
					        from idlelib.stackviewer import StackBrowser
 | 
				
			||||||
        try:
 | 
					        try:
 | 
				
			||||||
            StackBrowser(self.root, sys.last_value, self.flist)
 | 
					            StackBrowser(self.root, sys.last_exc, self.flist)
 | 
				
			||||||
        except:
 | 
					        except:
 | 
				
			||||||
            messagebox.showerror("No stack trace",
 | 
					            messagebox.showerror("No stack trace",
 | 
				
			||||||
                "There is no stack trace yet.\n"
 | 
					                "There is no stack trace yet.\n"
 | 
				
			||||||
                "(sys.last_value is not defined)",
 | 
					                "(sys.last_exc is not defined)",
 | 
				
			||||||
                parent=self.text)
 | 
					                parent=self.text)
 | 
				
			||||||
        return None
 | 
					        return None
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue