Comments (14)
I'm having the same issue on macOS ver 10.13.6.
output of sys.stderr.buffer is <_io.BufferedWriter name='<stderr>'>
from audiojack.
This is an unusual error, and it looks like it has to do with youtube-dl
. Try updating youtube-dl
and re-downloading the FFmpeg binaries, and see if you still get the error.
from audiojack.
This issue is still present. I updated youtube-dl and FFmpeg and still, the error is present.
from audiojack.
What OS are you using? Do you always get this error, or only with certain settings (custom tags, custom path, etc.)?
from audiojack.
from audiojack.
Thank you for the detailed breakdown! I'm thinking that something is going wrong in application.py
, but there are a few try-catch statements after line 58 so it's difficult to pinpoint where the error is occurring. Try replacing application.py
with the copy I've attached (rename the extension to .py
, GitHub doesn't allow attaching .py
files directly) and you should get a more detailed error report.
from audiojack.
from audiojack.
Looks like youtube-dl
expects sys.stderr.buffer
to be a BufferedWriter
object, but for some reason, your console returns a string object. Where are you running the program from (cmd, PowerShell, etc.)?
Also, what is returned when you run the following code?
import sys
print(sys.stderr.buffer)
from audiojack.
from audiojack.
You have to run the code in the Python shell. In cmd, first type in py
, then press enter. You should see a message telling you your Python version and some other info (make sure this is Python 3+, if it's not, then try running python
instead). Type in the first line (import sys
) and press enter, and then type in sys.stderr.buffer
and press enter.
If that doesn't work, then save the two lines of code as a .py
file and run it as you would run any Python file.
from audiojack.
from audiojack.
I'm not exactly sure what is causing this problem; I suggest you open an issue over on youtube-dl and see if they can help. In the meantime, does using PowerShell or another terminal prevent the error?
from audiojack.
@bunny-pot same exact issue on MacOS Mojave 10.14.4. Has anybody found a fix for this?
from audiojack.
Here is the output using the modified application.py file:
$ python3 launcher.py
[INFO ] [Logger ] Record log in /Users/cmot17/.kivy/logs/kivy_19-05-19_1.txt
[INFO ] [Kivy ] v1.10.1
[INFO ] [Python ] v3.7.3 (default, Mar 27 2019, 09:23:15)
[Clang 10.0.1 (clang-1001.0.46.3)]
[INFO ] [Factory ] 194 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_imageio, img_dds, img_sdl2, img_pil, img_gif (img_ffpyplayer ignored)
[INFO ] [Loader ] using a thread pool of 2 workers
[INFO ] [Text ] Provider: sdl2
[INFO ] [Window ] Provider: sdl2
[INFO ] [GL ] Using the "OpenGL ES 2" graphics system
[INFO ] [GL ] Backend used <gl>
[INFO ] [GL ] OpenGL version <b'2.1 ATI-2.8.38'>
[INFO ] [GL ] OpenGL vendor <b'ATI Technologies Inc.'>
[INFO ] [GL ] OpenGL renderer <b'AMD Radeon RX Vega 56 OpenGL Engine'>
[INFO ] [GL ] OpenGL parsed version: 2, 1
[INFO ] [GL ] Shading version <b'1.20'>
[INFO ] [GL ] Texture max size <16384>
[INFO ] [GL ] Texture max units <16>
[INFO ] [Window ] auto add sdl2 input provider
[INFO ] [Window ] virtual keyboard not allowed, single mode, not docked
[INFO ] [GL ] NPOT texture support is available
[INFO ] [Base ] Start application main loop
[INFO ] [Clipboard ] Provider: sdl2(['clipboard_nspaste'] ignored)
[youtube] XbGs_qK2PQA: Downloading webpage
[youtube] XbGs_qK2PQA: Downloading video info webpage
Notified current thread
/Users/cmot17/Downloads/AudioJack-GUI
[youtube] XbGs_qK2PQA: Downloading webpage
[youtube] XbGs_qK2PQA: Downloading video info webpage
[download] XbGs_qK2PQA.webm has already been downloaded
[download] 100% of 5.80MiB
[ffmpeg] Destination: XbGs_qK2PQA.mp3
Exception in thread Thread-10:
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/youtube_dl/postprocessor/ffmpeg.py", line 265, in run_ffmpeg
FFmpegPostProcessor.run_ffmpeg(self, path, out_path, opts)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/postprocessor/ffmpeg.py", line 239, in run_ffmpeg
self.run_ffmpeg_multiple_files([path], out_path, opts)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/postprocessor/ffmpeg.py", line 235, in run_ffmpeg_multiple_files
raise FFmpegPostProcessorError(msg)
youtube_dl.postprocessor.ffmpeg.FFmpegPostProcessorError: Unknown encoder 'libmp3lame'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/youtube_dl/postprocessor/ffmpeg.py", line 336, in run
self.run_ffmpeg(path, new_path, acodec, more_opts)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/postprocessor/ffmpeg.py", line 267, in run_ffmpeg
raise AudioConversionError(err.msg)
youtube_dl.postprocessor.common.AudioConversionError: Unknown encoder 'libmp3lame'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 2054, in post_process
files_to_delete, info = pp.run(info)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/postprocessor/ffmpeg.py", line 339, in run
'audio conversion failed: ' + e.msg)
youtube_dl.utils.PostProcessingError: audio conversion failed: Unknown encoder 'libmp3lame'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/lib/python3.7/threading.py", line 917, in _bootstrap_inner
self.run()
File "/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/lib/python3.7/threading.py", line 865, in run
self._target(*self._args, **self._kwargs)
File "/Users/cmot17/Downloads/AudioJack-GUI/audiojack_gui.py", line 175, in _select
self.local_search.select(index, path=self.path)
File "/Users/cmot17/Downloads/AudioJack-GUI/application.py", line 63, in select
self.file = self.audiojack.select(self.selection, path=path)
File "/Users/cmot17/Downloads/AudioJack-GUI/audiojack.py", line 46, in select
info = self.ydl.extract_info(entry['url'])
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 807, in extract_info
return self.process_ie_result(ie_result, download, extra_info)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 861, in process_ie_result
return self.process_video_result(ie_result, download=download)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 1642, in process_video_result
self.process_info(new_info)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 1989, in process_info
self.post_process(filename, info_dict)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 2056, in post_process
self.report_error(e.msg)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 624, in report_error
self.trouble(error_message, tb)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 577, in trouble
self.to_stderr(message)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 526, in to_stderr
self._write_string(output, self._err_file)
File "/usr/local/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 505, in _write_string
write_string(s, out=out, encoding=self.params.get('encoding'))
File "/usr/local/lib/python3.7/site-packages/youtube_dl/utils.py", line 1500, in write_string
out.buffer.write(byt)
AttributeError: 'str' object has no attribute 'write'
EDIT:
Here is more info:
$ python3
Python 3.7.3 (default, Mar 27 2019, 09:23:15)
[Clang 10.0.1 (clang-1001.0.46.3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.stderr.buffer
<_io.BufferedWriter name='<stderr>'>
from audiojack.
Related Issues (3)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from audiojack.