You are not logged in.

#1 2019-08-22 20:04:19

julapas
Member
Registered: 2019-01-28
Posts: 5

[SOLVED]Problems installing python2-pwntools

Hi everyone I'm trying to install python2-pwntools in every possible ways because I tried to install from AUR, from pip and from git but I can't use to import any libraries when I'm writing and script can't import from pwn cause it displays that doesn't exist, and if I write pwn -h in command line I get:

Traceback (most recent call last):
  File "/bin/pwn", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3241, in <module>
    @_call_aside
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3225, in _call_aside
    f(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3254, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 585, in _build_master
    return cls._build_from_requirements(__requires__)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 598, in _build_from_requirements
    dists = ws.resolve(reqs, Environment())
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 786, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'sortedcontainers<2.0' distribution was not found and is required by pwntools

And I don't know what indicates that error. I'd Appreciate your help guys thanks.

Last edited by julapas (2019-08-22 23:00:59)

Offline

#2 2019-08-22 20:17:36

loqs
Member
Registered: 2014-03-06
Posts: 9,052

Re: [SOLVED]Problems installing python2-pwntools

https://github.com/Gallopsled/pwntools/ … tup.py#L61 references
https://github.com/Gallopsled/pwntools/issues/1154 which was resolved by https://github.com/chaimleib/intervaltr … 4278063592 present in 3.02

So the dependency can be changed to

                        'sortedcontainers<3.0',

Offline

#3 2019-08-22 20:59:54

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 9,134
Website

Re: [SOLVED]Problems installing python2-pwntools

Mod note: moving to AUR Issues.


Sakura:-
Mobo: MSI X299 TOMAHAWK ARCTIC // Processor: Intel Core i7-7820X 3.6GHz // GFX: nVidia GeForce GTX 970 // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 5x 1TB HDD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#4 2019-08-22 21:14:59

loqs
Member
Registered: 2014-03-06
Posts: 9,052

Re: [SOLVED]Problems installing python2-pwntools

diff --git a/setup.py b/setup.py
index 99d4a029..5644e089 100644
--- a/setup.py
+++ b/setup.py
@@ -58,7 +58,7 @@ install_requires     = ['paramiko>=1.15.2',
                         'packaging',
                         'psutil>=3.3.0',
                         'intervaltree',
-                        'sortedcontainers<2.0', # See Gallopsled/pwntools#1154
+                        'sortedcontainers<3.0',
                         'unicorn']
 
 # Check that the user has installed the Python development headers

Patching_packages covers the changes you need to make to the PKGBUILD to apply the patch.

Offline

#5 2019-08-22 22:59:31

julapas
Member
Registered: 2019-01-28
Posts: 5

Re: [SOLVED]Problems installing python2-pwntools

Thanks guys, the problem was sortedcontainers<2 so I changed it and it works.

Offline

Board footer

Powered by FluxBB