Add type annotations
This commit is contained in:
		
							parent
							
								
									488142eede
								
							
						
					
					
						commit
						d1d0e7c969
					
				
					 1 changed files with 4 additions and 4 deletions
				
			
		| 
						 | 
				
			
			@ -1,4 +1,4 @@
 | 
			
		|||
from os import getenv, chdir
 | 
			
		||||
from os import chdir
 | 
			
		||||
import logging
 | 
			
		||||
# Use logger that is also in wallman_lib
 | 
			
		||||
logger = logging.getLogger("wallman")
 | 
			
		||||
| 
						 | 
				
			
			@ -36,7 +36,7 @@ def on_quit(icon, item, shutdown_scheduler):
 | 
			
		|||
 | 
			
		||||
chdir("/etc/wallman/icons/")
 | 
			
		||||
try:
 | 
			
		||||
    icon_image = Image.open("systrayIcon.jpg")
 | 
			
		||||
    icon_image: Image.Image = Image.open("systrayIcon.jpg")
 | 
			
		||||
except FileNotFoundError:
 | 
			
		||||
    logger.error("~/.config/wallman/systrayIcon.jpg has not been found, wallman will launch without a systray.")
 | 
			
		||||
    print("~/.config/wallman/systrayIcon.jpg has not been found, wallman will launch without a systray.")
 | 
			
		||||
    logger.error("/etc/wallman/icons/systrayIcon.jpg has not been found, wallman will launch without a systray.")
 | 
			
		||||
    print("ERROR: /etc/wallman/icons/systrayIcon.jpg has not been found, wallman will launch without a systray.")
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in a new issue