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

fix: load paths to git repositories at start-time; versions endpoint fix #47

Merged
merged 4 commits into from
Jul 24, 2024

Conversation

n-dusan
Copy link
Contributor

@n-dusan n-dusan commented Jul 23, 2024

Fixes to stelae we found on our testing environment.

Two notable changes:

  • Fix to _compare endpoint to not include an additional current date if the request url contains /current.
  • stelae serve command is changed to load paths to git repositories instead of keeping git repository handles open. This makes it so that the command won't fail in cases where data repos aren't on disk. Moreover, if/when data repositories become available on disk, stelae serve will work.

n-dusan added 4 commits July 23, 2024 16:36
Also reduce nesting by early exiting the function if conditions aren't
met.
- Moved `find_blob` to `git/utils/mod.rs` module as `Repo` associated
  function.
- Refactor `RepoState` and `FallbackState` to not keep open handles to
  git repositories. This change makes it so that stelae can serve
  partial stele, and not fail if any data repository is missing from
  `repositories.json`. Handles to git repos are now open at request time instead.
@n-dusan n-dusan added the bug Something isn't working label Jul 23, 2024
@n-dusan n-dusan marked this pull request as ready for review July 23, 2024 15:57
@n-dusan n-dusan requested a review from tombh July 23, 2024 16:06
@n-dusan n-dusan merged commit 851aa0d into main Jul 24, 2024
10 checks passed
@n-dusan n-dusan deleted the ndusan/prerelease-fixes branch July 24, 2024 10:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants