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

add doc update to build script #196

Closed
sgosline opened this issue Jul 9, 2024 · 6 comments
Closed

add doc update to build script #196

sgosline opened this issue Jul 9, 2024 · 6 comments
Assignees

Comments

@sgosline
Copy link
Member

sgosline commented Jul 9, 2024

Current build script will push to figshare but not update the link on the doc page. how do i get this to be included in build_all.py?

@sgosline sgosline self-assigned this Jul 9, 2024
@jjacobson95
Copy link
Collaborator

This might be another one where we'd have to use GitHub web-hooks to trigger an action? To update the doc page, we need to run GitHub Actions and the updated link would have to be provided somewhere online. This could potentially be retrieved from the PyPI package.

@jjacobson95
Copy link
Collaborator

I thought of some other options for this - bitly and tinyurl allow for the creation of links whose destination can be updated. However, both cost money (minimum $8-10 a month). I haven't found any free versions that could work for us. But it did make me realize that we might be able to build a redirect service/page.

So our docs would be linked to this separate redirect page. And when users visit this page, they are immediately redirected to the latest figshare version.

Advantage: We wouldn't have to modify our current docs page and risk any breaking changes.
Disadvantage: We would still have to modify a github page with the updated link. And there would be some time setting this up.

@sgosline
Copy link
Member Author

sgosline commented Sep 6, 2024

I dont understand, cant the build_all.py script just modify the text of the docs? They're in the repo, correct?

@jjacobson95
Copy link
Collaborator

Yes, but there are more steps needed.

The full code would have to do the following:

  • Retrieve the latest version of the Figshare link
    • Currently this is done by pushing data to figshare and extracting the link from the Figshare upload response written to figshare_latest.yaml.
  • Modify the text of the docs
  • Commit this change, set upstream to main (or a newly specified docs branch), and push the change back to github.
    • We'd need to add 'GITHUB_AUTH_TOKEN' to the environment.
  • Trigger a github action to rebuild the docs.

If we have a specific docs branch, we could make it so changes to the branch automatically trigger github actions to rebuild the page.

All of this can be done, I just wasn't sure if we wanted build_all.py to push updates to our GitHub repo.

@sgosline
Copy link
Member Author

sgosline commented Sep 6, 2024

It sounds like the main issue is the dependency on github actions. If we remove that, we can do everything else in a script. If we decide to use github actions again, we can just have it call the script. Anyway, this is not a huge priority atm.

@jjacobson95
Copy link
Collaborator

This issue was resolved with the versioning code. However there is a new related issue #216.

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

No branches or pull requests

2 participants