ThoughtfulDev / EagleEye

Stalk your Friends. Find their Instagram, FB and Twitter Profiles using Image Recognition and Reverse Image Search.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Error while scanning

niemajak900 opened this issue · comments

got following issue while scanning:

:: Result
==> Found the following Profiles:

:: Google Reverse Image Search
==> Opening Webdriver

:: Uploading Local Known Images
==> Please agree to google's stuff in the browser
Traceback (most recent call last):
File "/home/kali/Desktop/EagleEye-master/eagle-eye.py", line 229, in
main(skipFB=args.skipfb, FBUrls=[], jsonRep=jsonRepFile, dockerMode=aDocker, dockerName=aName)
File "/home/kali/Desktop/EagleEye-master/eagle-eye.py", line 131, in main
g.collectLinksLocal()
File "/home/kali/Desktop/EagleEye-master/grabber/google.py", line 136, in collectLinksLocal
elems = driver.find_elements_by_xpath(self.PHOTO_XPATH)[0]
IndexError: list index out of range

I have seen it in a previous issue developer commented; "Change the X_PATH in google.py because google changed the X_PATH of the input. You can do this by inspecting the element (e.g input box)." but to what do I change inside the file?

You should familiarize yourself with developer tools of browsers. just right click the element and copy the xpath

You should familiarize yourself with developer tools of browsers. just right click the element and copy the xpath

I tried to do that. but there are four xpaths in google.py:

PHOTO_XPATH
PHOTO_UPLOAD_XPATH
PRED_XPATH
PRED_LINKS

And I don't know which element on the google image search website is responsible for a particular XPATH. for example I click on the element of google input box to get an xpath and I got: /html/body/div[2]/div[2]/div/form/div[1]/div[1]/div[1]/div/div[2]/input and where do I paste it?

It is difficult to sort this issue out for some one who has minimal knowledge.

image

You should familiarize yourself with developer tools of browsers. just right click the element and copy the xpath

example:
//*[@id="discussion_bucket"]/div/div[1]/div/div[1]/div[2]/div[2]/div/div[1]/a/img

image

You should familiarize yourself with developer tools of browsers. just right click the element and copy the xpath

example: //*[@id="discussion_bucket"]/div/div[1]/div/div[1]/div[2]/div[2]/div/div[1]/a/img

I know how to get an xpath. but there are four xpaths in google.py and I do not know how to find a xpath for these listed below:

PHOTO_XPATH
PHOTO_UPLOAD_XPATH
PRED_XPATH
PRED_LINKS

Fixed in latest commit

Hi can anyone help me on this thanks!
:: Creating PDF Report
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/PIL/ImageFile.py", line 496, in _save
fh = fp.fileno()
io.UnsupportedOperation: fileno

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/PIL/Image.py", line 430, in _getencoder
encoder = getattr(core, encoder_name + "_encoder")
AttributeError: module 'PIL._imaging' has no attribute 'jpeg2k_encoder'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/weasyprint/document.py", line 256, in _save_jpeg2000
pillow_image.save(image_file, format='JPEG2000', optimize=optimize)
File "/usr/lib/python3/dist-packages/PIL/Image.py", line 2102, in save
save_handler(self, fp, filename)
File "/usr/lib/python3/dist-packages/PIL/Jpeg2KImagePlugin.py", line 290, in _save
ImageFile._save(im, fp, [("jpeg2k", (0, 0) + im.size, 0, kind)])
File "/usr/lib/python3/dist-packages/PIL/ImageFile.py", line 501, in _save
e = Image._getencoder(im.mode, e, a, im.encoderconfig)
File "/usr/lib/python3/dist-packages/PIL/Image.py", line 433, in _getencoder
raise OSError("encoder %s not available" % encoder_name)
OSError: encoder jpeg2k not available

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/PIL/ImageFile.py", line 496, in _save
fh = fp.fileno()
io.UnsupportedOperation: fileno

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/PIL/Image.py", line 430, in _getencoder
encoder = getattr(core, encoder_name + "_encoder")
AttributeError: module 'PIL._imaging' has no attribute 'jpeg2k_encoder'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "eagle-eye.py", line 229, in
main(skipFB=args.skipfb, FBUrls=[], jsonRep=jsonRepFile, dockerMode=aDocker, dockerName=aName)
File "eagle-eye.py", line 175, in main
makeReport(name, rev_links, predictions, validatedInstaNames)
File "/home/python/git/EagleEye/report/report.py", line 37, in makeReport
doc.write_pdf('{0}_Report.pdf'.format(name))
File "/usr/local/lib/python3.8/dist-packages/weasyprint/init.py", line 180, in write_pdf
self.render(
File "/usr/local/lib/python3.8/dist-packages/weasyprint/document.py", line 1157, in write_pdf
page.paint(stream, scale=scale)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/document.py", line 767, in paint
draw_page(self._page_box, stream)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/draw.py", line 69, in draw_page
draw_stacking_context(stream, stacking_context)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/draw.py", line 182, in draw_stacking_context
draw_stacking_context(stream, child_context)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/draw.py", line 159, in draw_stacking_context
draw_box_background_and_border(
File "/usr/local/lib/python3.8/dist-packages/weasyprint/draw.py", line 73, in draw_box_background_and_border
draw_background(stream, box.background)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/draw.py", line 341, in draw_background
draw_background_image(stream, layer, bg.image_rendering)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/draw.py", line 423, in draw_background_image
layer.image.draw(group, image_width, image_height, image_rendering)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/images.py", line 56, in draw
image_name = stream.add_image(
File "/usr/local/lib/python3.8/dist-packages/weasyprint/document.py", line 320, in add_image
image_file = self._save_jpeg2000(pillow_image, optimize)
File "/usr/local/lib/python3.8/dist-packages/weasyprint/document.py", line 261, in _save_jpeg2000
pillow_image.save(
File "/usr/lib/python3/dist-packages/PIL/Image.py", line 2102, in save
save_handler(self, fp, filename)
File "/usr/lib/python3/dist-packages/PIL/Jpeg2KImagePlugin.py", line 290, in _save
ImageFile._save(im, fp, [("jpeg2k", (0, 0) + im.size, 0, kind)])
File "/usr/lib/python3/dist-packages/PIL/ImageFile.py", line 501, in _save
e = Image._getencoder(im.mode, e, a, im.encoderconfig)
File "/usr/lib/python3/dist-packages/PIL/Image.py", line 433, in _getencoder
raise OSError("encoder %s not available" % encoder_name)
OSError: encoder jpeg2k not available

Its a OS error. libjpeg dev Package is missing for you