Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build failure with python < 2.7: ImportError: No module named argparse #4483

Closed
ryandesign opened this issue Dec 15, 2014 · 1 comment
Closed

Comments

@ryandesign
Copy link
Contributor

@ryandesign ryandesign commented Dec 15, 2014

Hello, I'm the maintainer of youtube-dl in the MacPorts package management system. Building youtube-dl 2014.12.15 fails on Mac OS X v10.6 Snow Leopard as follows:

DEBUG: Executing command line:  cd "/Volumes/Data/macports/snowleopard/var/macports/build/_Volumes_Data_macports_dports_net_youtube-dl/youtube-dl/work/youtube-dl" && /usr/bin/make -w all PYTHON=/Volumes/Data/macports/snowleopard/bin/python2.7 
make: Entering directory `/Volumes/Data/macports/snowleopard/var/macports/build/_Volumes_Data_macports_dports_net_youtube-dl/youtube-dl/work/youtube-dl'
zip -q youtube-dl youtube_dl/*.py youtube_dl/*/*.py
zip -q -j youtube-dl youtube_dl/__main__.py
echo '#!/Volumes/Data/macports/snowleopard/bin/python2.7' > youtube-dl
cat youtube-dl.zip >> youtube-dl
rm youtube-dl.zip
chmod a+x youtube-dl
python devscripts/make_contributing.py README.md CONTRIBUTING.md
Traceback (most recent call last):
  File "devscripts/make_contributing.py", line 4, in <module>
    import argparse
ImportError: No module named argparse

I believe the problem is that make_contributing.py uses argparse, which is not included in Python until version 2.7; python on Mac OS X v10.6 is version 2.6.1. As you can see I have requested to use a MacPorts-installed copy of Python 2.7, but the youtube-dl build system is not making use of it. My first guess is that you could use $(PYTHON) instead of python in the Makefile to fix this.

@phihag phihag closed this in ccbfaa8 Dec 15, 2014
@phihag
Copy link
Contributor

@phihag phihag commented Dec 15, 2014

Thank you for the report. I believe this to be fixed in youtube-dl 2014.12.16.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.