mirror of
				https://github.com/f-droid/fdroidserver.git
				synced 2025-11-04 14:30:30 +03:00 
			
		
		
		
	"field will be in random order" only applies to config.py
YAML only has lists, no sets or tuples, so this warning can only ever make any sense when config.py is the active config file.
This commit is contained in:
		
							parent
							
								
									a1d9d9d885
								
							
						
					
					
						commit
						d7a673523d
					
				
					 1 changed files with 6 additions and 6 deletions
				
			
		| 
						 | 
				
			
			@ -429,12 +429,12 @@ def read_config(opts=None):
 | 
			
		|||
            code = compile(fp.read(), old_config_file, 'exec')
 | 
			
		||||
            exec(code, None, config)  # nosec TODO automatically migrate
 | 
			
		||||
 | 
			
		||||
    for k in ('mirrors', 'install_list', 'uninstall_list', 'serverwebroot', 'servergitroot'):
 | 
			
		||||
        if k in config:
 | 
			
		||||
            if not type(config[k]) in (str, list, tuple):
 | 
			
		||||
                logging.warning(
 | 
			
		||||
                    _("'{field}' will be in random order! Use () or [] brackets if order is important!")
 | 
			
		||||
                    .format(field=k))
 | 
			
		||||
        for k in ('mirrors', 'install_list', 'uninstall_list', 'serverwebroot', 'servergitroot'):
 | 
			
		||||
            if k in config:
 | 
			
		||||
                if not type(config[k]) in (str, list, tuple):
 | 
			
		||||
                    logging.warning(
 | 
			
		||||
                        _("'{field}' will be in random order! Use () or [] brackets if order is important!")
 | 
			
		||||
                        .format(field=k))
 | 
			
		||||
 | 
			
		||||
    # smartcardoptions must be a list since its command line args for Popen
 | 
			
		||||
    smartcardoptions = config.get('smartcardoptions')
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue