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

feat:RedditSync - Path /u/ requests to use /user/ endpoint #3634

Closed
3 tasks done
garpunkal opened this issue Sep 11, 2024 · 15 comments · Fixed by #3559
Closed
3 tasks done

feat:RedditSync - Path /u/ requests to use /user/ endpoint #3634

garpunkal opened this issue Sep 11, 2024 · 15 comments · Fixed by #3559
Labels
Feature request Requesting a new feature that's not implemented yet

Comments

@garpunkal
Copy link

garpunkal commented Sep 11, 2024

Feature description

Patch Reddit Sync to use /user/ endpoint instead of /u/

https://reddit.com/u/spez/about.json (500 error)

vs

https://reddit.com/user/spez/about.json (works fine)

Motivation

Currently the About section in sync is broken for users because the endpoint provides a 500 error.

It's important because sync breaks on the user profile page.

Acknowledgements

  • I have checked all open and closed feature requests and this is not a duplicate
  • I have chosen an appropriate title.
  • All requested information has been provided properly.
@garpunkal garpunkal added the Feature request Requesting a new feature that's not implemented yet label Sep 11, 2024
@trulow
Copy link

trulow commented Sep 12, 2024

Can I offer a $50 USD bounty for this to be patched?

@oSumAtrIX
Copy link
Member

oSumAtrIX commented Sep 12, 2024

Claiming (I already have changes locally that fix it, because I use Sync myself)

@trulow
Copy link

trulow commented Sep 12, 2024

@oSumAtrIX

I DM'd you on reddit. Once the fix is live, send me your contact info to send the bounty.

@oSumAtrIX
Copy link
Member

Here's the patch in action:

WsaClient_poqZwEQTx1.mp4

@trulow
Copy link

trulow commented Sep 12, 2024

@oSumAtrIX

Thanks! I replied to your DM on reddit btw!

@oSumAtrIX
Copy link
Member

oSumAtrIX commented Sep 12, 2024

Implemented with 46d11f3

@oSumAtrIX oSumAtrIX linked a pull request Sep 12, 2024 that will close this issue
1 task
@DVDAndroid
Copy link

I just checked this issue and my unpatched app and is working fine.
Do you think that this patch will be still needed?

@elmagio
Copy link

elmagio commented Sep 12, 2024

I just checked this issue and my unpatched app and is working fine. Do you think that this patch will be still needed?

Huh that's weird, it also started working again for me, without the new patch. Wasn't working as of an hour ago.

@oSumAtrIX
Copy link
Member

oSumAtrIX commented Sep 12, 2024

It was a known bug on Reddits end confirmed by Reddit devs a couple days ago. It was bound to be fixed like the other login bugs caused by Reddit in the past. (The server returned 500, an internal error). The patch is not needed anymore and can be removed, but it won't make any difference if used.

@trulow
Copy link

trulow commented Sep 12, 2024

Does you new patch have a check to see if the app receives a 500 error, to then use /user instead?

If it does, maybe we can still implement it as a backup.

@oSumAtrIX
Copy link
Member

No, it simply changes the endpoint to /user. I think it's even the "new" endpoint and /u/ is deprecated but exists for backwards compatibility reasons. Should me mentioned in the docs

@trulow
Copy link

trulow commented Sep 12, 2024

I just went over the API docs, and it seems like @oSumAtrIX is correct.

I think we should implement this patch as the API docs only reference /user/ and not /u/

My thinking on this is that it's only a matter of time until /u/ may break again causing another need fix in the future.

What does everyone else think?

@oSumAtrIX
Copy link
Member

It won't make a difference. u/ wont break unless Reddit decides to drop backwards compatibility support at which point dozens of other apis would be broken and would need heavy fixing

@garpunkal
Copy link
Author

I think we should have the patch available. If /user/ is the canonical URL then it gives the option to patch for future use.

@oSumAtrIX
Copy link
Member

I'll keep it for now as it doesn't break anything but maybe the patch should be renamed to what it does, as it's called a fix whereas it doesn't fix current issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature request Requesting a new feature that's not implemented yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants