mirror of
https://github.com/openSUSE/osc.git
synced 2025-01-23 05:26:16 +01:00
- pass a str to exec() instead of an open file object
An open file object isn't supported anymore by python3. This fixes issue #26.
This commit is contained in:
parent
0c0ffe50fb
commit
cdc1245960
@ -7859,7 +7859,7 @@ Please submit there instead, or use --nodevelproject to force direct submission.
|
||||
if not extfile.endswith('.py'):
|
||||
continue
|
||||
try:
|
||||
exec(open(os.path.join(plugin_dir, extfile)))
|
||||
exec(open(os.path.join(plugin_dir, extfile)).read())
|
||||
except SyntaxError as e:
|
||||
if (os.environ.get('OSC_PLUGIN_FAIL_IGNORE')):
|
||||
print("%s: %s\n" % (plugin_dir, e), file=sys.stderr)
|
||||
|
Loading…
Reference in New Issue
Block a user