Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-4180

Improve error messages for directory matching module name in local directory

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Won't Do
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: PMT
    • Labels:
      None
    • Template:

      Description

      Test 0.2 scenario:
      Try to install a module using a directory in the local directory.

      Tested by doing:
      `puppet module install anderson-test_a` when anderson-test_a is a module directory in the current directory.

      Outcome:
      PASS (conditionally) -
      PMT tried to untar the directory, which resulted in an error, therefore preventing the installation of the module in
      this manner, but the error messages were directly from tar, not from PMT.

      root@support:/shard/pmt-testing# puppet module install anderson-test_a
      Notice: Preparing to install into /etc/puppetlabs/puppet/modules ...
      Error: Could not extract contents of module archive: Execution of 'tar xzf anderson-test_a --no-same-owner -C /var/opt/lib/pe-puppet/puppet-module/cache/tmp-unpacker20140211-9766-1ssspbg' returned 2: tar (child): anderson-test_a: Cannot read: Is a directory
      tar (child): At beginning of tape, quitting now
      tar (child): Error is not recoverable: exiting now
      gzip: stdin: unexpected end of file
      tar: Child returned status 2
      tar: Error is not recoverable: exiting now
      Error: Try 'puppet help module install' for usage

      Suggestions:
      Better error messages, as the error messages did not appear related to the command.
      Also, this is the case whether or not a module of the same name is published to the forge. The situation of PMT trying to install a local directory instead of the published module may or may not make sense.

        Attachments

          Activity

            People

            Assignee:
            ryan Ryan Coleman
            Reporter:
            anderson Anderson Mills
            QA Contact:
            Eric Thompson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Zendesk Support