AttributeError: 'bytes' object has no attribute 'encode' error in Python 3.7.3
keepitreal opened this issue · comments
Darion Welch commented
When I run omr
with --output_type=MusicXML
I'm seeing stderr printing AttributeError: 'bytes' object has no attribute 'encode'
error in Python 3.7.3.
Removing the call to .encode('utf-8')
here seems to fix it: https://github.com/tensorflow/moonlight/blob/master/moonlight/omr.py#L95.
Seems to only be an issue in recent versions of Python.
I'm relatively new to this repository but would be willing to submit a PR for this if someone else can reproduce.
Daniel Ringwalt commented
Thanks, this is a Python 3 issue and we're still in the process of updating from Python 2 to 3. I've repro'd and removing encode
is correct there, feel free to open a PR!