Bug #4489

standalone puppet file source error "Could not evaluate: getaddrinfo: ..."

Added by Mathias Gug over 1 year ago. Updated 5 months ago.

Status:Closed Start date:08/06/2010
Priority:Immediate Due date:
Assignee:Markus Roberts % Done:

0%

Category:fileserving
Target version:-
Affected Puppet version:2.6.0 Branch:http://github.com/MarkusQ/puppet/tree/ticket/2.6.x/4489
Keywords:
Votes: 7

Description

When running the puppet command with the following code:

file { "/tmp/bobics_fileserver": source => "puppet:///modules/bobics/bobics_fileserver"}

I get the error:

err: /Stage[main]/Bobics/File[/tmp/bobics_fileserver]: Could not evaluate: getaddrinfo: Name or service not known Could not retrieve file metadata for puppet:///modules/bobics/bobics_fileserver: getaddrinfo: Name or service not known at /home/debian/puppet_sample/ modules/bobics/manifests/init.pp:8 

See http://groups.google.com/group/puppet-users/browse_thread/thread/626e7334b437f4fc/ac3434e23105b2a4.

This seems to be a regression in 2.6.


Related issues

related to Puppet - Bug #4770: Problem file serving standalone Rejected 09/14/2010
duplicated by Puppet - Bug #4557: File serving breaks in masterless operation Duplicate 08/17/2010

History

Updated by Anselm Strauss over 1 year ago

Same for me. Currently 2.6.1 is unusable in standalone mode on FreeBSD, all file sources fail.

Updated by James Turnbull over 1 year ago

  • Category set to fileserving
  • Status changed from Unreviewed to Investigating
  • Assignee set to Markus Roberts
  • Priority changed from Normal to Immediate
  • Target version set to 2.6.1

Updated by Markus Roberts over 1 year ago

Stack trace to the actually point at which it fails:

/usr/lib/ruby/1.8/net/http.rb:560:in `initialize'
/usr/lib/ruby/1.8/net/http.rb:560:in `open'
/usr/lib/ruby/1.8/net/http.rb:560:in `connect'
/usr/lib/ruby/1.8/timeout.rb:62:in `timeout'
/usr/lib/ruby/1.8/timeout.rb:93:in `timeout'
/usr/lib/ruby/1.8/net/http.rb:560:in `connect'
/usr/lib/ruby/1.8/net/http.rb:553:in `do_start'
/usr/lib/ruby/1.8/net/http.rb:542:in `start'
/usr/lib/ruby/1.8/net/http.rb:1035:in `request'
/usr/lib/ruby/1.8/net/http.rb:772:in `get'
./lib/puppet/indirector/rest.rb:71:in `find'
./lib/puppet/indirector/indirection.rb:193:in `find'
./lib/puppet/indirector.rb:50:in `find'
./lib/puppet/type/file/source.rb:141:in `init_metadata'
./lib/puppet/type/file/source.rb:139:in `each'
./lib/puppet/type/file/source.rb:139:in `init_metadata'
./lib/puppet/util/cacher.rb:106:in `send'
./lib/puppet/util/cacher.rb:106:in `cached_value'
/usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
./lib/puppet/util/cacher.rb:98:in `cached_value'
./lib/puppet/util/cacher.rb:48:in `metadata'
./lib/puppet/type/file/source.rb:99:in `copy_source_values'
./lib/puppet/type/file.rb:632:in `retrieve'
./lib/puppet/type.rb:695:in `retrieve_resource'
./lib/puppet/transaction/resource_harness.rb:39:in `changes_to_perform'
./lib/puppet/transaction/resource_harness.rb:87:in `evaluate'
./lib/puppet/transaction.rb:49:in `apply'
./lib/puppet/transaction.rb:114:in `eval_children_and_apply_resource'
./lib/puppet/transaction.rb:92:in `eval_resource'
./lib/puppet/transaction.rb:143:in `evaluate'
./lib/puppet/util.rb:414:in `thinmark'
/usr/lib/ruby/1.8/benchmark.rb:308:in `realtime'
./lib/puppet/util.rb:413:in `thinmark'
./lib/puppet/transaction.rb:142:in `evaluate'
./lib/puppet/transaction.rb:135:in `each'
./lib/puppet/transaction.rb:135:in `evaluate'
./lib/puppet/resource/catalog.rb:144:in `apply'
./lib/puppet/application/apply.rb:126:in `main'
./lib/puppet/application/apply.rb:35:in `run_command'
./lib/puppet/application.rb:300:in `run'
./lib/puppet/application.rb:397:in `exit_on_fail'
./lib/puppet/application.rb:300:in `run'
./lib/puppet/util/command_line.rb:55:in `execute'
bin/puppet:4

Updated by Markus Roberts over 1 year ago

  • Status changed from Investigating to Needs More Information
  • Assignee deleted (Markus Roberts)

The problem seems to be in the indirector when it’s trying to open a connection to the master (there isn’t one, we’re running standalone). In 0.25.x it didn’t do this but it also didn’t work, so far as I can see. Ticket #658 seems to imply that it should work, but I’m having no luck setting it up.

Did fileserving work standalone in 0.25.x, and, if so, what do I need to do to set that up?

UPDATE: The problems I was having arose from an unrelated bug in 0.25.x (which I was foolishly using instead of 0.25.5); Jordan’s test case does demonstrate the bug.

Updated by Jordan Sissel over 1 year ago

I provided a reproduce case for this bug here: http://projects.puppetlabs.com/issues/4557

It shows failing in 2.6, 2.6.1rc2. Works in 0.25.5.

Updated by Markus Roberts over 1 year ago

  • Status changed from Needs More Information to Accepted
  • Assignee set to Markus Roberts

Thanks!

Updated by Markus Roberts over 1 year ago

It’s using the :rest terminus instead of :file_serving. But why…?

Updated by Markus Roberts over 1 year ago

  • Status changed from Accepted to In Topic Branch Pending Review
  • Branch set to http://github.com/MarkusQ/puppet/tree/ticket/2.6.x/4489

It was choosing the terminus based in part on the application name, which changed in 2.6.x (it’s now apply).

Updated by Markus Roberts over 1 year ago

  • Status changed from In Topic Branch Pending Review to Closed
  • Branch changed from http://github.com/MarkusQ/puppet/tree/ticket/2.6.x/4489 to http://github.com/MarkusQ/puppet/tree/ticket/2.6.x/4489

commit:c3185584a0c9f22b7deaff022855b160a945486f

Updated by Jörg Herzinger over 1 year ago

This is issue is still not solved. I just tried it with 2.6.1rc3 from github the same errors still exist.

I took a freshly created squeeze machine and issued the following:

aptitude install facter ruby git-core git clone http://github.com/reductivelabs/puppet.git cd puppet && ruby install.rb

mkdir -p /etc/puppet/modules/ && cd /etc/puppet/modules/ git clone http://github.com/andis/admin-essentials.git mkdir -p /etc/puppet/manifests && echo “node default { include ‘admin-essentials’ }” > /etc/puppet/manifests/site.pp

puppet apply /etc/puppet/manifests/site.pp

Which works for most of the recipie but still hast 2 errors:

err: /File[/root/.mc/ini]/ensure: change from absent to file failed: Could not set ‘file on ensure: getaddrinfo: Name or service not known err: /Stagecommit:main]/Admin-essentials/File[/root/.emacs/ensure: change from absent to file failed: Could not set 'file on ensure: getaddrinfo: Name or service not known at /etc/puppet/modules/admin-essentials/manifests/admin-essentials.pp:42

Any file created via source => “puppet:///puppet/modules/myfilename”; will fail, while files created via content or ensure present work.

Updated by Sebastian Boehm over 1 year ago

The bug Joerg is referring to was introduced in commit:2cf7222df889981313c6955cc9220ce160dd90f6(http://github.com/reductivelabs/puppet/commit/2cf7222df889981313c6955cc9220ce160dd90f6) with client-side file streaming.

Markus changed the terminus selection code with the fix above but it seems to me that each_chunk_from (and hence write) in lib/puppet/type/file/content.rb does not actually use the terminus. (Although I’m not exactly sure I’ve managed to wrap my head around the way indirectors and termini work in this case.)

The local? method in lib/puppet/type/file/source.rb uses a hardcoded check for “file” in the URI to determine whether a file source is local, which is why it never returns true for puppet URIs — even with “puppet apply”.

So when each_chunk_from finally calls chunk_file_from_source in lib/puppet/type/file/content.rb an HTTP request is issued which subsequently fails with the getaddrinfo error.

It would be great if you could get this fixed for 2.6.1 since it effectively renders file sources in standalone puppet useless.

References

each_chunk_from seems to be a good starting point to investigate this bug further.

Updated by Sebastian Boehm over 1 year ago

Stack trace:


/usr/lib/ruby/1.8/net/http.rb:560:in `initialize'
/usr/lib/ruby/1.8/net/http.rb:560:in `open'
/usr/lib/ruby/1.8/net/http.rb:560:in `connect'
/usr/lib/ruby/1.8/timeout.rb:62:in `timeout'
/usr/lib/ruby/1.8/timeout.rb:93:in `timeout'
/usr/lib/ruby/1.8/net/http.rb:560:in `connect'
/usr/lib/ruby/1.8/net/http.rb:553:in `do_start'
/usr/lib/ruby/1.8/net/http.rb:542:in `start'
/usr/lib/ruby/1.8/net/http.rb:1035:in `request'
/usr/lib/ruby/1.8/net/http.rb:948:in `request_get'
/usr/local/lib/site_ruby/1.8/puppet/type/file/content.rb:189:in `chunk_file_from_source'
/usr/local/lib/site_ruby/1.8/puppet/type/file/content.rb:172:in `each_chunk_from'
/usr/local/lib/site_ruby/1.8/puppet/type/file/content.rb:157:in `write'
/usr/local/lib/site_ruby/1.8/puppet/util/checksums.rb:46:in `md5_stream'
/usr/local/lib/site_ruby/1.8/puppet/type/file/checksum.rb:30:in `send'
/usr/local/lib/site_ruby/1.8/puppet/type/file/checksum.rb:30:in `sum_stream'
/usr/local/lib/site_ruby/1.8/puppet/type/file/content.rb:156:in `write'
/usr/local/lib/site_ruby/1.8/puppet/type/file.rb:761:in `write_content'
/usr/local/lib/site_ruby/1.8/puppet/type/file.rb:722:in `write'
/usr/local/lib/site_ruby/1.8/puppet/type/file.rb:722:in `open'
/usr/local/lib/site_ruby/1.8/puppet/type/file.rb:722:in `write'
/usr/local/lib/site_ruby/1.8/puppet/util.rb:144:in `withumask'
/usr/local/lib/site_ruby/1.8/puppet/type/file.rb:722:in `write'
/usr/local/lib/site_ruby/1.8/puppet/type/file/content.rb:137:in `sync'
/usr/local/lib/site_ruby/1.8/puppet/transaction/change.rb:34:in `apply'
/usr/local/lib/site_ruby/1.8/puppet/transaction/resource_harness.rb:21:in `apply_changes'
/usr/local/lib/site_ruby/1.8/puppet/transaction/resource_harness.rb:20:in `each'
/usr/local/lib/site_ruby/1.8/puppet/transaction/resource_harness.rb:20:in `apply_changes'
/usr/local/lib/site_ruby/1.8/puppet/transaction/resource_harness.rb:90:in `evaluate'
/usr/local/lib/site_ruby/1.8/puppet/transaction.rb:49:in `apply'
/usr/local/lib/site_ruby/1.8/puppet/transaction.rb:114:in `eval_children_and_apply_resource'
/usr/local/lib/site_ruby/1.8/puppet/transaction.rb:92:in `eval_resource'
/usr/local/lib/site_ruby/1.8/puppet/transaction.rb:143:in `evaluate'
/usr/local/lib/site_ruby/1.8/puppet/util.rb:414:in `thinmark'
/usr/lib/ruby/1.8/benchmark.rb:308:in `realtime'
/usr/local/lib/site_ruby/1.8/puppet/util.rb:413:in `thinmark'
/usr/local/lib/site_ruby/1.8/puppet/transaction.rb:142:in `evaluate'
/usr/local/lib/site_ruby/1.8/puppet/transaction.rb:135:in `each'
/usr/local/lib/site_ruby/1.8/puppet/transaction.rb:135:in `evaluate'
/usr/local/lib/site_ruby/1.8/puppet/resource/catalog.rb:144:in `apply'
/usr/local/lib/site_ruby/1.8/puppet/application/apply.rb:133:in `main'
/usr/local/lib/site_ruby/1.8/puppet/application/apply.rb:35:in `run_command'
/usr/local/lib/site_ruby/1.8/puppet/application.rb:300:in `run'
/usr/local/lib/site_ruby/1.8/puppet/application.rb:397:in `exit_on_fail'
/usr/local/lib/site_ruby/1.8/puppet/application.rb:300:in `run'
/usr/local/lib/site_ruby/1.8/puppet/util/command_line.rb:55:in `execute'
/usr/sbin/puppet:4

Updated by Sebastian Boehm over 1 year ago

Steps to reproduce:

rm -r /etc/puppet
mkdir -p /etc/puppet/modules/example/{files,manifests}
echo 'hello world' > /etc/puppet/modules/example/files/testfile
echo 'class example {
  file { "/tmp/testfile":
    source => "puppet:///modules/example/testfile";
  }
}' > /etc/puppet/modules/example/manifests/init.pp
mkdir /etc/puppet/manifests
echo 'node default { include "example" }' > /etc/puppet/manifests/site.pp
puppet apply /etc/puppet/manifests/site.pp -v

Updated by Sebastian Boehm over 1 year ago

  • Status changed from Closed to Re-opened

Updated by Markus Roberts over 1 year ago

Status update:

I’m still working on this, interspersed with other tasks, and have reproduced the extended symptoms, which can be resolved in a manner analogous to the first problem, but that just lets it go a few lines further to where it hits a new (but closely related) issue. I’m looking at addressing the file streaming part higher up the call stack as it doesn’t really make sense to “stream” in standalone mode. More as I have it.

Updated by Markus Roberts over 1 year ago

  • Status changed from Re-opened to Accepted

I have a kludgey solution that short-circuits the streaming logic for standalone. I’m going to clean it up & will post it for testing shortly.

Updated by Markus Roberts over 1 year ago

  • Status changed from Accepted to In Topic Branch Pending Review

The branch has been replaced with one that addresses the file streaming issue as well as the indirector issue. Note that this new branch has the same name and will look like a git-history rewrite, so you may need to use -f (force) to pull it (sorry if that causes undue hassle to anyone).

Updated by Sebastian Boehm over 1 year ago

The revised commit in ticket/2.6.x/4489 looks good and seems to be working correctly for standalone puppet using my test case above.

Updated by James Turnbull over 1 year ago

  • Status changed from In Topic Branch Pending Review to Code Insufficient

It however results in the following broken tests:


1)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from local source should open the local file'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: File.open('/path/to/source', 'r')
satisfied expectations:
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)
- allowed any number of times, not yet invoked: #.read(8192)
- allowed any number of times, not yet invoked: File.open(any_parameters)

./spec/unit/type/file/content_spec.rb:316:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

2)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from local source should read the local file by chunks'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.read(8192)
satisfied expectations:
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)
- allowed any number of times, not yet invoked: #.read(8192)
- allowed any number of times, not yet invoked: File.open(any_parameters)

./spec/unit/type/file/content_spec.rb:321:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

3)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from local source should write each chunk to the file'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.print('chunk2')
satisfied expectations:
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)
- allowed any number of times, not yet invoked: #.read(8192)
- allowed any number of times, not yet invoked: File.open(any_parameters)

./spec/unit/type/file/content_spec.rb:326:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

4)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from local source should pass each chunk to the current sum stream'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.<<('chunk2')
satisfied expectations:
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)
- allowed any number of times, not yet invoked: #.read(8192)
- allowed any number of times, not yet invoked: File.open(any_parameters)

./spec/unit/type/file/content_spec.rb:331:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

5)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should open a network connection to source server and port'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: Puppet::Network::HttpPool.http_instance('server', 1234)
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:360:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

6)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should send the correct indirection uri'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.request_get()
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:365:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

7)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should return nil if source is not found'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.code(any_parameters)
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:370:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

8)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should not write anything if source is not found'
unexpected invocation: #.print(nil)
unsatisfied expectations:
- expected exactly once, not yet invoked: #.code(any_parameters)
satisfied expectations:
- expected never, not yet invoked: #.print(any_parameters)
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

/home/james/src/puppet/spec/../lib/puppet/type/file/content.rb:159:in `write'
/home/james/src/puppet/spec/../lib/puppet/type/file/content.rb:170:in `each_chunk_from'
/home/james/src/puppet/spec/../lib/puppet/type/file/content.rb:157:in `write'
/home/james/src/puppet/spec/../lib/puppet/type/file/content.rb:156:in `write'
./spec/unit/type/file/content_spec.rb:377:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

9)
'Puppet::Type::File::Content when writing from remote source should raise an HTTP error in case of server error' FAILED
expected Exception but nothing was raised
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/expectations/fail_with.rb:41:in `fail_with'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/expectations/handler.rb:21:in `handle_matcher'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/expectations/extensions/kernel.rb:27:in `should'
./spec/unit/type/file/content_spec.rb:382:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

10)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should write content by chunks'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.print('chunk2')
- expected exactly once, not yet invoked: #.read_body(any_parameters)
- expected exactly once, not yet invoked: #.code(any_parameters)
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:388:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

11)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should pass each chunk to the current sum stream'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.read_body(any_parameters)
- expected exactly once, not yet invoked: #.code(any_parameters)
- expected exactly once, not yet invoked: #.<<('chunk2')
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:394:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

12)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should return the checksum computed'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.read_body(any_parameters)
- expected exactly once, not yet invoked: #.code(any_parameters)
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- expected exactly once, already invoked once: #.sum_stream(any_parameters)
- allowed any number of times, not yet invoked: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:401:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

13)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should get the current accept encoding header value'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.add_accept_encoding(any_parameters)
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:407:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

14)
'Puppet::Type::File::Content when writing from remote source should uncompress body on error' FAILED
expected Exception but nothing was raised
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/expectations/fail_with.rb:41:in `fail_with'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/expectations/handler.rb:21:in `handle_matcher'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/expectations/extensions/kernel.rb:27:in `should'
./spec/unit/type/file/content_spec.rb:415:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

15)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should uncompress chunk by chunk'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.read_body(any_parameters)
- expected exactly once, not yet invoked: #.code(any_parameters)
- expected exactly once, not yet invoked: #.uncompress(#)
- expected exactly once, not yet invoked: #.uncompress('chunk2')
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:422:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

16)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should write uncompressed chunks to the file'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.print('uncompressed2')
- expected exactly once, not yet invoked: #.print('uncompressed1')
- expected exactly once, not yet invoked: #.read_body(any_parameters)
- expected exactly once, not yet invoked: #.code(any_parameters)
- expected exactly once, not yet invoked: #.uncompress(#)
- expected exactly once, not yet invoked: #.uncompress('chunk2')
- expected exactly once, not yet invoked: #.uncompress('chunk1')
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:438:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

17)
Mocha::ExpectationError in 'Puppet::Type::File::Content when writing from remote source should pass each uncompressed chunk to the current sum stream'
not all expectations were satisfied
unsatisfied expectations:
- expected exactly once, not yet invoked: #.read_body(any_parameters)
- expected exactly once, not yet invoked: #.code(any_parameters)
- expected exactly once, not yet invoked: #.uncompress(#)
- expected exactly once, not yet invoked: #.<<('uncompressed2')
- expected exactly once, not yet invoked: #.uncompress('chunk2')
- expected exactly once, not yet invoked: #.uncompress('chunk1')
satisfied expectations:
- allowed any number of times, not yet invoked: #.code(any_parameters)
- allowed any number of times, not yet invoked: #.request_get(any_parameters)
- allowed any number of times, not yet invoked: Puppet::Network::HttpPool.http_instance(any_parameters)
- allowed any number of times, already invoked once: #.actual_content(any_parameters)
- allowed any number of times, not yet invoked: #.server(any_parameters)
- allowed any number of times, not yet invoked: #.full_path(any_parameters)
- allowed any number of times, not yet invoked: #.local?(any_parameters)
- allowed any number of times, not yet invoked: #.port(any_parameters)
- allowed any number of times, already invoked once: #.parameter(:checksum)
- allowed any number of times, already invoked once: #.parameter(:source)
- allowed any number of times, already invoked once: #.sum_stream(any_parameters)

./spec/unit/type/file/content_spec.rb:447:
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `instance_eval'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:40:in `execute'
/usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_methods.rb:37:in `execute'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:214:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `each'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:212:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/example/example_group_methods.rb:103:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:21:in `run'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `each'
/home/james/src/puppet/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:16:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:152:in `run_examples'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in `run'
/usr/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5:
/usr/bin/spec:19:in `load'
/usr/bin/spec:19:

Updated by Markus Roberts over 1 year ago

smile You’re jumping the gun on us there James. First we figure out what needs to be done to get the desired results, then we can worry about which of our overly invasive tests it breaks. When I say I have a kludgey partial solution that’s meant to imply that it isn’t a final answer, just a draft.

Updated by Markus Roberts over 1 year ago

  • Status changed from Code Insufficient to Ready For Checkin

The branch has been extended with a commit that stubs the standalone detection so that the specs will deterministically pass (rather than depending on the phase of the moon or the value in Puppet.settings[:name]).

Updated by James Turnbull over 1 year ago

  • Status changed from Ready For Checkin to Closed

Pushed in commit:b397b698314daae36f59751521be113cfd337095 in branch 2.6.x

Updated by Jordan Sissel over 1 year ago

Confirmed standalone works again for me, tested with the example tarball I listed above : http://projects.puppetlabs.com/attachments/1087/puppet26-masterless-break-example.tar.gz

% sudo puppet apply --verbose --modulepath modules manifests/site.pp
info: Applying configuration version '1283849861'
notice: /Stage[main]/Foo/File[/tmp/footest]/ensure: defined content as '{md5}f0ef7081e1539ac00ef5b761b4fb01b3'

Thanks!

Updated by Stig Sandbeck Mathisen over 1 year ago

  • Status changed from Closed to Re-opened
  • Target version deleted (2.6.1)

Stig’s comment has been moved to it’s own ticket, #4770.

Updated by James Turnbull over 1 year ago

  • Target version set to 2.6.2

Updated by Markus Roberts over 1 year ago

  • Status changed from Re-opened to Closed
  • Target version deleted (2.6.2)

This is a new (albeit possibly closely related) issue. See the linked ticket.

Also available in: Atom PDF