mirror of
				https://github.com/qurator-spk/modstool.git
				synced 2025-10-31 17:34:13 +01:00 
			
		
		
		
	✨ ALTO: Handle PermissionErrors
This commit is contained in:
		
							parent
							
								
									10b8023dd6
								
							
						
					
					
						commit
						01326050d3
					
				
					 1 changed files with 4 additions and 1 deletions
				
			
		|  | @ -79,7 +79,10 @@ def walk(m): | ||||||
|             if f.is_file() and not f.name.startswith('.'): |             if f.is_file() and not f.name.startswith('.'): | ||||||
|                 yield f.path |                 yield f.path | ||||||
|             elif f.is_dir(): |             elif f.is_dir(): | ||||||
|  |                 try: | ||||||
|                     yield from walk(f.path) |                     yield from walk(f.path) | ||||||
|  |                 except PermissionError: | ||||||
|  |                     warnings.warn(f"Error walking {f.path}") | ||||||
|     else: |     else: | ||||||
|         yield m.path |         yield m.path | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue