Open Sicks3c opened 5 years ago
I tried to switch to py3
and did these
Tried py3 I changed urlparse to urllib.parse and also
from StringIO import StringIO
because of
ImportError: No module named 'StringIO'
Works like charm
No syntax error but when I put js link via localhost and press JSParse
I get this
HTTPServerRequest(protocol='http', host='localhost:8008', method='POST', uri='/parse/ajax', version='HTTP/1.1', remote_ip='::1')
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/tornado/web.py", line 1590, in _execute
result = method(*self.path_args, **self.path_kwargs)
File "handler.py", line 198, in post
data = self.parseLinks(url, headers)
File "handler.py", line 184, in parseLinks
file = self.fetchURL(url, headers)
File "handler.py", line 179, in fetchURL
res = sc.execute(url)
File "/opt/JSParser/safeurl.py", line 714, in execute
response = StringIO.StringIO()
AttributeError: type object '_io.StringIO' has no attribute 'StringIO'
ERROR:tornado.access:500 POST /parse/ajax (::1) 75.82ms
Any solution ?
2 from setuptools import setup, find_packages
3
4 setup(
5 name='JSParser',
6 version='1.0',
7 packages=find_packages(),
8 description="",
9 long_description=open('README.md').read(),
10 author='Ben Sadeghipour',
11 url='https://github.com/nahamsec/JSParser',
12 install_requires=['safeurl', 'tornado<=5.1', 'jsbeautifier',
13 'netaddr', 'pycurl', 'BeautifulSoup4'],
14 )
change the torando
with tornado<=5.1
, it will fix the issue
2 from setuptools import setup, find_packages 3 4 setup( 5 name='JSParser', 6 version='1.0', 7 packages=find_packages(), 8 description="", 9 long_description=open('README.md').read(), 10 author='Ben Sadeghipour', 11 url='https://github.com/nahamsec/JSParser', 12 install_requires=['safeurl', 'tornado<=5.1', 'jsbeautifier', 13 'netaddr', 'pycurl', 'BeautifulSoup4'], 14 )
change the
torando
withtornado<=5.1
, it will fix the issue
I can confirm. It works with your solution.
2 from setuptools import setup, find_packages 3 4 setup( 5 name='JSParser', 6 version='1.0', 7 packages=find_packages(), 8 description="", 9 long_description=open('README.md').read(), 10 author='Ben Sadeghipour', 11 url='https://github.com/nahamsec/JSParser', 12 install_requires=['safeurl', 'tornado<=5.1', 'jsbeautifier', 13 'netaddr', 'pycurl', 'BeautifulSoup4'], 14 )
change the
torando
withtornado<=5.1
, it will fix the issue
stil lhave the problem.
ERROR: Package 'tornado' requires a different Python 2.7.17 not in '>= 3.5' .
Problem solve:
Hello
I have an issue concerning JSParser 1 - I Cloned the repo 2 -
python setup.py install
3 -pip install -r -requirements.txt
4 -python handler.py
The errorWhat I Tried
sudo pip install --upgrade {packages} ...
Same issue
I'm using