mojo required full path for $MOJO_SPEC

Bug #1546262 reported by Brian Murray
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Mojo: Continuous Delivery for Juju
Fix Released
Medium
Tim Kuhlman

Bug Description

stg-ue-error-tracker@wendigo:~$ mojo run --project mojo-stg-ue-error-tracker --series trusty --stage ue/mojo-ue-error-tracker/staging mojo-error-tracker
2016-02-16 18:24:43 [INFO] Using pre-existing container class lxc
2016-02-16 18:24:43 [INFO] Rsyncing mojo-error-tracker to spec
2016-02-16 18:24:43 [ERROR] Unknown error
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/mojo/cli.py", line 503, in run_with_args
    args.func(args)
  File "/usr/lib/python2.7/dist-packages/mojo/utils.py", line 305, in wrapped
    return method(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/mojo/cli.py", line 287, in run_from_manifest
    logfile=args.logfile)
  File "/usr/lib/python2.7/dist-packages/mojo/project.py", line 296, in create_workspace
    ws.prepare()
  File "/usr/lib/python2.7/dist-packages/mojo/workspace.py", line 58, in prepare
    self.spec # Initializes spec
  File "/usr/lib/python2.7/dist-packages/mojo/workspace.py", line 35, in spec
    self._spec = Spec(self.spec_dir, self.spec_url, stage=self.stage, manifest_file=self.manifest_file)
  File "/usr/lib/python2.7/dist-packages/mojo/spec.py", line 33, in __init__
    self.ct.run() # Process the codetree directive, ie branch, pull, etc
  File "/usr/lib/python2.7/dist-packages/codetree/config.py", line 44, in run
    return self.source.get(self.location, self.source_options)
  File "/usr/lib/python2.7/dist-packages/codetree/handlers/basic.py", line 74, in get
    fileutils.rsync(self.source, dest)
  File "/usr/lib/python2.7/dist-packages/codetree/fileutils.py", line 26, in rsync
    raise FileManipulationError("Only files and directories can be copied")
FileManipulationError: Only files and directories can be copied

I was able to work around this by prepending /home/stg-ue-error-tracker/ to the command line option mojo-error-tracker.

Related branches

Revision history for this message
Tim Kuhlman (timkuhlman) wrote :

Supporting relative paths for the mojo spec would be good though if not that at least it should have a better error message.

Changed in mojo:
assignee: nobody → Tim Kuhlman (timkuhlman)
Revision history for this message
Tom Haddon (mthaddon) wrote :

I can't think of a good reason that Mojo shouldn't support relative paths for spec repos, so we'll need to change Codetree to support this too.

Changed in mojo:
status: New → Confirmed
importance: Undecided → Medium
Tim Kuhlman (timkuhlman)
Changed in mojo:
status: Confirmed → In Progress
Tim Kuhlman (timkuhlman)
Changed in mojo:
status: In Progress → Fix Committed
Tom Haddon (mthaddon)
Changed in mojo:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.