Test on Julia nightly fails - ERROR: UndefVarError: clone not defined

Note

Originally posted to the travis community. I’ll update both posts, when a solution is found.

(re)Post

I am trying to update the CI and documentation of Observables.jl. To update the travis script, I used PkgTemplates. The following is the result:

# Documentation: http://docs.travis-ci.com/user/languages/julia/
language: julia
os:
  - linux
  - osx
julia:
  - 0.7
  - 1.0
  - 1.3
  - nightly
matrix:
  allow_failures:
    - julia: nightly
notifications:
  email: false
after_success:
  - julia -e 'using Pkg; Pkg.add("Coverage"); using Coverage; Codecov.submit(process_folder())'
  - julia -e 'using Pkg; Pkg.add("Coverage"); using Coverage; Coveralls.submit(process_folder())'
jobs:
  include:
    - stage: Documentation
      julia: 1.0
      script: julia --project=docs -e '
          using Pkg;
          Pkg.develop(PackageSpec(path=pwd()));
          Pkg.instantiate();
          include("docs/make.jl");'
      after_success: skip

My problem is that the testing fails on nightly builds of Julia. The error:

$ julia --color=yes -e "VERSION >= v\"0.7.0-DEV.5183\" && using Pkg; Pkg.clone(pwd()); if VERSION >= v\"1.1.0-rc1\"; Pkg.build(\"${JL_PKG}\"; verbose=true); else Pkg.build(\"${JL_PKG}\"); end"
ERROR: UndefVarError: clone not defined
Stacktrace:
 [1] getproperty(::Module, ::Symbol) at ./Base.jl:26
 [2] top-level scope at none:1
The command "julia --color=yes -e "VERSION >= v\"0.7.0-DEV.5183\" && using Pkg; Pkg.clone(pwd()); if VERSION >= v\"1.1.0-rc1\"; Pkg.build(\"${JL_PKG}\"; verbose=true); else Pkg.build(\"${JL_PKG}\"); end"" failed and exited with 1 during .

Builds are here. Tests also fail on AppVeyor on the nightly builds with the same error (see here).

What did I do wrong?
cc-ing @ararslan, @staticfloat, @StefanKarpinski

As I recently discovered, this happens if you don’t have a Project.toml file in the repository.

I have been getting similar complaints lately from the nightly build. I’m not even sure what to report. Here’s the bottom line on the error:

The command "julia --color=yes -e "if VERSION < v\"0.7.0-DEV.5183\"; cd(Pkg.dir(\"${JL_PKG}\")); else using Pkg; end; Pkg.add(\"Coverage\"); using Coverage; Codecov.submit(process_folder())"" exited with 1.