Skip to content

X (formerly Twitter) cannot be checked nor addedΒ #2253

@DZAladan

Description

@DZAladan

Checklist

  • I'm reporting a bug in Maigret functionality
  • I've checked for similar bug reports including closed ones
  • I've checked for pull requests that attempt to fix this bug

Description

Info about Maigret version you are running and environment (--version, operation system, ISP provider):

  • maigret 0.5.0
  • Socid-extractor: 0.0.27
  • Aiohttp: 3.13.2
  • Requests: 2.32.5
  • Python: 3.13.3
  • Operating system: Kali Linux 2025.2 (Virtual Machine)
  • Provider: Linkem (Italy)

How to reproduce this bug (commandline options / conditions):

Checking: maigret {username} --site Twitter or maigret {username} --site X
Adding website: maigret --submit https://x.com/{username}

The website X.com (formerly Twitter.com) is impossible to check as it isn't included in Maigret's database and the software doesn't recognize redirects (inputting https://twitter.com/ in a browser redirects to https://x.com/ now), resulting in the website being constantly skipped even with the option --site Twitter and despite the account existing.

Additionally, X.com cannot be submitted either as Maigret doesn't allow adding it as a new website nor adding it to a pre-existing website not included in the options it "believes" are correct, and will return the following instead (note that, in this copy-paste, I replaced the username I was looking for with the {username} placeholder in the command):

maigret --submit https://x.com/{username}      
[!] Sites with domain "x.com" already exists in the Maigret database!
500px 
        https://500px.com/
        https://500px.com/p/{username}
Affiliatefix (disabled)
        https://www.affiliatefix.com
        {urlMain}{urlSubpath}/members/?username={username}
Empflix (disabled)
        https://www.empflix.com
        https://www.empflix.com/profile/{username}/
Friendfinder-x (disabled)

        https://www.friendfinder-x.com/profile/{username}
Macosx 
        https://macosx.com
        {urlMain}{urlSubpath}/members/?username={username}
Mix 
        https://mix.com
        https://mix.com/{username}
Roblox (disabled)
        https://www.roblox.com/
        https://www.roblox.com/user.aspx?username={username}
Screwfix 
        https://community.screwfix.com
        {urlMain}{urlSubpath}/members/?username={username}
Wix 
        https://wix.com/
        https://{username}.wix.com
1x 
        https://1x.com
        https://1x.com/{username}
www.hsx.com (disabled)
        https://www.hsx.com
        https://www.hsx.com/profile/{username}
forum.languagelearningwithnetflix.com (disabled)
        https://forum.languagelearningwithnetflix.com
        {urlMain}/u/{username}/summary
mineplex.com (disabled)
        https://www.mineplex.com
        {urlMain}{urlSubpath}/members/?username={username}
www.itemfix.com 
        https://www.itemfix.com
        https://www.itemfix.com/c/{username}
v2ex.com 

        https://v2ex.com/member/{username}
Pixwox 
        https://www.pixwox.com
        https://www.pixwox.com/profile/{username}/
www.tnaflix.com (disabled)
        https://www.tnaflix.com
        https://www.tnaflix.com/profile/{username}
[?] Do you want to continue? [yN] y
[?] Which site do you want to update in case of success? 1st by default. [500px, Affiliatefix, Empflix, Friendfinder-x, Macosx, Mix, Roblox, Screwfix, Wix, 1x, www.hsx.com, forum.languagelearningwithnetflix.com, mineplex.com, www.itemfix.com, v2ex.com, Pixwox, www.tnaflix.com] Twitter      
Traceback (most recent call last):
  File "/home/kali/.local/bin/maigret", line 7, in <module>
    sys.exit(run())
             ~~~^^
  File "/home/kali/.local/share/pipx/venvs/maigret/lib/python3.13/site-packages/maigret/maigret.py", line 779, in run                                                                             
    asyncio.run(main())
    ~~~~~~~~~~~^^^^^^^^
  File "/usr/lib/python3.13/asyncio/runners.py", line 195, in run
    return runner.run(main)
           ~~~~~~~~~~^^^^^^
  File "/usr/lib/python3.13/asyncio/runners.py", line 118, in run
    return self._loop.run_until_complete(task)
           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
  File "/usr/lib/python3.13/asyncio/base_events.py", line 719, in run_until_complete
    return future.result()
           ~~~~~~~~~~~~~^^
  File "/home/kali/.local/share/pipx/venvs/maigret/lib/python3.13/site-packages/maigret/maigret.py", line 553, in main                                                                            
    is_submitted = await submitter.dialog(args.new_site_to_submit, args.cookie_file)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/kali/.local/share/pipx/venvs/maigret/lib/python3.13/site-packages/maigret/submit.py", line 452, in dialog                                                                           
    f'{Fore.GREEN}[+] We will update site "{old_site.name}" in case of success.{Style.RESET_ALL}'
                                            ^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'name'
[base_events.py:1865] ERROR  12:42:14 Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x7f1b1f6b16a0>

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions