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

Files cannot be retrieved programmatically #2

Open
umarcor opened this issue Mar 28, 2023 · 2 comments
Open

Files cannot be retrieved programmatically #2

umarcor opened this issue Mar 28, 2023 · 2 comments

Comments

@umarcor
Copy link

umarcor commented Mar 28, 2023

When curl or get are used to get latest linux-editor-mono or linux-template-minimal, instead of downloading the zipfiles, HTML pages are written. See umarcor@577ee33 and https://github.com/umarcor/godot-commit-artifacts/actions/runs/4548687288/jobs/8019967935:

<!DOCTYPE html>
<html lang="en-US">
  <meta charset="utf-8">
  <title>Redirecting&hellip;</title>
  <link rel="canonical" href="https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309">
  <script>location="https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309"</script>
  <meta http-equiv="refresh" content="0; url=https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309">
  <meta name="robots" content="noindex">
  <h1>Redirecting&hellip;</h1>
  <a href="https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309">Click here if you are not redirected.</a>
</html>
--2023-03-28 23:45:11--  https://godotengine.github.io/godot-commit-artifacts/download/godotengine/godot/master/linux-editor-mono
Resolving godotengine.github.io (godotengine.github.io)... 185.199.108.153, 185.199.110.153, 185.199.111.153, ...
Connecting to godotengine.github.io (godotengine.github.io)|185.199.108.153|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://godotengine.github.io/godot-commit-artifacts/download/godotengine/godot/master/linux-editor-mono/ [following]
--2023-03-28 23:45:11--  https://godotengine.github.io/godot-commit-artifacts/download/godotengine/godot/master/linux-editor-mono/
Reusing existing connection to godotengine.github.io:443.
HTTP request sent, awaiting response... 200 OK
Length: 645 [text/html]
Saving to: ‘linux-editor-mono’

     0K                                                       100% 1.95M=0s

2023-03-28 23:45:11 (1.95 MB/s) - ‘linux-editor-mono’ saved [645/645]

<!DOCTYPE html>
<html lang="en-US">
  <meta charset="utf-8">
  <title>Redirecting&hellip;</title>
  <link rel="canonical" href="https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309">
  <script>location="https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309"</script>
  <meta http-equiv="refresh" content="0; url=https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309">
  <meta name="robots" content="noindex">
  <h1>Redirecting&hellip;</h1>
  <a href="https://github.com/godotengine/godot/suites/11869467969/artifacts/620727309">Click here if you are not redirected.</a>
</html>

I though I might download the JSON files (https://github.com/godotengine/godot-commit-artifacts/tree/gh-pages/data), for instance https://godotengine.github.io/godot-commit-artifacts/data/godotengine.godot.master.json, but I can't see how to get the URL from there without reimplementing the logic.

@YuriSizov
Copy link
Contributor

YuriSizov commented Mar 29, 2023

I don't think it's possible to implement a redirect in any other way due to the "serverless" aspect of GH Pages, but I can output a JSON with target links, if it helps.

E.g. it can be some /download/godotengine/godot/master/latest.json with the mapping for artifact name and the URL as a top-level object.

@umarcor
Copy link
Author

umarcor commented Apr 19, 2023

That would certainly help!

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

2 participants