my code is as below
aaa = "['https://google.com', 'https://yahoo.com']"
REQUEST = f'{"siteUrls": {aaa}}'
print(REQUEST)
I've tried
aaa = "['https://google.com', 'https://yahoo.com']"
REQUEST = {"siteUrls": {}}.format(aaa)
print(REQUEST)
and
aaa = "['https://google.com', 'https://yahoo.com']"
REQUEST = {"siteUrls": %s}%aaa
print(REQUEST)
all of them didn't work
REQUEST must be dict.
please help.
try this
aaa = "['https://google.com', 'https://yahoo.com']"
REQUEST = {"siteUrls": f"{aaa}"}
print(REQUEST)