#Launcher doesn't want to open. 'Failed to create whole tree'

1 messages Β· Page 1 of 1 (latest)

left ravine
#

I recently re-build my pc and had yarc(g) on an m.2 that doesn't want to seem to work after the rebuild.

I reinstalled a few times on my hard drive and I've gotten the same message every time. A little frustrating but I'm sure I'm just doing something wrong.

left ravine
#

Issue persists with the 1.1.0 update

sharp hollow
#

my yarg was working perfectly fine. The 1.1.0 update has now given me this same issue.

loud breach
#

that's interesting..it shouldn't be trying to create anything new if you're just updating

sharp hollow
loud breach
#

If you're on windows, you can try deleting the %localappdata%\YARC folder entirely. (I suggest backing it up first). This will remove any copies of the setlist or YARG installs you have, but if it's not working anyway, not much to lose there, lol

sharp hollow
#

Sorry to bug you, I just don't know what else I can do lol never run into any issue like this before

loud breach
#

You could try manually creating folders called "YARG Installs" and "Setlists" inside the YARC folder in %localappdata% (create it if it doesn't exist)

#

it should use them if they're there...

#

(it's also possible some antivirus software is preventing it from creating folders, so it might be worth checking to see if the AV says it blocked anything)

sharp hollow
loud breach
#

Hm, thanks for trying. If you know how to check permissions of folders, make sure your Windows user has Full Control rights to %appdata%\Local (I can't imagine it wouldn't without causing all kinds of other problems, but it never hurts to check)

#

In the meantime, I'm working on putting together a version of the launcher that should hopefully provide more useful error messages in cases like these so we can nail down the problem a bit better

sharp hollow
#

I tried installing the previous version of the launcher and that didn't work either. I'm going to try installing a portable version just to see what happens.

loud breach
#

I was going to suggest using the portable version of YARG in the meantime

#

If you have the setlist already downloaded, you will have to manually tell YARG where it is the same way you would point it to custom songs, but it will read the setlist just fine once you do that

#

(sadly, it is not possible to download the setlist without the launcher if you don't already have it)

left ravine
#

Thank you for your time and such. Still getting the same errors but i'll give portable a shot!

sharp hollow
#

@loud breach I FIXED IT

loud breach
#

πŸ‘€

sharp hollow
#

In MY situation, it turned out the drive that I had my main folders in was actually UNPLUGGED so it was causing boot errors. I have all my songs on an external 2TB SSD and apparently I also have some app data there too.

#

Plugged it back in, and now the launcher loads

loud breach
#

ahhh...I presume you had changed the default download folder at some point?

sharp hollow
loud breach
#

I'm glad you got it figured out πŸ˜„

loud breach
# left ravine Issue persists with the 1.1.0 update

did the drive letter of the m.2 drive change? You can find the launcher's configuration file in %appdata%\Roaming\in.yarg.launcher\settings.json. Near the top there should be an entry named "downloadLocation". If your drive letter changed, change the drive letter at the beginning of that entry to the new letter and it should work.

If you don't want to mess with it and don't mind possibly having to redownload everything, you can delete the entire in.yarg.launcher folder and start from scratch.

left ravine
#

bless your heart

#

that worked

distant pivot
#

so i guess the launcher doesn't handle unplugged drives gracefully?

loud breach
#

alls it knows is that the directory doesn't exist, so it tries to create it

distant pivot
#

hm so i guess it just doesn't handle any directory create error gracefully

#

it should give a pretty pop-up at least (with a path of the directory its trying to create), and a possibility to change the path in the pop-up would be even nicer

loud breach
#

Yeah, I was working on trying to make it at least give a more useful error message (dir_create_all can only return that useless "failed to create entire tree" message), but I know basically no rust, lol

distant pivot
#

you should create your own wrapper enum error type, and then use map_err() to convert the io::Error into your wrapper type

#

and then your wrapper type can have its own implementation of a function that says how it should be displayed

#

and also it can have additional info, such as a filepath

#

..i could do that if that's too complicated for you

loud breach
#

dir_create_all doesn't seem to return the underlying io error

#

have at it, please

#

(it's not actually dir_create_all, ffs, my memory is just shot, but it's something like that)

distant pivot
#

how do i explain this

#

Result is either a "success" with just a normal returned value or an "error" with an error value

loud breach
#

I know it's kinda a composite between ok and error depending

distant pivot
#

in the case of create_dir_all, the "success" value is of type void (so it doesn't return any additional information), and the "error" value is of type io::Error

loud breach
#

but from looking at its implementation it seems to overwrite the underlying error with io::Error::UnspecifiedError or something

#

but again, idk rust, so maybe that's just a default case?

distant pivot
#

oh i just now see how the launcher does things

#

okay so,, the easiest way to show a path right now is just to include in the format!() statement

loud breach
#
            Some(p) => self.create_dir_all(p)?,
            None => {
                return Err(io::const_error!(
                    io::ErrorKind::Uncategorized,
                    "failed to create whole tree",
                ));
            }
        }```
#

this is what I'm talking about when I say that it looks like it can only return the Uncategorized error when it fails to create the tree

distant pivot
#

right, but that shouldn't really be an issue

#

we don't really care what exact specific kind of error it is

#

we just care that its an error

loud breach
#

we kinda do, because otherwise we can't tell the difference between "the user doesn't have permission" and "there is no disk here" and whatever else

#

or even "this already exists"

distant pivot
#

in both cases we have the same problem - we're trying to use a path and we can't, manual intervention from the user is required, most likely a path change
"this already exists" should be detected separately

loud breach
#

(though I think the default settings for the directory builder stuff will just be like "alrighty, cool" if it already exists..we check separately whether the directory is empty, at least in the case where the user specifies an custom install location)

distant pivot
#

its already done in one of the error hanndling functions

#

just not in the rest of them

loud breach
distant pivot
#

true

loud breach
#

30 years dealing with users has taught me something, lol

#

fml, I got old

#

(started young, but still)

distant pivot
#

hmm it seems like tauri has some additional restrictions on error types for functions with the command attribute

#

i guess its because tauri has to send the error back to the frontend, so the frontend basically can only receive a string

#

which i guess we can just jsonify the error and send the json

#

seems kinda weird but i mean it makes sense, how else are you gonna send data across processes

#

i'm going to move into #launcher-dev