Privacy plugin cannot retrieve GitHub assets #8500
-
|
Hey! Does anyone know why the Privacy plugin can retrieve some GitHub assets without any problems, but not others? Example: The thing is, it's always the same URLs where the Privacy plugin fails. These are all assets that were uploaded recently. Assets from a few months ago work fine. So it seems as if GitHub has changed something in the backend, which now means that the Privacy plugin from Mkdocs Material can no longer be used. Perhaps it is due to the user agent or something similar. Does anyone have similar experiences and a workaround? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Hello @robingenz, In general GitHub doesn't want to be a free file hosting platform, and these links redirect to a AWS hosted file with a temporary token. If it's confirmed that the second link doesn't load without proper auth, you could patch the privacy plugin to use your GitHub login cookies, but this also is a temporary solution 🤔 A proper solution could be some kind of API call with your own OAuth credentials, but I'm not sure if GitHub supports such case. Also what are these files anyway? The first one is a GIF, so did you perhaps edit the Markdown file and copy/paste the file in there, and during the copy/paste the file got sent over as an attachment? If these files are part of your own docs repository, I think you can just add the files next to the Markdown file and reference them with a relative local path 🤔 |
Beta Was this translation helpful? Give feedback.
Hello @robingenz,
404 in GitHub often means 403 as well. When I try to load the links above in my browser with my GitHub account it only loads the first one, second gets me a 404. So, I assume the second link is somewhat private only visible for you, it's not due to User-Agent.
In general GitHub doesn't want to be a free file hosting platform, and these links redirect to a AWS hosted file with a temporary token.
If it's confirmed that the second link doesn't load without proper auth, you could patch the privacy plugin to use your GitHub login cookies, but this also is a temporary solution 🤔 A proper solution could be some kind of API call with your own OAuth credentials, but I'm not sure …