proseltd / Telepathy-Community

Public release of Telepathy, an OSINT toolkit for investigating Telegram chats.
MIT License
949 stars 133 forks source link

AttributeError: 'User' object has no attribute 'title' #35

Closed elabdi closed 1 year ago

elabdi commented 1 year ago

telepathy -t ***** -c

  ______     __                 __  __
 /_  __/__  / /__  ____  ____ _/ /_/ /_  __  __
  / / / _ \/ / _ \/ __ \/ __ `/ __/ __ \/ / / /
 / / /  __/ /  __/ /_/ / /_/ / /_/ / / / /_/ /
/_/  \___/_/\___/ .___/\__,_/\__/_/ /_/\__, /
               /_/                    /____/
-- An OSINT toolkit for investigating Telegram chats.
-- Developed by @jordanwildon | Version 2.2.62.

[!] Performing comprehensive scan [-] Fetching details for **... Traceback (most recent call last): File "C:\Python310\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "C:\Python310\lib\runpy.py", line 86, in run_code exec(code, run_globals) File "C:\Python310\Scripts\telepathy.exe_main.py", line 7, in File "C:\Python310\lib\site-packages\click\core.py", line 829, in call return self.main(args, kwargs) File "C:\Python310\lib\site-packages\click\core.py", line 782, in main rv = self.invoke(ctx) File "C:\Python310\lib\site-packages\click\core.py", line 1066, in invoke return ctx.invoke(self.callback, *ctx.params) File "C:\Python310\lib\site-packages\click\core.py", line 610, in invoke return callback(args, **kwargs) File "C:\Python310\lib\site-packages\telepathy\telepathy.py", line 1759, in cli client.loop.run_until_complete(main()) File "C:\Python310\lib\asyncio\base_events.py", line 646, in run_until_complete return future.result() File "C:\Python310\lib\site-packages\telepathy\telepathy.py", line 407, in main name = entity.title AttributeError: 'User' object has no attribute 'title'

proseltd commented 1 year ago

It appears you're searching for a user using the comprehensive flag and not the user flag. Is this correct?

elabdi commented 1 year ago

It appears you're searching for a user using the comprehensive flag and not the user flag. Is this correct?

No as you can see this is the command i run : telepathy -t userintelegram -c

proseltd commented 1 year ago

Forgive me if I am misunderstanding, but "userintelegram" would be a username, not a group or channel, hence why Telegram's API is telling you the user object doesn't have a title, because you're trying to look up a user.

Therefore, you should be using the user flag and not the comprehensive flag.

$ telepathy -t userintelegram -u would therefore be what you are looking for. More details of that in this part of the documentation:

'--user', '-u'

Looks up a specified user. This will only work if your account has "encountered" the user before (for example, after archiving a group), you can specify User ID or @ username. If looking up by username, it's not always necessary for your account to have already seen the user.

$ telepathy -t 0123456789 -u $ telepathy -t @test_user -u

elabdi commented 1 year ago

thank you Jordan i corrected it now and it doesn't return any errors but I think its not working for me i tried many users but i only get this message : User not found, this is likely because Telepathy has not encountered them yet

aaarghhh commented 1 year ago

Hi @elabdi, I think your version is an old one, the nickname search was introduced in last upgrades. Could you try to upgrade the Telepathy to the last release?

elabdi commented 1 year ago

thank you for your response, nope im using 2.3.2 and no success for me to make it run successfully

aaarghhh commented 1 year ago

ups, sorry I saw the log you provided.

  ______     __                 __  __
 /_  __/__  / /__  ____  ____ _/ /_/ /_  __  __
  / / / _ \/ / _ \/ __ \/ __ `/ __/ __ \/ / / /
 / / /  __/ /  __/ /_/ / /_/ / /_/ / / / /_/ /
/_/  \___/_/\___/ .___/\__,_/\__/_/ /_/\__, /
               /_/                    /____/
-- An OSINT toolkit for investigating Telegram chats.
-- Developed by @jordanwildon | Version 2.2.62.

As you can see there is Version 2.2.62.

elabdi commented 1 year ago

Yes i updated when you've told me there is a new version but no success 😑

nhman482 commented 1 year ago

how i fix it?

Traceback (most recent call last): File "/home/name/.local/bin/telepathy", line 8, in sys.exit(cli()) File "/home/name/.local/lib/python3.10/site-packages/click/core.py", line 829, in call return self.main(args, kwargs) File "/home/name/.local/lib/python3.10/site-packages/click/core.py", line 782, in main rv = self.invoke(ctx) File "/home/name/.local/lib/python3.10/site-packages/click/core.py", line 1066, in invoke return ctx.invoke(self.callback, ctx.params) File "/home/name/.local/lib/python3.10/site-packages/click/core.py", line 610, in invoke return callback(args, **kwargs) File "/home/name/.local/lib/python3.10/site-packages/telepathy/telepathy.py", line 1740, in cli client.loop.run_until_complete(main()) File "/usr/lib/python3.10/asyncio/base_events.py", line 646, in run_until_complete return future.result() File "/home/name/.local/lib/python3.10/site-packages/telepathy/telepathy.py", line 1452, in main print_shell("group_stat", report_obj) File "/home/name/.local/lib/python3.10/site-packages/telepathy/utils.py", line 265, in print_shell " ├ Top poster 5: ", str(obj.poster_five) AttributeError: 'Object' object has no attribute 'poster_five'. Did you mean: 'poster_four'?

jevgen commented 1 year ago

same issue. Telepathy | Version 2.3.2., python3.10 Traceback (most recent call last): File "/opt/homebrew/bin/telepathy", line 8, in sys.exit(cli()) File "/opt/homebrew/lib/python3.10/site-packages/click/core.py", line 829, in call return self.main(*args, **kwargs) File "/opt/homebrew/lib/python3.10/site-packages/click/core.py", line 782, in main rv = self.invoke(ctx)

etc.. Looks like Telepathy script does not retrieve information for groupChat_id, only channel IDs can be targeted

LessDigital13 commented 1 year ago

Yes i updated when you've told me there is a new version but no success 😑

@elabdi @aaarghhh only 2.0.0 populates when I set up and run Telepathy?

How does one download/run the latest version? (Sorry, I'm new to this.)

aaarghhh commented 1 year ago

@LessDigital13 I clone the repository and use a virtualenv to maintain my system clean, so I activate the venv and from there I run the command for example:

Telepathy/src/telepathy/telepathy.py -t target -c

I don't use it as a global package.


@elabdi , what is the issue you are referring for? You updated the banner but the stacktrace is the previous one.

Can you update it, in this version on line 407 there is code that seems unrelated to your issue. https://github.com/jordanwildon/Telepathy/blob/4f166c053b0a0f2a067dbf528545dcc65f0e0b6e/src/telepathy/telepathy.py#L407


@Shopimisrel

There is a bug, I fixed it. I'll try to PR the fix in this couple of next days.

proseltd commented 1 year ago

Closing this issue in accordance with the new release, but feel free to reopen it if you still have any issues!