Skip to content

Instantly share code, notes, and snippets.

Package Tools

A quick summary of some tools for dealing with packages on disk. The aim of this effort is to give the user a set of tools that provides visibility into the dependencies between packages stored on disk by habitat either in /hab or in studio.

For each case we show what version it's released in or the relevant PR if it's already coded but not released.

Use Cases

  • Show the list of packages currently installed (0.68)
Proceeding with analysis...
ls_log.erl:22: Type specification ls_log:'#info-'('log') -> ['count' | 'created_at' | 'id' | 'node_name' | 'organization_name' | 'run_id'] is a supertype of the success typing: ls_log:'#info-'('log') -> ['count' | 'created_at' | 'id' | 'node_name' | 'organization_name' | 'run_id',...]
ls_log.erl:22: Type specification ls_log:'#info-log'('fields') -> ['count' | 'created_at' | 'id' | 'node_name' | 'organization_name' | 'run_id']
; ('size') -> 7 is a supertype of the success typing: ls_log:'#info-log'('fields' | 'size') -> ['count' | 'created_at' | 'id' | 'node_name' | 'organization_name' | 'run_id',...] | 7
ls_log.erl:22: Type specification ls_log:'#pos-log'('#attr-log'() | atom()) -> integer() is a supertype of the success typing: ls_log:'#pos-log'(atom()) -> 0 | 2 | 3 | 4 | 5 | 6 | 7
ls_log.erl:22: The specification for ls_log:'#pos-'/2 states that the function might also return 1 but the inferred return is 0 | 2 | 3 | 4 | 5 | 6 | 7
ls_log.erl:22: Type specification ls_log:'#i

Keybase proof

I hereby claim:

  • I am jamesc on github.
  • I am jamesc (https://keybase.io/jamesc) on keybase.
  • I have a public key whose fingerprint is 41D8 EFB5 E3FA 972A AEA0 4FC6 966D B723 C86F 6443

To claim this, I am signing this object:

@jamesc
jamesc / community cookbooks
Last active December 21, 2015 11:49
top file extensions in cookbooks
445 .rb
172 .erb
75 .md
31 .json
23 .gitignore
19 .yml
8 .lock
3 .gif
2 .rdoc
2 .png
@jamesc
jamesc / client
Created October 31, 2012 23:41
failing pushy test
[2012-10-31T22:59:42+00:00] INFO: [DONKEY] Worker: Listening for server heartbeat at tcp://private-chef.opscode.piab:10000
[2012-10-31T22:59:42+00:00] INFO: [DONKEY] Worker: Connecting to command channel at tcp://private-chef.opscode.piab:10002
[2012-10-31T22:59:42+00:00] INFO: [DONKEY] Sending heartbeat
[2012-10-31T22:59:42+00:00] INFO: [FIONA] Worker: Listening for server heartbeat at tcp://private-chef.opscode.piab:10000
[2012-10-31T22:59:42+00:00] INFO: [FIONA] Worker: Connecting to command channel at tcp://private-chef.opscode.piab:10002
[2012-10-31T22:59:42+00:00] INFO: [FIONA] Sending heartbeat
[2012-10-31T22:59:42+00:00] DEBUG: decompressing gzip response
[2012-10-31T22:59:42+00:00] DEBUG: [FIONA] Worker: Setting heartbeat at every 1.0 seconds
[2012-10-31T22:59:42+00:00] INFO: [FIONA] Reaper: will reap in 3600 seconds
[2012-10-31T22:59:42+00:00] DEBUG: [DONKEY] Worker: Setting heartbeat at every 1.0 seconds
Failures:
1) end-to-end-test with three clients when running a job the job and node statuses are marked complete
Failure/Error: echo_job_should_complete_on_all_clients
RuntimeError:
Job never reached status 'complete': actual job reported as {"command"=>"sh /opt/opscode-push-jobs-server/embedded/service/gem/ruby/1.9.1/bundler/gems/oc-pushy-pedant-tests-f3d71a654232/spec/support/echo_yahoo_to_tmp_pushytest", "status"=>"running", "run_timeout"=>3600, "nodes"=>{"complete"=>["FARQUAD", "FIONA"], "ready"=>["DONKEY"]}}
# ./oc-pushy-pedant:16:in `<main>'
Finished in 1 minute 10.25 seconds
22 examples, 1 failure
[2012-10-25T18:48:04+00:00] INFO: Running report handlers
[2012-10-25T18:48:04+00:00] INFO: Resource Elapsed Time(0.08s per unit)
[2012-10-25T18:48:04+00:00] INFO: ======== ============
[2012-10-25T18:48:04+00:00] INFO: remote_directory[/srv/chef/handlers]
[2012-10-25T18:48:04+00:00] INFO: cookbook_file[/srv/chef/handlers/chef_profiler.rb] ++++++++++++++++++++++++++++++
[2012-10-25T18:48:04+00:00] INFO: chef_handler[Chef::Handler::Profiler] +
[2012-10-25T18:48:04+00:00] INFO: package[ntp] ------
[2012-10-25T18:48:04+00:00] INFO: package[ntpdate] ------
[2012-10-25T18:48:04+00:00] INFO: directory[/var/lib/ntp]
[2012-10-25T18:48:04+00:00] INFO: directory[/var/log/ntpstats/]
Failures:
1) Environments API Endpoint POST /environments with no additional environments when handling the payload with authentication headers when X-Ops-Request-Source is web impersonating successful user succeeds
Failure/Error: let(:user) { Pedant::Requestor.new(success_user.name, '/etc/chef-server/webui_priv.pem') }
Errno::ENOENT:
No such file or directory - /etc/chef-server/webui_priv.pem
# /srv/piab/mounts/chef-pedant-core/lib/pedant/requestor.rb:30:in `read'
# /srv/piab/mounts/chef-pedant-core/lib/pedant/requestor.rb:30:in `initialize'
# /srv/piab/mounts/chef-pedant-core/lib/pedant/rspec/auth_headers_util.rb:276:in `new'
# /srv/piab/mounts/chef-pedant-core/lib/pedant/rspec/auth_headers_util.rb:276:in `block (4 levels) in <module:AuthHeadersUtil>'
# /srv/piab/mounts/chef-pedant-core/lib/pedant/rspec/auth_headers_util.rb:109:in `block (2 levels) in <module:AuthHeadersUtil>'
root@open-source-chef:/tmp/apt-1.4.3# hexdump -C providers/preference.rb |head
00000000 36 37 39 0d 0a 23 0a 23 20 43 6f 6f 6b 62 6f 6f |679..#.# Cookboo|
00000010 6b 20 4e 61 6d 65 3a 3a 20 61 70 74 0a 23 20 50 |k Name:: apt.# P|
00000020 72 6f 76 69 64 65 72 3a 3a 20 70 72 65 66 65 72 |rovider:: prefer|
00000030 65 6e 63 65 0a 23 0a 23 20 43 6f 70 79 72 69 67 |ence.#.# Copyrig|
00000040 68 74 20 32 30 31 30 2d 32 30 31 31 2c 20 4f 70 |ht 2010-2011, Op|
00000050 73 63 6f 64 65 2c 20 49 6e 63 2e 0a 23 0a 23 20 |scode, Inc..#.# |
00000060 4c 69 63 65 6e 73 65 64 20 75 6e 64 65 72 20 74 |Licensed under t|
00000070 68 65 20 41 70 61 63 68 65 20 4c 69 63 65 6e 73 |he Apache Licens|
...