richfitz / drat.builder

Build tools for a drat
Other
17 stars 2 forks source link

build() only works once? #21

Closed achubaty closed 3 years ago

achubaty commented 3 years ago

perhaps this package is only intended for CI use, so this may be a moot point...

I successfully setup a drat repository using drat.builder::build() but I am unable to run build() more than once. Subsequent calls give the error below. Note, this also completely breaks the git submodule structure and breaks the repo.

> drat.builder::build()
*** [fetch] achubaty/amc@development
*** [fetch] PredictiveEcology/CBMutils@development
*** [fetch] PredictiveEcology/fireSenseUtils@development
*** [fetch] PredictiveEcology/LandR@development
*** [fetch] PredictiveEcology/LandWebUtils@development
*** [fetch] PredictiveEcology/map@development
*** [fetch] PredictiveEcology/pemisc@development
*** [fetch] PredictiveEcology/peutils@development
*** [fetch] PredictiveEcology/quickPlot@development
*** [fetch] PredictiveEcology/Require@development
*** [fetch] PredictiveEcology/reproducible@development
*** [fetch] PredictiveEcology/SpaDES.core@development
*** [fetch] PredictiveEcology/SpaDES.tools@development
Error in call_system(Sys_which("git"), args, ...) : Running command:
  '/usr/bin/git' clone -- packages_src/achubaty/amc ./packages/amc
had status 128
Program output:
----------------------------------------------------------------------------------------------------------
fatal: repository 'packages_src/achubaty/amc' does not exist
----------------------------------------------------------------------------------------------------------

same result on Ubuntu 20.04 and Windows 10.

richfitz commented 3 years ago

I can't replicate this, and our workflow is repeatedly running build in the same directory so there's no reason why this should not work (see #22)

System calls are always fragile, it's unfortunate it can't report more information.

> drat.builder::build()
*** [fetch] achubaty/amc@development
*** [fetch] PredictiveEcology/CBMutils@development
*** [fetch] PredictiveEcology/fireSenseUtils@development
*** [fetch] PredictiveEcology/LandR@development
*** [fetch] PredictiveEcology/LandWebUtils@development
*** [fetch] PredictiveEcology/map@development
*** [fetch] PredictiveEcology/pemisc@development
*** [fetch] PredictiveEcology/peutils@development
*** [fetch] PredictiveEcology/quickPlot@development
*** [fetch] PredictiveEcology/Require@development
*** [fetch] PredictiveEcology/reproducible@development
*** [fetch] PredictiveEcology/SpaDES.core@development
*** [fetch] PredictiveEcology/SpaDES.tools@development
*** [fetch] PredictiveEcology/usefulFuns@development
*** [build] PredictiveEcology/LandR@development
*** [build] PredictiveEcology/Require@development
*** [drat] PredictiveEcology/LandR@development
*** [commit] PredictiveEcology/LandR@development
*** [drat] PredictiveEcology/Require@development
*** [commit] PredictiveEcology/Require@development
> drat.builder::build()
*** [fetch] achubaty/amc@development
*** [fetch] PredictiveEcology/CBMutils@development
*** [fetch] PredictiveEcology/fireSenseUtils@development
*** [fetch] PredictiveEcology/LandR@development
*** [fetch] PredictiveEcology/LandWebUtils@development
*** [fetch] PredictiveEcology/map@development
*** [fetch] PredictiveEcology/pemisc@development
*** [fetch] PredictiveEcology/peutils@development
*** [fetch] PredictiveEcology/quickPlot@development
*** [fetch] PredictiveEcology/Require@development
*** [fetch] PredictiveEcology/reproducible@development
*** [fetch] PredictiveEcology/SpaDES.core@development
*** [fetch] PredictiveEcology/SpaDES.tools@development
*** [fetch] PredictiveEcology/usefulFuns@development
achubaty commented 3 years ago

Thanks for taking a look. It's a bit annoying, but not a deal breaker for me, since I am running on CI primarily (and deleting the packages and packages_src directories as a workaround if I need to run things locally).