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

Fix 'too many values to unpack' issue #8

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tlvince
Copy link

@tlvince tlvince commented Jan 25, 2013

Line 12119 of EasyList (24 Jan 2013 21:51 UTC) contains the following (excuse
the unfortunate vulgarity!):

||judgeporn.com/video_pop.php?$$image,~image,popup

This is tripping up abp_import.py, giving the following stack trace:

Unhandled options: ~image, popup

Traceback (most recent call last):
File "./abp_import.py", line 101, in
main()
File "./abp_import.py", line 98, in main
print translate_all(easylist, infile)
File "./abp_import.py", line 71, in translate_all
str += translate(line)
File "./abp_import.py", line 54, in translate
pat, opts = line.split("$",2)
ValueError: too many values to unpack
make: *** [privoxy/easylist.action] Error 1
==> ERROR: A failure occurred in build().
Aborting...
The build failed.

This is a quick fix that simply checks for "$$" and splits accordingly.

Line 12119 of EasyList (24 Jan 2013 21:51 UTC) contains the following (excuse
the unfortunate vulgarity!):

    ||judgeporn.com/video_pop.php?$$image,~image,popup

This is tripping up abp_import.py, giving the following stack trace:

    Unhandled options: ~image, popup
    Traceback (most recent call last):
      File "./abp_import.py", line 101, in <module>
        main()
      File "./abp_import.py", line 98, in main
        print translate_all(easylist, infile)
      File "./abp_import.py", line 71, in translate_all
        str += translate(line)
      File "./abp_import.py", line 54, in translate
        pat, opts = line.split("$",2)
    ValueError: too many values to unpack
    make: *** [privoxy/easylist.action] Error 1
    ==> ERROR: A failure occurred in build().
        Aborting...
    The build failed.

This is a quick fix that simply checks for "$$" and splits accordingly.
@freedomUSA
Copy link

your missing build dep, if you look it tells you whats missing when the script runs,worked fine on Debian Wheezy after I got all the build-dep

freedombox-privoxy-3.0.19-2-1
freedombox-privoxy_3.0.19-2-1_amd64.build
freedombox-privoxy_3.0.19-2-1_amd64.changes
freedombox-privoxy_3.0.19-2-1_amd64.deb
freedombox-privoxy_3.0.19-2-1.debian.tar.gz
freedombox-privoxy_3.0.19-2-1.dsc
freedombox-privoxy_3.0.19-2.orig.tar.gz
privoxy-3.0.19
privoxy_3.0.19-2.debian.tar.gz
privoxy_3.0.19-2.dsc
privoxy_3.0.19.orig.tar.gz

@tlvince
Copy link
Author

tlvince commented Feb 12, 2013

It's quite possible, though I'm not seeing any missing dependency messages. I'm using the following to build on Arch Linux (see PKGBUILD):

depends=('pcre' 'zlib')
makedepends=('autoconf' 'git' 'python2' 'python2-beautifulsoup3')

Which dependencies were you missing that solved the issue?

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

Successfully merging this pull request may close these issues.

2 participants