[Lab3] Part5_PDC.pyc : Bad magic number

[Lab3] Part5_PDC.pyc : Bad magic number

by Chau Ying Kot -
Number of replies: 2
Hello,

When I try to run Part5_PDC.pyc file, I have RuntimeError : Bad magic number in .pyc file.

Do you have any idea what the cause of the problem is ?
In reply to Chau Ying Kot

Re: [Lab3] Part5_PDC.pyc : Bad magic number

by Gaiëtan Renault -
Hello,

.pyc files are compiled bytecode generated by python. Modification or trying to run .pyc with a different python version will raise a Bad magic number error. Can you please confirm me that you are on the VM ? If yes, could you please send me your python interpreter version ( python3 -- version).

Best,
Gaiëtan.
In reply to Gaiëtan Renault

Re: [Lab3] Part5_PDC.pyc : Bad magic number

by Chau Ying Kot -
Think you for the quick reply,

indeed I was working on my machine instead of the VM. Everything works fine on the VM.

All best,
Chau