• The Forgejo feature that would be most useful to me would be some kind of scraper mitigation. I may have missed something, but I am having to do mitigations at the level of the web server that is proxying it.


    score 1 · canonical

    • lobsters__wjt@crustaceanson.theshelf.topM
      link
      fedilink
      arrow-up
      1
      ·
      22 days ago

      How does it interact with Git LFS?

      GitHub has a sort of mirror-image feature where, when creating a PR from a fork to upstream, the PR creator can allow upstream maintainers to push changes back to the PR’s source branch in the fork. However, this does not work correctly if Git LFS is involved. My understanding is that the issue is that, while the git push permission is scoped to the PR’s source branch, pushing LFS objects back to the fork is all-or-nothing, so GitHub chooses nothing rather than allowing upstream to balloon the fork’s LFS storage. (Basically once an object is in LFS you can never safely remove it, lest some old ref point to it.) This is super-annoying for our open-source game where the maintainers routinely need to fix miscellaneous issues in less-experienced contributors’ PRs prior to merge.

      IIUC the AGit flow is conceptually reversed: a contributor without general write access to the upstream repo can push to specific refs in the upstream repo. Can they also push Git LFS objects? If so, how do you avoid contributors consuming unbounded LFS storage in the upstream? If not, … alas, it was a wonderful dream. :)


      Edit: and I’d love to see someone document how to use the AGit flow with jj on the client-side. It seems perfectly suited for the no-named-branches workflow.


      score 1 · canonical

      • Agit should work over ssh with git lfs (I could only find issues with http). I did not change anything here, but I know that LFS changes are being made.

        git lfs objects impacts the storage like normal git objects (even though the underlying storage may have another quota).

        In Forgejo (unlike github afaik) forks completely duplicate this storage. Having Agit PR (unlike fork-based PRs) allows to prevent this useless duplication (from a hoster point of view).

        From a repo owner point of view, it balloons the storage (like a fork-based PR), but since you are now allowed to (force) push to the PR, you should be able to cleanup those objects (from LFS as well once they have been made unreachable).

        I am not well versed into the LFS topic and I think it would be great if you could give this a try and report your experience ! https://v16.next.forgejo.org/ (if you plan to upload a large repo, please ping in matrix first, to not get banned :)


        JJ does not support agit at all yet: https://github.com/jj-vcs/jj/issues/4388


        score 1 · canonical