darkdragn / party

A quick *.party downloader
84 stars 12 forks source link

Error with emoji's #22

Closed UchiSasuke closed 8 months ago

UchiSasuke commented 8 months ago

Hi I am trying to download content from coomer (onlyfans) using this tool, but i am getting an error that emoji's probably can't be parsed.

final = False β”‚ β”‚ β”‚ β”‚ input = '[{"id":"790805353","user":"vaniitys","service":"onlyfans","title":"πŸŽƒHAPPY β”‚ β”‚ β”‚ β”‚ HALLOW'+25238 β”‚ β”‚ β”‚ β”‚ self = <encodings.cp1252.IncrementalEncoder object at 0x000001DF1F948650>

UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f383' in position 67: character maps to undefined

I tried with --post-id and --no-post-title but that didn't work sadly enough.

darkdragn commented 8 months ago

Yeah, that's exactly the problem... But since you included the user info, I can use it as a test and figure out at what point I should strip the emoji's from things to get it working. Just having lunch with my wife (I just woke up), give me a little bit to get around to that. Be on the look out for a new release later.

darkdragn commented 8 months ago

So, I just checked on my end and it ran without any issue. But, that is probably because I'm running linux for everything.

darkdragn@dragnDesk [07:16:47 PM] [/media/dumpCrypt/Documents/src/personal/party] [main *]
-> % party coomer onlyfans vaniitys -e m4v -e mp4 --limit 4 --post-title
2023-11-03 19:17:50.362 | DEBUG    | party.cli:pull_user:114 - Excluded Extensions: ['m4v', 'mp4']
Downloading from user: vaniitys
  0%|                                                                                                                                                               | 0/4 [00:00<?, ?it/s]
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒ
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._80865203-1db0-484b-9272-75642612f724.jpg:   0%|                                     | 0.00/1.96M [00:00<?, ?b/s]
Can I be your favorite Halloween treat??.._80865203-1db0-484b-9272-75642612f724.jpg:   2%|β–‹                            | 47.7k/1.96M [00:00<00:06, 324kb/s]   | 0.00/1.69M [00:00<?, ?b/s]
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒkness to spread..😈😈😈_672fe494-0b3f-44d7-8d94-4bcf8938db60.jpg:   3%|β–ˆβ–Ž                                               | 47.7k/1.69M [00:00<00:05, 320kb/s]
Can I be your favorite Halloween treat??.._80865203-1db0-484b-9272-75642612f724.jpg:   6%|β–ˆβ–‹                            | 112k/1.96M [00:00<00:05, 339kb/s]2k/1.69M [00:00<00:04, 380kb/s]
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:   0%|                                     | 0.00/1.81M [00:00<?, ?b/s]
Can I be your favorite Halloween treat??.._80865203-1db0-484b-9272-75642612f724.jpg:  11%|β–ˆβ–ˆβ–ˆβ–Ž                          | 224k/1.96M [00:00<00:03, 559kb/s]
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒkness to spread..😈😈😈_672fe494-0b3f-44d7-8d94-4bcf8938db60.jpg:  13%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–                                           | 224k/1.69M [00:00<00:02, 543kb/s]
Can I be your favorite Halloween treat??.._80865203-1db0-484b-9272-75642612f724.jpg:  22%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹                       | 448k/1.96M [00:00<00:01, 934kb/s]
 25%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š                                                                                                                 | 1/4 [00:04<00:14,  4.85s/it]
Can I be your favorite Halloween treat??.._80865203-1db0-484b-9272-75642612f724.jpg:  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰                | 896k/1.96M [00:00<00:00, 1.68Mb/s]
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒ                                                                                                                                                            
 50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ                                                                           | 2/4 [00:04<00:04,  2.06s/it]

100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 4/4 [00:09<00:00,  2.48s/it]
2023-11-03 19:18:30.173 | INFO     | party.cli:pull_user:199 - Output status: Counter({<StatusEnum.SUCCESS: 1>: 4})    | 896k/1.81M [00:00<00:00, 1.67Mb/s]

Emoji's messed with my terminal output, but were fine for file names and parsing. Are you running on windows? Or if you could give me any other info about your set up that might help me isolate the problem you're running into.

Please include: python version, OS version, storage filesystem format and maybe if you want a pip freeze. Also, let me know if you used any of those weird/off the wall isolation systems like anaconda

darkdragn commented 8 months ago

(I just updated the above comment to request information, but if you're reading it from your e-mail you probably won't get the update so I'm going to add that in another comment too, >_<

Please include: python version, OS version, storage filesystem format and maybe if you want a pip freeze. Also, let me know if you used any of those weird/off the wall isolation systems like anaconda)

mitchellchris1 commented 8 months ago

I executed the command and obtained the following results:

% party coomer onlyfans vaniitys -e m4v -e mp4 --limit 4 --post-title
2023-11-03 16:22:12.643 | DEBUG    | party.cli:pull_user:114 - Excluded Extensions: ['m4v', 'mp4']
Downloading from user: vaniitys
  0%|                                                                                            | 0/4 [00:00<?, ?it/s]
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒ
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:   0
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:   3
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:   466.jpg:   0%| | 0.00/1.74M [00:
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:   966.jpg:   3%| | 47.7k/1.74M [00
Can I be your favorite Halloween treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:  1266.jpg:   7%| | 128k/1.74M [00:
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒ
Can I be your favorite Halloween treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:  1766.jpg:  13%|▏| 224k/1.74M [00:
 25%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ                                                               | 1/4 [00:05<00:17,  5.95s/it]
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._a8902848-f6da-497b-a24a-60aaffa87e53.jpg:  3266.jpg:  25%|β–Ž| 448k/1.74M [00:
 50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ                                          | 2/4 [00:06<00:05,  2.52s/it]

vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒ
vaniitys/πŸŽƒHAPPY HALLOWEEN!!πŸŽƒen treat??.._80865203-1db0-484b-9272-75642612f724.jpg:   4
vaniitys/There’s A LOT of thickness to spread..😈😈😈_672fe494-0b3f-44d7-8d94-4bcf8938db60.jpg:   3%| | 47.7k/1.69M [00
vaniitys/There’s A LOT of thickness to spread..😈😈😈_672fe494-0b3f-44d7-8d94-4bcf8938db60.jpg:   6%| | 95.7k/1.69M [00
vaniitys/There’s A LOT of thickness to spread..😈😈😈_672fe494-0b3f-44d7-8d94-4bcf8938db60.jpg:  20%|▏| 352k/1.69M [00:
vaniitys/There’s A LOT of thickness to spread..😈😈😈_672fe494-0b3f-44d7-8d94-4bcf8938db60.jpg:  26%|β–Ž| 448k/1.69M [00:
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 4/4 [00:08<00:00,  2.16s/it]
2023-11-03 16:22:39.019 | INFO     | party.cli:pull_user:207 - Output status: Counter({<StatusEnum.SUCCESS: 1>: 4}) 

I'm running macOS.

darkdragn commented 8 months ago

Thank you so much @mitchellchris1 ! Seems like with your results I can narrow the encoding error down to Windows, and borrow my wife's computer later to work on it.

mitchellchris1 commented 8 months ago

Awesome! I'm glad I could help!

UchiSasuke commented 8 months ago

Hi glad someone else also jumped in :) I am using Windows 11, cloned the repo and run the installer. Only difference is that I run Python 3.12 instead of .11 so I needed to use a beta version of the aiohttp (v 3.9.0b0) otherwise the installer couldn't finish.

darkdragn commented 8 months ago

Sweet, my night was a bit spoken for by an 8 month old Malinois rescue who was a bit scared of sleeping alone, so my lawn chair got some use, lol.

I'll take a break from working with her on socializing with my dogs, and look into it with my wife's computer. Shouldn't take too long. I'm just debating squashing emojis universally or OS checking and restricting that to windows only.

darkdragn commented 8 months ago

Also, @UchiSasuke , awesome that you figured out the beta aiohttp was necessary. They committed the changes for Python 3.12 over 3 months ago and still haven't pushed a stable release, '>_<'

And, in response to the assistance, yeah @mitchellchris1 is pretty awesome for providing help. I had to give you props again, man!

darkdragn commented 8 months ago

So, @UchiSasuke, things are a bit different than I thought. I had a little bit of the debug item I'm about to remove that was majorly crashing it. But, yaspin, the progress spinner I just use to let people know it is doing something in the background, is the main culprit. So, I'm going to dig into yaspin and see if there's a windows fix or if I should just remove it for windows users.

darkdragn commented 8 months ago

There we go! Should be fixed with release v0.6.5. I still wouldn't use --post-title on windows, lol, but the cli is running smooth. I fixed yaspin on windows, and made sure the debug item that was causing the crash for you is pulled. (I had it in the wrong place anyway, lol.)

Check it out, and tell me what you think!

UchiSasuke commented 8 months ago

Thank you for fixing it! I haven't been able to test it yet! But thank you for your time :D