fix: skip comment lines in load_path.py paths parsing
Lines starting with # were parsed as path+role, causing
'#'.split() = ['#','sage_datamart'], where 'sage_datamart'
isn't 'any'/'logined'/'anonymous' and has no '.',
crashing add_roles_perm at role.split('.')
This commit is contained in:
parent
3290fd959e
commit
cf88984a09
@ -1531,7 +1531,7 @@ async def main():
|
||||
cnt = 0
|
||||
async with db.sqlorContext('sage') as sor:
|
||||
for l in paths.split('\n'):
|
||||
if not l:
|
||||
if not l or l.startswith('#'):
|
||||
continue
|
||||
parts = l.split()
|
||||
path = parts[0]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user