You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I parsed the Pipfile given in the example section, an attribute error came up because the line
requests = { extras = ['socks'] },
coz there is a list but it doesn't contain a dictionary. So just checking the type solved the issue.
def inject_environment_variables(d):
if not d:
return d
for k, v in d.items():
if isinstance(v, str):
d[k] = os.path.expandvars(v)
elif isinstance(v, dict):
d[k] = inject_environment_variables(v)
elif isinstance(v, list):
for e in v:
if type(e) == 'dict':
d[k] = inject_environment_variables(e)
else:
continue
return d
The text was updated successfully, but these errors were encountered:
When I parsed the Pipfile given in the example section, an attribute error came up because the line
requests = { extras = ['socks'] },
coz there is a list but it doesn't contain a dictionary. So just checking the type solved the issue.
The text was updated successfully, but these errors were encountered: