1.18.2 logs error
zax71 opened this issue · 8 comments
This doesn't look like it's caused by Chat Heads at all.
Cloth Config tries to create the config directory which in your case throws a FileAlreadyExistsException
.
According to the javadocs, this should only happen when there's a file named config
and it thus can't create a directory with that name.
Do you have a file named config
in your minecraft profile (C:\Users\Admin\AppData\Roaming\.1.18 fabric)?
If so, it might be another mod that incorrectly tries to create the config directory.
Deleting the config
file and creating a config
directory manually should fix the issue.
If that's not it, I'm not quite sure what's going on because this is not an issue in the code but something with your file system or potentially with file/user permissions.
Do you maybe use symbolic links or junctions? Maybe there's a broken link somewhere in your profile path?
Maybe your user doesn't have permission to access/create the config directory or something?
Sorry for waiting so long but here i am :)
yes, i do have a config directory created, i copied it over from my 1.18.1 installation and i do use symlinks but there isn't one on the config directory. From what i can see the permissions look fine too
I could try replacing my symlinks with junctions but that will take a while and it seams strange for it to break on a minor version change. I did just notise that my config folder is symlinked if that changes anything.
Also, thanks for recommanding that utility. I allready have a GUI based tool that makes it easier so i'll keep using that :)
Hm... the symlinks are the most likely cause, but the weird thing is that I cannot reproduce this behavior at all.
There's this old JDK bug report that looks like it explains what's happening:
createDirectories
goes through all subpaths from root up, checks if it is a subpath doesn't exist and creates a directory. In the case when a subpath exists, it checks whether it is a directory and throws the FileAlreadyExistsException
if it isn't.
That means some subpath in C:\Users\Admin\AppData\Roaming\.1.18 fabric\config
isn't recognized as a directory.
I thought this simply meant there's a symbolic link in there (since they are literal files with a link to another directory and often aren't handled like directories), but when I try, it still succeeds.
Maybe you can try replacing your symbolic links with junctions instead, they are specifically made for directories and much more compatible with all kinds of software (and e.g. also necessary if you wanna use links on a network drive).
I can highly recommend using Link Shell Extension to make link creation easier.
I did just notise that my config folder is symlinked if that changes anything.
That's it!
Just tested it, it fails if the last subpath is a symlink, which is pretty weird.
The good news is though that it doesn't fail if it is a junction.
Thanks for that! I’ll give it a try later :)
Also, thanks for your help on an issue that is unrelated to your mod :)
Also, thanks for your help on an issue that is unrelated to your mod :)
Haha, if it's an interesting problem, I like helping out!
You never know if you might run into it too 😄