pyupgrade: Replace Text with str.
				
					
				
			We uses `pyupgrade --py3-plus` to automatically replace all occurence of `Text`. But manual fix is required to remove the unused imports. Note that with this configuration pyupgrade also convert string literals to .format(...) style, which is manually not included in the commit as well.
This commit is contained in:
		
							parent
							
								
									a54cccc012
								
							
						
					
					
						commit
						e27ac0ddbe
					
				
					 11 changed files with 42 additions and 46 deletions
				
			
		|  | @ -1,4 +1,4 @@ | |||
| from typing import Dict, Optional, Text | ||||
| from typing import Dict, Optional | ||||
| 
 | ||||
| # Change these values to configure authentication for the plugin | ||||
| ZULIP_USER = "svn-bot@example.com" | ||||
|  | @ -18,7 +18,7 @@ ZULIP_API_KEY = "0123456789abcdef0123456789abcdef" | |||
| # and "my-super-secret-repository" repos to | ||||
| # * stream "commits" | ||||
| # * topic "branch_name" | ||||
| def commit_notice_destination(path: Text, commit: Text) -> Optional[Dict[Text, Text]]: | ||||
| def commit_notice_destination(path: str, commit: str) -> Optional[Dict[str, str]]: | ||||
|     repo = path.split("/")[-1] | ||||
|     if repo not in ["evil-master-plan", "my-super-secret-repository"]: | ||||
|         return dict(stream="commits", subject="%s" % (repo,)) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 PIG208
						PIG208