Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"missing groupId" error downloading messages #90

Open
spaghetti-ii opened this issue Sep 23, 2024 · 37 comments
Open

"missing groupId" error downloading messages #90

spaghetti-ii opened this issue Sep 23, 2024 · 37 comments

Comments

@spaghetti-ii
Copy link

IMPORTANT: Be sure to replace all {{ template sections ⚠️}} or your issue may be discarded.

Bug Description

Program fails to download any media from messages and fails with "Response code: 400".

ErrorScreenshot

Expected behavior

Media from messages are downloaded without error.

Actual behavior

Error is thrown and messages are not process. Scrape can continue by hitting enter, but only downloads content from timeline.

Environment Information

  • Operating System: Windows 10
  • Fansly Downloader Version: happens on v0.9.7 and v0.9.9
  • Fansly Downloader Type: executable
  • Specific creators name: all creators

User Research

( fill [ ] with x, if you've already done said task )

I have done the following:

Additional context

Issue seems to be a change with Fansly requiring groupId on messages. Happened recently that I noticed (within 1-2 weeks) since time of writing.

@PsychoSid
Copy link

fwiw I get this too (v0.9.7)

@oksndr
Copy link

oksndr commented Sep 23, 2024

Getting the same error, tried with "Timeline", "Post" and "Collection" and it worked, "Normal" and "Messages" it's when it fails.

@PsychoSid
Copy link

I don't get the error with collection but I have some collections and nothing is downloaded from them ? Do they have to be in a collection with a specific name ?

@oksndr
Copy link

oksndr commented Sep 24, 2024

I don't get the error with collection but I have some collections and nothing is downloaded from them ? Do they have to be in a collection with a specific name ?

"Collection" option is to download what you have purchased and can be seen at https://fansly.com/collection

Any collection you have created by selecting and organizing your videos is not part of the "Collection" option

@bssoul
Copy link

bssoul commented Sep 25, 2024

I get the same error with messages. with both 9.3 & 9.7
I had no luck with 9.9 when it came out & those two were working so I just used them

@FabulousSoldier
Copy link

I get the same error with messages on v0.9.9

@lordoffools
Copy link

lordoffools commented Sep 26, 2024

Can confirm that I'm seeing the same issue with messages. Reproduces consistently across all creators.

 Info | 07:59 || Initiating Messages procedure. Standby for results.
 [31]ERROR | 07:59 || Failed Messages download. Response code: 400
{"success":false,"error":{"code":99,"details":"missing groupId"}}

This only happens with Messages content.

@lordoffools
Copy link

Gentle nudge to @prof79. Thank you very much!!

@Gnuclear
Copy link

Gnuclear commented Sep 26, 2024

I figured out how to fix this.

in /api/fansly.py, change the url in the get_group function:
old url: https://apiv3.fansly.com/api/v1/group
new url: https://apiv3.fansly.com/api/v1/messaging/groups

in /download/messages.py, change this line:
groups_response = groups_response.json()['response']['groups']
to this:
groups_response = groups_response.json()['response']['aggregationData']['groups']

@ZincStoat
Copy link

I figured out how to fix this.

You absolute star!

@bssoul
Copy link

bssoul commented Sep 26, 2024

I figured out how to fix this.

in /api/fansly.py, change the url in the get_group function: old url: https://apiv3.fansly.com/api/v1/group new url: https://apiv3.fansly.com/api/v1/messaging/groups

in /download/messages.py, change this line: groups_response = groups_response.json()['response']['groups'] to this: groups_response = groups_response.json()['response']['aggregationData']['groups']

Where do we change that?

@jmennAcc
Copy link

I figured out how to fix this.

in /api/fansly.py, change the url in the get_group function: old url: https://apiv3.fansly.com/api/v1/group new url: https://apiv3.fansly.com/api/v1/messaging/groups

in /download/messages.py, change this line: groups_response = groups_response.json()['response']['groups'] to this: groups_response = groups_response.json()['response']['aggregationData']['groups']

I can confirm that these changes work (v0.9.9).
Thank you very very much!

@bssoul
Copy link

bssoul commented Sep 26, 2024

Can someone explain to me how to make those changes. In my folder for the 9.3 version this is all I have
Capture

@oksndr
Copy link

oksndr commented Sep 26, 2024

When running the fansly_downloader_ng.py I get the following error, someone else? Or someone who could share the .exe for 9.7 or 9.9?

Python 3.11.0 (main, Oct 24 2022, 18:26:48) [MSC v.1933 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license()" for more information.

= RESTART: D:\folder\Fansly_Downloader_NG-Windows-v0.9.7\fansly-downloader-ng-main\fansly_downloader_ng.py Traceback (most recent call last): File "D:\folder\Fansly_Downloader_NG-Windows-v0.9.7\fansly-downloader-ng-main\fansly_downloader_ng.py", line 37, in <module> from config import FanslyConfig, load_config, validate_adjust_config File "D:\folder\Fansly_Downloader_NG-Windows-v0.9.7\fansly-downloader-ng-main\config\__init__.py", line 4, in <module> from .config import copy_old_config_values, load_config File "D:\folder\Fansly_Downloader_NG-Windows-v0.9.7\fansly-downloader-ng-main\config\config.py", line 12, in <module> from config.fanslyconfig import FanslyConfig File "D:\folder\Fansly_Downloader_NG-Windows-v0.9.7\fansly-downloader-ng-main\config\fanslyconfig.py", line 9, in <module> from config.modes import DownloadMode File "D:\folder\Fansly_Downloader_NG-Windows-v0.9.7\fansly-downloader-ng-main\config\modes.py", line 3, in <module> from strenum import StrEnum ModuleNotFoundError: No module named 'strenum'

@ZincStoat
Copy link

When running the fansly_downloader_ng.py I get the following error, someone else? Or someone who could share the .exe for 9.7 or 9.9?

To install the required python support modules (for Windows) you need to run pip3 install -r requirements.txt from the folder where fansly-downloader-ng.py is located

The exe's are available from the Releases page, but they haven't been updated with the fix for this issue yet, so running the Python app is your best option for now.

@oksndr
Copy link

oksndr commented Sep 26, 2024

When running the fansly_downloader_ng.py I get the following error, someone else? Or someone who could share the .exe for 9.7 or 9.9?

To install the required python support modules (for Windows) you need to run pip3 install -r requirements.txt from the folder where fansly-downloader-ng.py is located

The exe's are available from the Releases page, but they haven't been updated with the fix for this issue yet, so running the Python app is your best option for now.

Already did it, followed the instructions at main page

@Gnuclear
Copy link

Gnuclear commented Sep 27, 2024

When running the fansly_downloader_ng.py I get the following error, someone else? Or someone who could share the .exe for 9.7 or 9.9?

line 3, in from strenum import StrEnum ModuleNotFoundError: No module named 'strenum'`

path\to\python.exe -m pip install strenum

@oksndr
Copy link

oksndr commented Sep 27, 2024

When running the fansly_downloader_ng.py I get the following error, someone else? Or someone who could share the .exe for 9.7 or 9.9?
line 3, in from strenum import StrEnum ModuleNotFoundError: No module named 'strenum'`

path\to\python.exe -m pip install strenum

Thanks man, when running it I got the message that I already had installed, however it pointed the directory, being in "Python\Python39\Lib\site-packages" so figured the modules were in the wrong folder.

Manually copied them one by one as the downloader was requesting for them until it run, but wasn't finding any new messages. Made the mistake of copying the entire folder from "Python39" to "Python311" and it broke, decided to uninstall "Python39" and "Python38", run the "pip install -r requirements.txt" and this time it updated the "Python312" folder, which ultimately let me run the "fansly_downloader_ng.py" using "Messages" download mode.

@lordoffools
Copy link

Hmm, so can anyone confirm that the fix above actually pulls media in Messages? It made the error go away, but it also consistently results in this:

Info | 04:54 || Initiating Messages procedure. Standby for results.
WARNING | 04:54 || Could not find a chat history with xxxxxx; skipping messages download ...

This is despite the fact there's several media (video and photos) available in Messages with that particular creator for download (unlocked, free, available).

@PsychoSid
Copy link

It is working for me with messages on v0.9.9

@lordoffools
Copy link

It is working for me with messages on v0.9.9

Hmm, very strange. I'm running v0.9.9 with the fix noted above, as well.

Consistently able to reproduce it not working (with the same warning/error from above) across multiple creators.

I'll keep playing with it.

@lordoffools
Copy link

Interesting! I was able to trigger a scrape and download of media in Messages only after I generated some chat history with the creator myself first, despite there being history coming from them, otherwise the script concluded there was no chat history (per the warning/error message above).

Very strange. It wasn't always behaving this way -- only after it broke, and following the fix from above.

@Gnuclear
Copy link

Gnuclear commented Sep 27, 2024

Maybe try this url for the API:
https://apiv3.fansly.com/api/v1/messaging/groups?limit=1000&ngsw-bypass=true

I realized that the api by default only returns 20 results, so the group might not have been found because the messages you wanted were older. And by writing a new message, it bumped it up (and replaced one of the 20 results it was returning).

So, the solution should just be to ask for more results. Either in one go by adding ?limit=1000&ngsw-bypass=true

Or if that were to stop working, it might have to make multiple requests, with ?offset=0&ngsw-bypass=true, and increase offset by 20 each request

@lordoffools
Copy link

Hmm, with the fix noted above, it's no longer scraping, counting, and downloading messages.

Anyone else experiencing this issue - again?

@prof79

@lordoffools
Copy link

lordoffools commented Sep 28, 2024

Switching from https://apiv3.fansly.com/api/v1/messaging/groups to https://apiv3.fansly.com/api/v1/messaging/groups?limit=1000&ngsw-bypass=true has worked.

Thanks, @Gnuclear!

@cenax
Copy link

cenax commented Sep 29, 2024

How do i fix this while using the .exe?

@pzych0p4th
Copy link

pzych0p4th commented Oct 5, 2024

I am terrible sorry, but does anyone have the patience to try and explain this like its a 5 year old, I am really not getting everything here, I am usually fairly decent around what I am doing, but this is a little too deep for me.
Ive tried running the pip3 install -r requirements.txt command but it gives me an error with building wheel.
Building wheel for plyvel-ci (pyproject.toml) error: subprocess-exited-with-error and a whole lot after that too.
I have Python 3.12.6 installed, also Visual C++ 14 or above, so I am not sure what Im doing wrong, and honestly I dont even know what the pip3 install -r requirements.txt does, lmao.
Does it allow me to run the fansly_downloader_ng.py as if it were the exe or am I completely off?

@PsychoSid
Copy link

PsychoSid commented Oct 5, 2024

I don't know about Windows so I cannot help too much with the OS there. But one thing is common and that is how terrible Python packaging is. I had to install packages then the install the pip/wheels via the requirements.txt which is a list of modules used by the scripts here

pip install --upgrade pip setuptools wheel
sudo apt-get install python-dev python3-dev libleveldb-dev  python3.12-tk

This is running under a 3.12.x venv and then it got everything working.

@pzych0p4th
Copy link

pzych0p4th commented Oct 5, 2024

I think I got all the packages installed manually with the pip install command, also did the pip install --upgrade pip setuptools wheel, but I dont understand the sudo apt-get install python-dev python3-dev libleveldb-dev python3.12-tk, it isnt recognized.
Oh well, I think Ill just wait for an actual update where this might get fixed. 🙏🏻👌🏻

@PsychoSid
Copy link

Those apt-get commands are for Ubuntu/Debian linux only. You will need the equivalents for your OS

@bssoul
Copy link

bssoul commented Oct 5, 2024

I think I got all the packages installed manually with the pip install command, also did the pip install --upgrade pip setuptools wheel, but I dont understand the sudo apt-get install python-dev python3-dev libleveldb-dev python3.12-tk, it isnt recognized. Oh well, I think Ill just wait for an actual update where this might get fixed. 🙏🏻👌🏻

I don't have any inside information but I do not believe their will be another update. I think prof79 is done with it. I hope their is but I don't believe their will be.

@WX93623
Copy link

WX93623 commented Oct 9, 2024

just me or some videos dont even fully download anymore despite having a subscription to the creator ? :/

@juntrone
Copy link

juntrone commented Oct 10, 2024

I am terrible sorry, but does anyone have the patience to try and explain this like its a 5 year old, I am really not getting everything here, I am usually fairly decent around what I am doing, but this is a little too deep for me. Ive tried running the pip3 install -r requirements.txt command but it gives me an error with building wheel. Building wheel for plyvel-ci (pyproject.toml) error: subprocess-exited-with-error and a whole lot after that too. I have Python 3.12.6 installed, also Visual C++ 14 or above, so I am not sure what Im doing wrong, and honestly I dont even know what the pip3 install -r requirements.txt does, lmao. Does it allow me to run the fansly_downloader_ng.py as if it were the exe or am I completely off?

@pzych0p4th I was having the same issue with not being able to build the wheel or whatever and had almost given up. Commenting out the lines mentioned in this thread: #84 fixed everything and let me run the program as normal.

@Bun-Bun
Copy link

Bun-Bun commented Nov 19, 2024

Maybe try this url for the API: https://apiv3.fansly.com/api/v1/messaging/groups?limit=1000&ngsw-bypass=true

I realized that the api by default only returns 20 results, so the group might not have been found because the messages you wanted were older. And by writing a new message, it bumped it up (and replaced one of the 20 results it was returning).

So, the solution should just be to ask for more results. Either in one go by adding ?limit=1000&ngsw-bypass=true

Or if that were to stop working, it might have to make multiple requests, with ?offset=0&ngsw-bypass=true, and increase offset by 20 each request

This plus the other change in downloader.py worked great for me.

@jeffwhite6557
Copy link

I've been following along and trying to create a source code environment on a Win11 PC. The remaining error on installing all is that I cannot seem to get the plyvel-ci wheel to install. Has anyone built a win11 system using the source code and gotten it to work? Little words work best if you know how to help me, :-)

@WindyRiser
Copy link

Unfortunately, I'm too code-illiterate to understand Python mechanics properly and build an exe out of it, so if anyone can send a fixed version my way, I'll be immeasurably thankful.

@bssoul
Copy link

bssoul commented Dec 28, 2024

I've never gotten this working, I do have 9.3 working & only work it in single mode. This works well also
https://www.downloadhelper.net/ it's $18 bucks,and only for video/gif no pics a chrome extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests