-
Notifications
You must be signed in to change notification settings - Fork 9
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
biomake -Q slurm prints an error when the subdirectory does not exist #53
Comments
If foo/bar:
mkdir $(@D)
touch $@
|
yes, biomake currently leverages the filesystem far too intimately; it assumes that the subdirectory is there, to stash its internal files in the hidden directory This is certainly ugly but, as you point out, you can work around it easily enough by structuring the Makefile to ensure the directory exists, e.g. by adding an extra rule converting your
If that doesn't work for you, I get it, but it seems to me that the only other option is to have biomake anticipate that Of course, biomake could also find some way of storing its internal queue-related info that doesn't rely on the directory hierarchy being in place. I accept that this is a bug due to a design flaw (over-reliance on filesystem)... Open to additional thoughts on this.... incidentally, if bug reports can be reproduced using the internal thread pool queue implementation ( |
hmmm, now i am wondering if that example I gave would work... actually it might still run into the same issue. going to think about this some more... |
I'm okay with doing the I do in fact like the design of I avoid whenever possible having a rule depend on a directory, because the directories time stamp is pretty unstable. Any time a file within that directory changes, the time stamp of the directory changes. A simple workaround is to the time stamp issue follows. I think it suffers from the same issue though, of
|
I'm troubleshooting a program that appears to misbehave when it's output directory already exists, before it starts running. Here's a suggestion. The current Biomake metadata directory is
How about instead…
where |
@sjackman The problem with that is that the biomake directory for target X would then depend on which directory biomake was invoked in, as well as the location of X. In general this seems a bit fragile to me, and it would clearly break some cases (e.g. caching the MD5 checksum of a file) |
Is your concern specifically with recursive Makefile? That is, a Makefile in each subdirectory? I usually use one sole |
There are a few situations I can imagine where having the target metadata associated with the Makefile location (or the current working directory), rather than the target location, would be a bad idea. One such situation would be including Makefiles from other Makefiles. Another would be the case (common-ish for me) where a Makefile is refactored/split into one or more other Makefiles. Or indeed any situation where the Makefile is moved. Another gotcha situation would be if the Makefile uses absolute paths and the user expects to be able to invoke it from other, arbitrary directories. Make is already fragile enough in such situations - c.f. hacks involving the |
I'm suggesting that the I'm okay with closing this issue as a known limitation if that's your preference. It would be nice to avoid the ugly error message though if the directory doesn't already exist. Biomake should probably create the directory in that case I'd say. |
I'm still kind of hoping that an elegant solution will present itself... e.g. if @cmungall jumps in... I can certainly mitigate it by
It may be a few days before i have another chance to do some biomake hacking, so let's leave it open for discussion until then at least |
Also, if we allow for switchable behavior, there are other options... for example the location of metadata directories (in CWD vs in target dir) could be a user-changeable option... seems messy but perhaps the only way to cover all cases... |
Oddly, I believe it's already doing this, making the directory. Even though it prints the error message above, it still continues happily on and creates all the necessary directories and files. |
For my case without recursion, I'd find that helpful, |
Even though it prints this noisy error message, it seems to complete successfully. It looks like may be failing to create the file
foo/.biomake/slurm/job/bar
.The text was updated successfully, but these errors were encountered: