mirror of
				https://github.com/python/cpython.git
				synced 2025-10-31 13:41:24 +00:00 
			
		
		
		
	[issue19151] Fix docstring and use of _get_suppported_file_loaders() to reflect 2-tuples.
This commit is contained in:
		
							parent
							
								
									60b183407c
								
							
						
					
					
						commit
						efbc475278
					
				
					 3 changed files with 2627 additions and 2626 deletions
				
			
		|  | @ -781,7 +781,7 @@ def find_module(cls, fullname, path=None): | ||||||
|             _os.stat(filepath) |             _os.stat(filepath) | ||||||
|         except OSError: |         except OSError: | ||||||
|             return None |             return None | ||||||
|         for loader, suffixes, _ in _get_supported_file_loaders(): |         for loader, suffixes in _get_supported_file_loaders(): | ||||||
|             if filepath.endswith(tuple(suffixes)): |             if filepath.endswith(tuple(suffixes)): | ||||||
|                 return loader(fullname, filepath) |                 return loader(fullname, filepath) | ||||||
| 
 | 
 | ||||||
|  | @ -1643,7 +1643,7 @@ def _calc___package__(globals): | ||||||
| def _get_supported_file_loaders(): | def _get_supported_file_loaders(): | ||||||
|     """Returns a list of file-based module loaders. |     """Returns a list of file-based module loaders. | ||||||
| 
 | 
 | ||||||
|     Each item is a tuple (loader, suffixes, allow_packages). |     Each item is a tuple (loader, suffixes). | ||||||
|     """ |     """ | ||||||
|     extensions = ExtensionFileLoader, _imp.extension_suffixes() |     extensions = ExtensionFileLoader, _imp.extension_suffixes() | ||||||
|     source = SourceFileLoader, SOURCE_SUFFIXES |     source = SourceFileLoader, SOURCE_SUFFIXES | ||||||
|  |  | ||||||
|  | @ -203,6 +203,9 @@ Library | ||||||
| 
 | 
 | ||||||
| - Issue #18405: Improve the entropy of crypt.mksalt(). | - Issue #18405: Improve the entropy of crypt.mksalt(). | ||||||
| 
 | 
 | ||||||
|  | - Issue #19151: Fix docstring and use of _get_suppported_file_loaders() to | ||||||
|  |   reflect 2-tuples. | ||||||
|  | 
 | ||||||
| - Issue #18676: Change 'positive' to 'non-negative' in queue.py put and get | - Issue #18676: Change 'positive' to 'non-negative' in queue.py put and get | ||||||
|   docstrings and ValueError messages. Patch by Zhongyue Luo |   docstrings and ValueError messages. Patch by Zhongyue Luo | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
							
								
								
									
										5246
									
								
								Python/importlib.h
									
										
									
									
									
								
							
							
						
						
									
										5246
									
								
								Python/importlib.h
									
										
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load diff
											
										
									
								
							
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Eric Snow
						Eric Snow