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

naming hypha 'wiki' results in unexpected behavior #226

Closed
Tracked by #216
oxaliq opened this issue May 1, 2024 · 1 comment
Closed
Tracked by #216

naming hypha 'wiki' results in unexpected behavior #226

oxaliq opened this issue May 1, 2024 · 1 comment

Comments

@oxaliq
Copy link

oxaliq commented May 1, 2024

background

our computer club has been running an instance of mycorrhiza (happily!) that details some of our projects and services, including mycorrhiza itself. the hypha for this was at the root of our instance and called wiki.myco

recently a member attempted to rename this hypha services/wiki (making it a subhypha of the existing services hypha)

the bug

this rename failed and put our mycorrhiza in a "read-only" state. we could still open hyphae, but any attempt to rename or edit any hypha resulted in a server timeout

inspecting the logs yielded

gitsh: exit status 128
out: fatal: '/srv/mycorrhiza/services/wiki.git/services/wiki.myco' is outside repository at '/srv/mycorrhiza/wiki.git'
USER tries to rename 'wiki': exit status 128

within the mycorrhiza directory a new directory tree was created services/wiki.git/services

note wiki.myco was not created in this new directory outside of the git repo

steps to reproduce

from the client:

  • create a hypha named wiki.
  • rename that hypha SUPERHYPHA/wiki

note (i have tested this with multiple super-hyphae and the issue occurred every time)

steps to resolve

i manually moved wiki.myco to mycorrhiza/wiki.git/services/wiki.myco and manually changed all references to this hypha in a text editor before commiting changes (electing not to worry about redirects)

i then restarted the mycorrhiza service and confirmed that edits and renames were then working

i did not attempt to rename wiki again, and will advise others to avoid making this change in the client specifically for this hypha

the offending hypha

https://wiki.bunk.computer/hypha/services/wiki

@bouncepaw
Copy link
Owner

bouncepaw commented May 1, 2024

Thanks for the report. Looking at your club, it looks very cool, I wish the best luck with it!

As for the bug, yeah. It's a very old and a very known bug. Renaming will also probably fail if you name the hypha git, i.git, or any other substring of the wiki.git filepath. I had problems with home too, because I store my wikis in a home directory.

One day I'll fix it.

@bouncepaw bouncepaw mentioned this issue May 25, 2024
13 tasks
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