Python 2.7.14 (v2.7.14:84471935ed, Sep 16 2017, 12:01:12) 
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "copyright", "credits" or "license()" for more information.
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
 "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 2.40.1 (20161225.0304)
 -->
<!-- Title: %3 Pages: 1 -->
<svg width="91pt" height="116pt"
 viewBox="0.00 0.00 91.09 116.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 112)">
<title>%3</title>
<polygon fill="#ffffff" stroke="transparent" points="-4,4 -4,-112 87.0852,-112 87.0852,4 -4,4"/>
<!-- raymond -->
<g id="node1" class="node">
<title>raymond</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-90" rx="41.5852" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-85.8" font-family="Times,serif" font-size="14.00" fill="#000000">raymond</text>
</g>
<!-- matthew -->
<g id="node2" class="node">
<title>matthew</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-18" rx="40.6162" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-13.8" font-family="Times,serif" font-size="14.00" fill="#000000">matthew</text>
</g>
<!-- raymond&#45;&gt;matthew -->
<g id="edge1" class="edge">
<title>raymond&#45;&gt;matthew</title>
<path fill="none" stroke="#000000" d="M41.5426,-71.8314C41.5426,-64.131 41.5426,-54.9743 41.5426,-46.4166"/>
<polygon fill="#000000" stroke="#000000" points="45.0427,-46.4132 41.5426,-36.4133 38.0427,-46.4133 45.0427,-46.4132"/>
</g>
</g>
</svg>

>>> # sometimes when you install, existing sessions
>>> # don't about the new path.
>>> # so, restart the terminal session and python itself
>>> #    # python -m idlelib.idle
>>> svg_start = text.index('<svg')
>>> print text[svg_start:]
<svg width="91pt" height="116pt"
 viewBox="0.00 0.00 91.09 116.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 112)">
<title>%3</title>
<polygon fill="#ffffff" stroke="transparent" points="-4,4 -4,-112 87.0852,-112 87.0852,4 -4,4"/>
<!-- raymond -->
<g id="node1" class="node">
<title>raymond</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-90" rx="41.5852" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-85.8" font-family="Times,serif" font-size="14.00" fill="#000000">raymond</text>
</g>
<!-- matthew -->
<g id="node2" class="node">
<title>matthew</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-18" rx="40.6162" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-13.8" font-family="Times,serif" font-size="14.00" fill="#000000">matthew</text>
</g>
<!-- raymond&#45;&gt;matthew -->
<g id="edge1" class="edge">
<title>raymond&#45;&gt;matthew</title>
<path fill="none" stroke="#000000" d="M41.5426,-71.8314C41.5426,-64.131 41.5426,-54.9743 41.5426,-46.4166"/>
<polygon fill="#000000" stroke="#000000" points="45.0427,-46.4132 41.5426,-36.4133 38.0427,-46.4133 45.0427,-46.4132"/>
</g>
</g>
</svg>

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
<svg width="91pt" height="116pt"
 viewBox="0.00 0.00 91.09 116.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 112)">
<title>%3</title>
<polygon fill="#ffffff" stroke="transparent" points="-4,4 -4,-112 87.0852,-112 87.0852,4 -4,4"/>
<!-- raymond -->
<g id="node1" class="node">
<title>raymond</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-90" rx="41.5852" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-85.8" font-family="Times,serif" font-size="14.00" fill="#000000">raymond</text>
</g>
<!-- matthew -->
<g id="node2" class="node">
<title>matthew</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-18" rx="40.6162" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-13.8" font-family="Times,serif" font-size="14.00" fill="#000000">matthew</text>
</g>
<!-- raymond&#45;&gt;matthew -->
<g id="edge1" class="edge">
<title>raymond&#45;&gt;matthew</title>
<path fill="none" stroke="#000000" d="M41.5426,-71.8314C41.5426,-64.131 41.5426,-54.9743 41.5426,-46.4166"/>
<polygon fill="#000000" stroke="#000000" points="45.0427,-46.4132 41.5426,-36.4133 38.0427,-46.4133 45.0427,-46.4132"/>
</g>
</g>
</svg>

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
>>> print graphviz()
<svg width="91pt" height="116pt"
 viewBox="0.00 0.00 91.09 116.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 112)">
<title>%3</title>
<polygon fill="#ffffff" stroke="transparent" points="-4,4 -4,-112 87.0852,-112 87.0852,4 -4,4"/>
<!-- raymond -->
<g id="node1" class="node">
<title>raymond</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-90" rx="41.5852" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-85.8" font-family="Times,serif" font-size="14.00" fill="#000000">raymond</text>
</g>
<!-- matthew -->
<g id="node2" class="node">
<title>matthew</title>
<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-18" rx="40.6162" ry="18"/>
<text text-anchor="middle" x="41.5426" y="-13.8" font-family="Times,serif" font-size="14.00" fill="#000000">matthew</text>
</g>
<!-- raymond&#45;&gt;matthew -->
<g id="edge1" class="edge">
<title>raymond&#45;&gt;matthew</title>
<path fill="none" stroke="#000000" d="M41.5426,-71.8314C41.5426,-64.131 41.5426,-54.9743 41.5426,-46.4166"/>
<polygon fill="#000000" stroke="#000000" points="45.0427,-46.4132 41.5426,-36.4133 38.0427,-46.4133 45.0427,-46.4132"/>
</g>
</g>
</svg>

None
>>> 
>>> 
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
>>> t, e = graphviz('digraph {mark;}')
>>> print t
<svg width="65pt" height="44pt"
 viewBox="0.00 0.00 64.55 44.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 40)">
<title>%3</title>
<polygon fill="#ffffff" stroke="transparent" points="-4,4 -4,-40 60.5548,-40 60.5548,4 -4,4"/>
<!-- mark -->
<g id="node1" class="node">
<title>mark</title>
<ellipse fill="none" stroke="#000000" cx="28.2774" cy="-18" rx="28.0565" ry="18"/>
<text text-anchor="middle" x="28.2774" y="-13.8" font-family="Times,serif" font-size="14.00" fill="#000000">mark</text>
</g>
</g>
</svg>

>>> e
''
>>> t, e = graphviz('diagraph {mark;}')

Traceback (most recent call last):
  File "<pyshell#12>", line 1, in <module>
    t, e = graphviz('diagraph {mark;}')
  File "/Users/raymond/Dropbox/Public/sj178/subprocess_demo.py", line 14, in graphviz
    svg_start = text.index('<svg')
ValueError: substring not found
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
>>> t, e = graphviz('diagraph {mark;}')
>>> t
''
>>> e
"Error: <stdin>: syntax error in line 1 near 'diagraph'\n"
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======

Traceback (most recent call last):
  File "/Users/raymond/Dropbox/Public/sj178/subprocess_demo.py", line 31, in <module>
    print run_command('netstat -s').upper()
  File "/Users/raymond/Dropbox/Public/sj178/subprocess_demo.py", line 24, in run_command
    raise RuntimeError('Command failed')
RuntimeError: Command failed
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======

Traceback (most recent call last):
  File "/Users/raymond/Dropbox/Public/sj178/subprocess_demo.py", line 31, in <module>
    print run_command('netstat -s').upper()
  File "/Users/raymond/Dropbox/Public/sj178/subprocess_demo.py", line 24, in run_command
    raise RuntimeError('Command failed')
RuntimeError: Command failed
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======

Traceback (most recent call last):
  File "/Users/raymond/Dropbox/Public/sj178/subprocess_demo.py", line 31, in <module>
    print run_command('netstat -s').upper()
  File "/Users/raymond/Dropbox/Public/sj178/subprocess_demo.py", line 24, in run_command
    raise RuntimeError('Command failed')
RuntimeError: Command failed
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/subprocess_demo.py ======
TCP:
	0 PACKET SENT
		0 DATA PACKET (0 BYTE)
		0 DATA PACKET (0 BYTE) RETRANSMITTED
		0 RESEND INITIATED BY MTU DISCOVERY
		0 ACK-ONLY PACKET (0 DELAYED)
		0 URG ONLY PACKET
		0 WINDOW PROBE PACKET
		0 WINDOW UPDATE PACKET
		0 CONTROL PACKET
		0 DATA PACKET SENT AFTER FLOW CONTROL
		0 CHECKSUMMED IN SOFTWARE
			0 SEGMENT (0 BYTE) OVER IPV4
			0 SEGMENT (0 BYTE) OVER IPV6
	0 PACKET RECEIVED
		0 ACK (FOR 0 BYTE)
		0 DUPLICATE ACK
		0 ACK FOR UNSENT DATA
		0 PACKET (0 BYTE) RECEIVED IN-SEQUENCE
		0 COMPLETELY DUPLICATE PACKET (0 BYTE)
		0 OLD DUPLICATE PACKET
		0 RECEIVED PACKET DROPPED DUE TO LOW MEMORY
		0 PACKET WITH SOME DUP. DATA (0 BYTE DUPED)
		0 OUT-OF-ORDER PACKET (0 BYTE)
		0 PACKET (0 BYTE) OF DATA AFTER WINDOW
		0 WINDOW PROBE
		0 WINDOW UPDATE PACKET
		0 PACKET RECEIVED AFTER CLOSE
		0 BAD RESET
		0 DISCARDED FOR BAD CHECKSUM
		0 CHECKSUMMED IN SOFTWARE
			0 SEGMENT (0 BYTE) OVER IPV4
			0 SEGMENT (0 BYTE) OVER IPV6
		0 DISCARDED FOR BAD HEADER OFFSET FIELD
		0 DISCARDED BECAUSE PACKET TOO SHORT
	0 CONNECTION REQUEST
	0 CONNECTION ACCEPT
	0 BAD CONNECTION ATTEMPT
	0 LISTEN QUEUE OVERFLOW
	0 CONNECTION ESTABLISHED (INCLUDING ACCEPTS)
	0 CONNECTION CLOSED (INCLUDING 0 DROP)
		0 CONNECTION UPDATED CACHED RTT ON CLOSE
		0 CONNECTION UPDATED CACHED RTT VARIANCE ON CLOSE
		0 CONNECTION UPDATED CACHED SSTHRESH ON CLOSE
	0 EMBRYONIC CONNECTION DROPPED
	0 SEGMENT UPDATED RTT (OF 0 ATTEMPT)
	0 RETRANSMIT TIMEOUT
		0 CONNECTION DROPPED BY REXMIT TIMEOUT
		0 CONNECTION DROPPED AFTER RETRANSMITTING FIN
	0 PERSIST TIMEOUT
		0 CONNECTION DROPPED BY PERSIST TIMEOUT
	0 KEEPALIVE TIMEOUT
		0 KEEPALIVE PROBE SENT
		0 CONNECTION DROPPED BY KEEPALIVE
	0 CORRECT ACK HEADER PREDICTION
	0 CORRECT DATA PACKET HEADER PREDICTION
	0 SACK RECOVERY EPISODE
	0 SEGMENT REXMIT IN SACK RECOVERY EPISODES
	0 BYTE REXMIT IN SACK RECOVERY EPISODES
	0 SACK OPTION (SACK BLOCKS) RECEIVED
	0 SACK OPTION (SACK BLOCKS) SENT
	0 SACK SCOREBOARD OVERFLOW
	0 LRO COALESCED PACKET
		0 TIME LRO FLOW TABLE WAS FULL
		0 COLLISION IN LRO FLOW TABLE
		0 TIME LRO COALESCED 2 PACKETS
		0 TIME LRO COALESCED 3 OR 4 PACKETS
		0 TIME LRO COALESCED 5 OR MORE PACKETS
	0 LIMITED TRANSMIT DONE
	0 EARLY RETRANSMIT DONE
	0 TIME CUMULATIVE ACK ADVANCED ALONG WITH SACK
	0 PROBE TIMEOUT
		0 TIME RETRANSMIT TIMEOUT TRIGGERED AFTER PROBE
		0 TIME PROBE PACKETS WERE SENT FOR AN INTERFACE
		0 TIME COULDN'T SEND PROBE PACKETS FOR AN INTERFACE
		0 TIME FAST RECOVERY AFTER TAIL LOSS
		0 TIME RECOVERED LAST PACKET 
		0 SACK BASED RESCUE RETRANSMIT
	0 CLIENT CONNECTION ATTEMPTED TO NEGOTIATE ECN
		0 CLIENT CONNECTION SUCCESSFULLY NEGOTIATED ECN
		0 TIME GRACEFUL FALLBACK TO NON-ECN CONNECTION
		0 TIME LOST ECN NEGOTIATING SYN, FOLLOWED BY RETRANSMISSION
		0 SERVER CONNECTION ATTEMPTED TO NEGOTIATE ECN
		0 SERVER CONNECTION SUCCESSFULLY NEGOTIATED ECN
		0 TIME LOST ECN NEGOTIATING SYN-ACK, FOLLOWED BY RETRANSMISSION
		0 TIME RECEIVED CONGESTION EXPERIENCED (CE) NOTIFICATION
		0 TIME CWR WAS SENT IN RESPONSE TO ECE
		0 TIME SENT ECE NOTIFICATION
		0 CONNECTION RECEIVED CE ATLEAST ONCE
		0 CONNECTION RECEIVED ECE ATLEAST ONCE
		0 CONNECTION USING ECN HAVE SEEN PACKET LOSS BUT NO CE
		0 CONNECTION USING ECN HAVE SEEN PACKET LOSS AND CE
		0 CONNECTION USING ECN RECEIVED CE BUT NO PACKET LOSS
		0 CONNECTION FELL BACK TO NON-ECN DUE TO SYN-LOSS
		0 CONNECTION FELL BACK TO NON-ECN DUE TO REORDERING
		0 CONNECTION FELL BACK TO NON-ECN DUE TO EXCESSIVE CE-MARKINGS
	0 TIME PACKET REORDERING WAS DETECTED ON A CONNECTION
		0 TIME TRANSMITTED PACKETS WERE REORDERED
		0 TIME FAST RECOVERY WAS DELAYED TO HANDLE REORDERING
		0 TIME RETRANSMISSION WAS AVOIDED BY DELAYING RECOVERY
		0 RETRANSMISSION NOT NEEDED 
	0 TIME DSACK OPTION WAS SENT
		0 TIME DSACK OPTION WAS RECEIVED
		0 TIME DSACK WAS DISABLED ON A CONNECTION
		0 TIME RECOVERED FROM BAD RETRANSMISSION USING DSACK
		0 TIME IGNORED DSACK DUE TO ACK LOSS
		0 TIME IGNORED OLD DSACK OPTIONS
	0 TIME PMTU BLACKHOLE DETECTION, SIZE REVERTED
	0 CONNECTION WERE DROPPED AFTER LONG SLEEP
	0 TIME A TFO-COOKIE HAS BEEN ANNOUNCED
	0 SYN WITH DATA AND A VALID TFO-COOKIE HAVE BEEN RECEIVED
	0 SYN WITH TFO-COOKIE-REQUEST RECEIVED
	0 TIME AN INVALID TFO-COOKIE HAS BEEN RECEIVED
	0 TIME WE REQUESTED A TFO-COOKIE
		0 TIME THE PEER ANNOUNCED A TFO-COOKIE
	0 TIME WE COMBINED SYN WITH DATA AND A TFO-COOKIE
		0 TIME OUR SYN WITH DATA HAS BEEN ACKNOWLEDGED
	0 TIME A CONNECTION-ATTEMPT WITH TFO FELL BACK TO REGULAR TCP
	0 TIME A TFO-CONNECTION BLACKHOLE'D
	0 TIME MAXIMUM SEGMENT SIZE WAS CHANGED TO DEFAULT
	0 TIME MAXIMUM SEGMENT SIZE WAS CHANGED TO MEDIUM
	0 TIME MAXIMUM SEGMENT SIZE WAS CHANGED TO LOW
	0 TIMER DRIFT LESS OR EQUAL TO 1 MS
	0 TIMER DRIFT LESS OR EQUAL TO 10 MS
	0 TIMER DRIFT LESS OR EQUAL TO 20 MS
	0 TIMER DRIFT LESS OR EQUAL TO 50 MS
	0 TIMER DRIFT LESS OR EQUAL TO 100 MS
	0 TIMER DRIFT LESS OR EQUAL TO 200 MS
	0 TIMER DRIFT LESS OR EQUAL TO 500 MS
	0 TIMER DRIFT LESS OR EQUAL TO 1000 MS
	0 TIMER DRIFT GREATER THAN TO 1000 MS
UDP:
	621722 DATAGRAMS RECEIVED
		0 WITH INCOMPLETE HEADER
		0 WITH BAD DATA LENGTH FIELD
		0 WITH BAD CHECKSUM
		54 WITH NO CHECKSUM
		588597 CHECKSUMMED IN SOFTWARE
			300857 DATAGRAMS (93253292 BYTES) OVER IPV4
			287740 DATAGRAMS (120899196 BYTES) OVER IPV6
		5693 DROPPED DUE TO NO SOCKET
		3618 BROADCAST/MULTICAST DATAGRAMS UNDELIVERED
		0 TIME MULTICAST SOURCE FILTER MATCHED
		1 DROPPED DUE TO FULL SOCKET BUFFERS
		0 NOT FOR HASHED PCB
		612410 DELIVERED
	147602 DATAGRAMS OUTPUT
		155410 CHECKSUMMED IN SOFTWARE
			58960 DATAGRAMS (12762103 BYTES) OVER IPV4
			96450 DATAGRAMS (21647354 BYTES) OVER IPV6
ICMP:
	1398 CALLS TO ICMP_ERROR
	0 ERROR NOT GENERATED 'CUZ OLD MESSAGE WAS ICMP
	OUTPUT HISTOGRAM:
		ECHO REPLY: 38
		DESTINATION UNREACHABLE: 1398
	0 MESSAGE WITH BAD CODE FIELDS
	0 MESSAGE < MINIMUM LENGTH
	1 BAD CHECKSUM
	0 MESSAGE WITH BAD LENGTH
	0 MULTICAST ECHO REQUESTS IGNORED
	0 MULTICAST TIMESTAMP REQUESTS IGNORED
	INPUT HISTOGRAM:
		ECHO REPLY: 9
		DESTINATION UNREACHABLE: 2007
		ECHO: 38
		ROUTER ADVERTISEMENT: 147
	38 MESSAGE RESPONSES GENERATED
	ICMP ADDRESS MASK RESPONSES ARE DISABLED
IGMP:
	1639 MESSAGES RECEIVED
	0 MESSAGE RECEIVED WITH TOO FEW BYTES
	0 MESSAGE RECEIVED WITH WRONG TTL
	0 MESSAGE RECEIVED WITH BAD CHECKSUM
	568 V1/V2 MEMBERSHIP QUERIES RECEIVED
	287 V3 MEMBERSHIP QUERIES RECEIVED
	0 MEMBERSHIP QUERIES RECEIVED WITH INVALID FIELD(S)
	837 GENERAL QUERIES RECEIVED
	18 GROUP QUERIES RECEIVED
	0 GROUP-SOURCE QUERIES RECEIVED
	0 GROUP-SOURCE QUERIES DROPPED
	784 MEMBERSHIP REPORTS RECEIVED
	0 MEMBERSHIP REPORT RECEIVED WITH INVALID FIELD(S)
	784 MEMBERSHIP REPORTS RECEIVED FOR GROUPS TO WHICH WE BELONG
	0 V3 REPORT RECEIVED WITHOUT ROUTER ALERT
	893 MEMBERSHIP REPORTS SENT
IPSEC:
	0 INBOUND PACKET PROCESSED SUCCESSFULLY
	0 INBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 INBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID INBOUND PACKET
	0 INBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 INBOUND PACKET FAILED GETTING SPI
	0 INBOUND PACKET FAILED ON AH REPLAY CHECK
	0 INBOUND PACKET FAILED ON ESP REPLAY CHECK
	0 INBOUND PACKET CONSIDERED AUTHENTIC
	0 INBOUND PACKET FAILED ON AUTHENTICATION
	0 OUTBOUND PACKET PROCESSED SUCCESSFULLY
	0 OUTBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 OUTBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID OUTBOUND PACKET
	0 OUTBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 OUTBOUND PACKET WITH NO ROUTE
ARP:
	1872 BROADAST ARP REQUESTS SENT
	9 UNICAST ARP REQUESTS SENT
	3324 ARP REPLIES SENT
	0 ARP ANNOUNCEMENT SENT
	11634 ARP REQUESTS RECEIVED
	1620 ARP REPLIES RECEIVED
	13256 TOTAL ARP PACKETS RECEIVED
	0 ARP CONFLICT PROBE SENT
	0 INVALID ARP RESOLVE REQUEST
	0 TOTAL PACKET DROPPED DUE TO LACK OF MEMORY
	0 TOTAL PACKET HELD AWAITING ARP REPLY
	43 TOTAL PACKETS DROPPED DUE TO NO ARP ENTRY
	378 TOTAL PACKETS DROPPED DURING ARP ENTRY REMOVAL
	1652 ARP ENTRIES TIMED OUT
	0 DUPLICATE IP SEEN
MPTCP:
	0 DATA PACKET SENT
	0 DATA BYTE SENT
	0 DATA PACKET RECEIVED
	0 DATA BYTE RECEIVED
	0 PACKET WITH AN INVALID MPCAP OPTION
	0 PACKET WITH AN INVALID MPJOIN OPTION
	0 TIME PRIMARY SUBFLOW FELL BACK TO TCP
	0 TIME SECONDARY SUBFLOW FELL BACK TO TCP
	0 DSS OPTION DROP
	0 OTHER INVALID MPTCP OPTION
	0 TIME THE MPTCP SUBFLOW WINDOW WAS REDUCED
	0 BAD DSS CHECKSUM
	0 TIME RECEIVED OUT OF ORDER DATA 
	0 SUBFLOW SWITCH
	0 SUBFLOW SWITCH DUE TO ADVISORY
	0 SUBFLOW SWITCH DUE TO RTT
	0 SUBFLOW SWITCH DUE TO RTO
	0 SUBFLOW SWITCH DUE TO PEER
	0 NUMBER OF SUBFLOW PROBE
IP6:
	808506 TOTAL PACKETS RECEIVED
		0 WITH SIZE SMALLER THAN MINIMUM
		0 WITH DATA SIZE < DATA LENGTH
		0 WITH DATA SIZE > DATA LENGTH
			0 PACKET FORCED TO SOFTWARE CHECKSUM
		0 WITH BAD OPTIONS
		168 WITH INCORRECT VERSION NUMBER
		8 FRAGMENTS RECEIVED
			0 DROPPED (DUP OR OUT OF SPACE)
			0 DROPPED AFTER TIMEOUT
			0 EXCEEDED LIMIT
			4 REASSEMBLED OK
			0 ATOMIC FRAGMENTS RECEIVED
		728564 PACKETS FOR THIS HOST
		0 PACKET FORWARDED
		37198 PACKETS NOT FORWARDABLE
		0 REDIRECT SENT
		37141 MULTICAST PACKETS WHICH WE DON'T JOIN
		0 PACKET WHOSE HEADERS ARE NOT CONTINUOUS
		0 TUNNELING PACKET THAT CAN'T FIND GIF
		0 PACKET DISCARDED DUE TO TOO MAY HEADERS
		0 FORWARD CACHE HIT
		0 FORWARD CACHE MISS
		0 PACKET DROPPED DUE TO NO BUFS FOR CONTROL DATA
	352392 PACKETS SENT FROM THIS HOST
		0 PACKET SENT WITH FABRICATED IP HEADER
		0 OUTPUT PACKET DROPPED DUE TO NO BUFS, ETC.
		2291 OUTPUT PACKETS DISCARDED DUE TO NO ROUTE
		0 OUTPUT DATAGRAM FRAGMENTED
		0 FRAGMENT CREATED
		0 DATAGRAM THAT CAN'T BE FRAGMENTED
		0 PACKET THAT VIOLATED SCOPE RULES
		0 PACKET DROPPED DUE TO NECP POLICY
	INPUT HISTOGRAM:
		HOP BY HOP: 6005
		TCP: 430610
		UDP: 327266
		FRAGMENT: 8
		ICMP6: 43255
		PIM: 1194
	MBUF STATISTICS:
		1787 ONE MBUF
		TWO OR MORE MBUF:
			LO0= 11148
			UTUN1= 12
		795559 ONE EXT MBUF
		0 TWO OR MORE EXT MBUF
		0 FAILURE OF SOURCE ADDRESS SELECTION
		SOURCE ADDRESSES ON AN OUTGOING I/F
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESSES ON A NON-OUTGOING I/F
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESSES OF SAME SCOPE
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESSES OF A DIFFERENT SCOPE
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		DEPRECATED SOURCE ADDRESSES
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESS SELECTION
			19258 RULES DEFAULT
			0 RULE PREFER SAME ADDRESS
			6005 RULES PREFER APPROPRIATE SCOPE
			0 RULE AVOID DEPRECATED ADDRESSES
			0 RULE PREFER HOME ADDRESSES
			0 RULE PREFER OUTGOING INTERFACE
			10 RULES PREFER MATCHING LABEL
			47351 RULES PREFER TEMPORARY ADDRESSES
			0 RULE PREFER ADDRESSES ON ALIVE INTERFACES
			0 RULE USE LONGEST MATCHING PREFIX
		0 DUPLICATE ADDRESS DETECTION COLLISION
		0 DUPLICATE ADDRESS DETECTION NS LOOP
		0 TIME IGNORED SOURCE ON SECONDARY EXPENSIVE I/F
ICMP6:
	1736 CALLS TO ICMP_ERROR
	0 ERROR NOT GENERATED BECAUSE OLD MESSAGE WAS ICMP ERROR OR SO
	0 ERROR NOT GENERATED BECAUSE RATE LIMITATION
	OUTPUT HISTOGRAM:
		UNREACH: 1736
		MLDV1 LISTENER REPORT: 77
		MLDV1 LISTENER DONE: 11
		ROUTER SOLICITATION: 123
		NEIGHBOR SOLICITATION: 5384
		NEIGHBOR ADVERTISEMENT: 4416
		MLDV2 LISTENER REPORT: 1338
	0 MESSAGE WITH BAD CODE FIELDS
	0 MESSAGE < MINIMUM LENGTH
	0 BAD CHECKSUM
	0 MESSAGE WITH BAD LENGTH
	INPUT HISTOGRAM:
		UNREACH: 150
		MULTICAST LISTENER QUERY: 2255
		ROUTER ADVERTISEMENT: 31293
		NEIGHBOR SOLICITATION: 4416
		NEIGHBOR ADVERTISEMENT: 4531
	HISTOGRAM OF ERROR MESSAGES TO BE GENERATED:
		0 NO ROUTE
		0 ADMINISTRATIVELY PROHIBITED
		0 BEYOND SCOPE
		150 ADDRESS UNREACHABLE
		1586 PORT UNREACHABLE
		0 PACKET TOO BIG
		0 TIME EXCEED TRANSIT
		0 TIME EXCEED REASSEMBLY
		0 ERRONEOUS HEADER FIELD
		0 UNRECOGNIZED NEXT HEADER
		0 UNRECOGNIZED OPTION
		0 REDIRECT
		0 UNKNOWN
	0 MESSAGE RESPONSE GENERATED
	0 MESSAGE WITH TOO MANY ND OPTIONS
	0 MESSAGE WITH BAD ND OPTIONS
	0 BAD NEIGHBOR SOLICITATION MESSAGE
	0 BAD NEIGHBOR ADVERTISEMENT MESSAGE
	0 BAD ROUTER SOLICITATION MESSAGE
	0 BAD ROUTER ADVERTISEMENT MESSAGE
	0 BAD REDIRECT MESSAGE
	0 PATH MTU CHANGE
	0 DROPPED FRAGMENTED NDP MESSAGE
IPSEC6:
	0 INBOUND PACKET PROCESSED SUCCESSFULLY
	0 INBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 INBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID INBOUND PACKET
	0 INBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 INBOUND PACKET FAILED GETTING SPI
	0 INBOUND PACKET FAILED ON AH REPLAY CHECK
	0 INBOUND PACKET FAILED ON ESP REPLAY CHECK
	0 INBOUND PACKET CONSIDERED AUTHENTIC
	0 INBOUND PACKET FAILED ON AUTHENTICATION
	0 OUTBOUND PACKET PROCESSED SUCCESSFULLY
	0 OUTBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 OUTBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID OUTBOUND PACKET
	0 OUTBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 OUTBOUND PACKET WITH NO ROUTE
RIP6:
	0 MESSAGE RECEIVED
	0 CHECKSUM CALCULATION ON INBOUND
	0 MESSAGE WITH BAD CHECKSUM
	0 MESSAGE DROPPED DUE TO NO SOCKET
	0 MULTICAST MESSAGE DROPPED DUE TO NO SOCKET
	0 MESSAGE DROPPED DUE TO FULL SOCKET BUFFERS
	0 DELIVERED
	0 DATAGRAM OUTPUT
PFKEY:
	0 REQUEST SENT TO USERLAND
	0 BYTE SENT TO USERLAND
	0 MESSAGE WITH INVALID LENGTH FIELD
	0 MESSAGE WITH INVALID VERSION FIELD
	0 MESSAGE WITH INVALID MESSAGE TYPE FIELD
	0 MESSAGE TOO SHORT
	0 MESSAGE WITH MEMORY ALLOCATION FAILURE
	0 MESSAGE WITH DUPLICATE EXTENSION
	0 MESSAGE WITH INVALID EXTENSION TYPE
	0 MESSAGE WITH INVALID SA TYPE
	0 MESSAGE WITH INVALID ADDRESS EXTENSION
	0 REQUEST SENT FROM USERLAND
	0 BYTE SENT FROM USERLAND
	0 MESSAGE TOWARD SINGLE SOCKET
	0 MESSAGE TOWARD ALL SOCKETS
	0 MESSAGE TOWARD REGISTERED SOCKETS
	0 MESSAGE WITH MEMORY ALLOCATION FAILURE
KEVT:
	24 CURRENT KERNEL CONTROL SOCKETS
	19074 KERNEL CONTROL GENERATION COUNT
	0 BAD VENDOR FAILURE
	7447 MESSAGE TOO BIG FAILURES
	0 OUT OF MEMORY FAILURE
	0 MESSAGE DROPPED DUE TO FULL SOCKET BUFFERS
	278703 MESSAGES POSTED
KCTL:
	0 TOTAL KERNEL CONTROL MODULE REGISTERED
	12 CURRENT KERNEL CONTROL MODULES REGISTERED
	55 CURRENT KERNEL CONTROL SOCKETS
	1119 KERNEL CONTROL GENERATION COUNT
	581 CONNECTION ATTEMPTS
	0 CONNECTION FAILURE
	35 SEND FAILURES
	0 SEND LIST FAILURE
	0 ENQUEUE FAILURE
	0 PACKET DROPPED DUE TO FULL SOCKET BUFFERS
XBKIDLE:
	1 MAX PER PROCESS
	600 MAXIMUM TIME (SECONDS)
	131072 HIGH WATER MARK
	0 SOCKET OPTION NOT SUPPORTED FAILURE
	0 TOO MANY SOCKETS FAILURE
	0 TOTAL SOCKET REQUESTED OK
	0 EXTENDED BK IDLE SOCKET
	0 NO CELLULAR FAILURE
	0 NO TIME FAILURES
	0 FORCED DEFUNCT SOCKET
	0 RESUMED SOCKET
	0 TIMEOUT EXPIRED FAILURE
	0 TIMER RESCHEDULED
	0 NO DELEGATED FAILURE
NET_API:
	2 INTERFACE FILTERS CURRENTLY ATTACHED
	2 INTERFACE FILTERS ATTACHED SINCE BOOT
	2 INTERFACE FILTERS ATTACHED SINCE BOOT BY OS
	0 IP FILTER CURRENTLY ATTACHED
	0 IP FILTER ATTACHED SINCE BOOT
	0 IP FILTER ATTACHED SINCE BOOT BY OS
	4 SOCKET FILTERS CURRENTLY ATTACHED
	4 SOCKET FILTERS ATTACHED SINCE BOOT
	4 SOCKET FILTERS ATTACHED SINCE BOOT BY OS
	328925 SOCKETS ALLOCATED SINCE BOOT
	75 SOCKETS ALLOCATED IN-KERNEL SINCE BOOT
	75 SOCKETS ALLOCATED IN-KERNEL BY OS
	2493 SOCKETS WITH NECP CLIENT UUID SINCE BOOT
	105006 LOCAL DOMAIN SOCKETS ALLOCATED SINCE BOOT
	1199 ROUTE DOMAIN SOCKETS ALLOCATED SINCE BOOT
	124898 INET DOMAIN SOCKETS ALLOCATED SINCE BOOT
	60788 INET6 DOMAIN SOCKETS ALLOCATED SINCE BOOT
	10130 SYSTEM DOMAIN SOCKETS ALLOCATED SINCE BOOT
	0 MULTIPATH DOMAIN SOCKET ALLOCATED SINCE BOOT
	0 KEY DOMAIN SOCKET ALLOCATED SINCE BOOT
	5 NDRV DOMAIN SOCKETS ALLOCATED SINCE BOOT
	0 OTHER DOMAINS SOCKET ALLOCATED SINCE BOOT
	15625 IPV4 STREAM SOCKETS CREATED SINCE BOOT
	109273 IPV4 DATAGRAM SOCKETS CREATED SINCE BOOT
	10493 IPV4 DATAGRAM SOCKETS CONNECTED
	38717 IPV4 DNS SOCKETS
	102542 IPV4 DATAGRAM SOCKETS WITHOUT DATA
	7671 IPV6 STREAM SOCKETS CREATED SINCE BOOT
	53117 IPV6 DATAGRAM SOCKETS CREATED SINCE BOOT
	35524 IPV6 DATAGRAM SOCKETS CONNECTED
	0 IPV6 DNS SOCKET
	28708 IPV6 DATAGRAM SOCKETS WITHOUT DATA
	1115 SOCKET MULTICAST JOINS SINCE BOOT
	1115 SOCKET MULTICAST JOINS SINCE BOOT BY OS
	0 IPV4 STREAM NEXUS FLOW ADDED SINCE BOOT
	0 IPV4 DATAGRAM NEXUS FLOW ADDED SINCE BOOT
	0 IPV6 STREAM NEXUS FLOW ADDED SINCE BOOT
	0 IPV6 DATAGRAM NEXUS FLOW ADDED SINCE BOOT
	12 INTERFACES CURRENTLY ALLOCATED
	12 INTERFACES ALLOCATED SINCE BOOT
	12 INTERFACES CURRENTLY ALLOCATED BY OS
	12 EXTENDED INTERFACES ALLOCATED SINCE BOOT BY OS
	2 PF ADDRULE OPERATIONS SINCE BOOT
	0 PF ADDRULE OPERATION SINCE BOOT BY OS
	0 VMNET START SINCE BOOT

TCP:
	0 PACKET SENT
		0 DATA PACKET (0 BYTE)
		0 DATA PACKET (0 BYTE) RETRANSMITTED
		0 RESEND INITIATED BY MTU DISCOVERY
		0 ACK-ONLY PACKET (0 DELAYED)
		0 URG ONLY PACKET
		0 WINDOW PROBE PACKET
		0 WINDOW UPDATE PACKET
		0 CONTROL PACKET
		0 DATA PACKET SENT AFTER FLOW CONTROL
		0 CHECKSUMMED IN SOFTWARE
			0 SEGMENT (0 BYTE) OVER IPV4
			0 SEGMENT (0 BYTE) OVER IPV6
	0 PACKET RECEIVED
		0 ACK (FOR 0 BYTE)
		0 DUPLICATE ACK
		0 ACK FOR UNSENT DATA
		0 PACKET (0 BYTE) RECEIVED IN-SEQUENCE
		0 COMPLETELY DUPLICATE PACKET (0 BYTE)
		0 OLD DUPLICATE PACKET
		0 RECEIVED PACKET DROPPED DUE TO LOW MEMORY
		0 PACKET WITH SOME DUP. DATA (0 BYTE DUPED)
		0 OUT-OF-ORDER PACKET (0 BYTE)
		0 PACKET (0 BYTE) OF DATA AFTER WINDOW
		0 WINDOW PROBE
		0 WINDOW UPDATE PACKET
		0 PACKET RECEIVED AFTER CLOSE
		0 BAD RESET
		0 DISCARDED FOR BAD CHECKSUM
		0 CHECKSUMMED IN SOFTWARE
			0 SEGMENT (0 BYTE) OVER IPV4
			0 SEGMENT (0 BYTE) OVER IPV6
		0 DISCARDED FOR BAD HEADER OFFSET FIELD
		0 DISCARDED BECAUSE PACKET TOO SHORT
	0 CONNECTION REQUEST
	0 CONNECTION ACCEPT
	0 BAD CONNECTION ATTEMPT
	0 LISTEN QUEUE OVERFLOW
	0 CONNECTION ESTABLISHED (INCLUDING ACCEPTS)
	0 CONNECTION CLOSED (INCLUDING 0 DROP)
		0 CONNECTION UPDATED CACHED RTT ON CLOSE
		0 CONNECTION UPDATED CACHED RTT VARIANCE ON CLOSE
		0 CONNECTION UPDATED CACHED SSTHRESH ON CLOSE
	0 EMBRYONIC CONNECTION DROPPED
	0 SEGMENT UPDATED RTT (OF 0 ATTEMPT)
	0 RETRANSMIT TIMEOUT
		0 CONNECTION DROPPED BY REXMIT TIMEOUT
		0 CONNECTION DROPPED AFTER RETRANSMITTING FIN
	0 PERSIST TIMEOUT
		0 CONNECTION DROPPED BY PERSIST TIMEOUT
	0 KEEPALIVE TIMEOUT
		0 KEEPALIVE PROBE SENT
		0 CONNECTION DROPPED BY KEEPALIVE
	0 CORRECT ACK HEADER PREDICTION
	0 CORRECT DATA PACKET HEADER PREDICTION
	0 SACK RECOVERY EPISODE
	0 SEGMENT REXMIT IN SACK RECOVERY EPISODES
	0 BYTE REXMIT IN SACK RECOVERY EPISODES
	0 SACK OPTION (SACK BLOCKS) RECEIVED
	0 SACK OPTION (SACK BLOCKS) SENT
	0 SACK SCOREBOARD OVERFLOW
	0 LRO COALESCED PACKET
		0 TIME LRO FLOW TABLE WAS FULL
		0 COLLISION IN LRO FLOW TABLE
		0 TIME LRO COALESCED 2 PACKETS
		0 TIME LRO COALESCED 3 OR 4 PACKETS
		0 TIME LRO COALESCED 5 OR MORE PACKETS
	0 LIMITED TRANSMIT DONE
	0 EARLY RETRANSMIT DONE
	0 TIME CUMULATIVE ACK ADVANCED ALONG WITH SACK
	0 PROBE TIMEOUT
		0 TIME RETRANSMIT TIMEOUT TRIGGERED AFTER PROBE
		0 TIME PROBE PACKETS WERE SENT FOR AN INTERFACE
		0 TIME COULDN'T SEND PROBE PACKETS FOR AN INTERFACE
		0 TIME FAST RECOVERY AFTER TAIL LOSS
		0 TIME RECOVERED LAST PACKET 
		0 SACK BASED RESCUE RETRANSMIT
	0 CLIENT CONNECTION ATTEMPTED TO NEGOTIATE ECN
		0 CLIENT CONNECTION SUCCESSFULLY NEGOTIATED ECN
		0 TIME GRACEFUL FALLBACK TO NON-ECN CONNECTION
		0 TIME LOST ECN NEGOTIATING SYN, FOLLOWED BY RETRANSMISSION
		0 SERVER CONNECTION ATTEMPTED TO NEGOTIATE ECN
		0 SERVER CONNECTION SUCCESSFULLY NEGOTIATED ECN
		0 TIME LOST ECN NEGOTIATING SYN-ACK, FOLLOWED BY RETRANSMISSION
		0 TIME RECEIVED CONGESTION EXPERIENCED (CE) NOTIFICATION
		0 TIME CWR WAS SENT IN RESPONSE TO ECE
		0 TIME SENT ECE NOTIFICATION
		0 CONNECTION RECEIVED CE ATLEAST ONCE
		0 CONNECTION RECEIVED ECE ATLEAST ONCE
		0 CONNECTION USING ECN HAVE SEEN PACKET LOSS BUT NO CE
		0 CONNECTION USING ECN HAVE SEEN PACKET LOSS AND CE
		0 CONNECTION USING ECN RECEIVED CE BUT NO PACKET LOSS
		0 CONNECTION FELL BACK TO NON-ECN DUE TO SYN-LOSS
		0 CONNECTION FELL BACK TO NON-ECN DUE TO REORDERING
		0 CONNECTION FELL BACK TO NON-ECN DUE TO EXCESSIVE CE-MARKINGS
	0 TIME PACKET REORDERING WAS DETECTED ON A CONNECTION
		0 TIME TRANSMITTED PACKETS WERE REORDERED
		0 TIME FAST RECOVERY WAS DELAYED TO HANDLE REORDERING
		0 TIME RETRANSMISSION WAS AVOIDED BY DELAYING RECOVERY
		0 RETRANSMISSION NOT NEEDED 
	0 TIME DSACK OPTION WAS SENT
		0 TIME DSACK OPTION WAS RECEIVED
		0 TIME DSACK WAS DISABLED ON A CONNECTION
		0 TIME RECOVERED FROM BAD RETRANSMISSION USING DSACK
		0 TIME IGNORED DSACK DUE TO ACK LOSS
		0 TIME IGNORED OLD DSACK OPTIONS
	0 TIME PMTU BLACKHOLE DETECTION, SIZE REVERTED
	0 CONNECTION WERE DROPPED AFTER LONG SLEEP
	0 TIME A TFO-COOKIE HAS BEEN ANNOUNCED
	0 SYN WITH DATA AND A VALID TFO-COOKIE HAVE BEEN RECEIVED
	0 SYN WITH TFO-COOKIE-REQUEST RECEIVED
	0 TIME AN INVALID TFO-COOKIE HAS BEEN RECEIVED
	0 TIME WE REQUESTED A TFO-COOKIE
		0 TIME THE PEER ANNOUNCED A TFO-COOKIE
	0 TIME WE COMBINED SYN WITH DATA AND A TFO-COOKIE
		0 TIME OUR SYN WITH DATA HAS BEEN ACKNOWLEDGED
	0 TIME A CONNECTION-ATTEMPT WITH TFO FELL BACK TO REGULAR TCP
	0 TIME A TFO-CONNECTION BLACKHOLE'D
	0 TIME MAXIMUM SEGMENT SIZE WAS CHANGED TO DEFAULT
	0 TIME MAXIMUM SEGMENT SIZE WAS CHANGED TO MEDIUM
	0 TIME MAXIMUM SEGMENT SIZE WAS CHANGED TO LOW
	0 TIMER DRIFT LESS OR EQUAL TO 1 MS
	0 TIMER DRIFT LESS OR EQUAL TO 10 MS
	0 TIMER DRIFT LESS OR EQUAL TO 20 MS
	0 TIMER DRIFT LESS OR EQUAL TO 50 MS
	0 TIMER DRIFT LESS OR EQUAL TO 100 MS
	0 TIMER DRIFT LESS OR EQUAL TO 200 MS
	0 TIMER DRIFT LESS OR EQUAL TO 500 MS
	0 TIMER DRIFT LESS OR EQUAL TO 1000 MS
	0 TIMER DRIFT GREATER THAN TO 1000 MS
UDP:
	621748 DATAGRAMS RECEIVED
		0 WITH INCOMPLETE HEADER
		0 WITH BAD DATA LENGTH FIELD
		0 WITH BAD CHECKSUM
		54 WITH NO CHECKSUM
		588623 CHECKSUMMED IN SOFTWARE
			300869 DATAGRAMS (93255942 BYTES) OVER IPV4
			287754 DATAGRAMS (120902267 BYTES) OVER IPV6
		5693 DROPPED DUE TO NO SOCKET
		3618 BROADCAST/MULTICAST DATAGRAMS UNDELIVERED
		0 TIME MULTICAST SOURCE FILTER MATCHED
		1 DROPPED DUE TO FULL SOCKET BUFFERS
		0 NOT FOR HASHED PCB
		612436 DELIVERED
	147602 DATAGRAMS OUTPUT
		155410 CHECKSUMMED IN SOFTWARE
			58960 DATAGRAMS (12762103 BYTES) OVER IPV4
			96450 DATAGRAMS (21647354 BYTES) OVER IPV6
ICMP:
	1398 CALLS TO ICMP_ERROR
	0 ERROR NOT GENERATED 'CUZ OLD MESSAGE WAS ICMP
	OUTPUT HISTOGRAM:
		ECHO REPLY: 38
		DESTINATION UNREACHABLE: 1398
	0 MESSAGE WITH BAD CODE FIELDS
	0 MESSAGE < MINIMUM LENGTH
	1 BAD CHECKSUM
	0 MESSAGE WITH BAD LENGTH
	0 MULTICAST ECHO REQUESTS IGNORED
	0 MULTICAST TIMESTAMP REQUESTS IGNORED
	INPUT HISTOGRAM:
		ECHO REPLY: 9
		DESTINATION UNREACHABLE: 2007
		ECHO: 38
		ROUTER ADVERTISEMENT: 147
	38 MESSAGE RESPONSES GENERATED
	ICMP ADDRESS MASK RESPONSES ARE DISABLED
IGMP:
	1639 MESSAGES RECEIVED
	0 MESSAGE RECEIVED WITH TOO FEW BYTES
	0 MESSAGE RECEIVED WITH WRONG TTL
	0 MESSAGE RECEIVED WITH BAD CHECKSUM
	568 V1/V2 MEMBERSHIP QUERIES RECEIVED
	287 V3 MEMBERSHIP QUERIES RECEIVED
	0 MEMBERSHIP QUERIES RECEIVED WITH INVALID FIELD(S)
	837 GENERAL QUERIES RECEIVED
	18 GROUP QUERIES RECEIVED
	0 GROUP-SOURCE QUERIES RECEIVED
	0 GROUP-SOURCE QUERIES DROPPED
	784 MEMBERSHIP REPORTS RECEIVED
	0 MEMBERSHIP REPORT RECEIVED WITH INVALID FIELD(S)
	784 MEMBERSHIP REPORTS RECEIVED FOR GROUPS TO WHICH WE BELONG
	0 V3 REPORT RECEIVED WITHOUT ROUTER ALERT
	893 MEMBERSHIP REPORTS SENT
IPSEC:
	0 INBOUND PACKET PROCESSED SUCCESSFULLY
	0 INBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 INBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID INBOUND PACKET
	0 INBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 INBOUND PACKET FAILED GETTING SPI
	0 INBOUND PACKET FAILED ON AH REPLAY CHECK
	0 INBOUND PACKET FAILED ON ESP REPLAY CHECK
	0 INBOUND PACKET CONSIDERED AUTHENTIC
	0 INBOUND PACKET FAILED ON AUTHENTICATION
	0 OUTBOUND PACKET PROCESSED SUCCESSFULLY
	0 OUTBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 OUTBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID OUTBOUND PACKET
	0 OUTBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 OUTBOUND PACKET WITH NO ROUTE
ARP:
	1872 BROADAST ARP REQUESTS SENT
	9 UNICAST ARP REQUESTS SENT
	3324 ARP REPLIES SENT
	0 ARP ANNOUNCEMENT SENT
	11634 ARP REQUESTS RECEIVED
	1620 ARP REPLIES RECEIVED
	13256 TOTAL ARP PACKETS RECEIVED
	0 ARP CONFLICT PROBE SENT
	0 INVALID ARP RESOLVE REQUEST
	0 TOTAL PACKET DROPPED DUE TO LACK OF MEMORY
	0 TOTAL PACKET HELD AWAITING ARP REPLY
	43 TOTAL PACKETS DROPPED DUE TO NO ARP ENTRY
	378 TOTAL PACKETS DROPPED DURING ARP ENTRY REMOVAL
	1652 ARP ENTRIES TIMED OUT
	0 DUPLICATE IP SEEN
MPTCP:
	0 DATA PACKET SENT
	0 DATA BYTE SENT
	0 DATA PACKET RECEIVED
	0 DATA BYTE RECEIVED
	0 PACKET WITH AN INVALID MPCAP OPTION
	0 PACKET WITH AN INVALID MPJOIN OPTION
	0 TIME PRIMARY SUBFLOW FELL BACK TO TCP
	0 TIME SECONDARY SUBFLOW FELL BACK TO TCP
	0 DSS OPTION DROP
	0 OTHER INVALID MPTCP OPTION
	0 TIME THE MPTCP SUBFLOW WINDOW WAS REDUCED
	0 BAD DSS CHECKSUM
	0 TIME RECEIVED OUT OF ORDER DATA 
	0 SUBFLOW SWITCH
	0 SUBFLOW SWITCH DUE TO ADVISORY
	0 SUBFLOW SWITCH DUE TO RTT
	0 SUBFLOW SWITCH DUE TO RTO
	0 SUBFLOW SWITCH DUE TO PEER
	0 NUMBER OF SUBFLOW PROBE
IP6:
	808522 TOTAL PACKETS RECEIVED
		0 WITH SIZE SMALLER THAN MINIMUM
		0 WITH DATA SIZE < DATA LENGTH
		0 WITH DATA SIZE > DATA LENGTH
			0 PACKET FORCED TO SOFTWARE CHECKSUM
		0 WITH BAD OPTIONS
		168 WITH INCORRECT VERSION NUMBER
		8 FRAGMENTS RECEIVED
			0 DROPPED (DUP OR OUT OF SPACE)
			0 DROPPED AFTER TIMEOUT
			0 EXCEEDED LIMIT
			4 REASSEMBLED OK
			0 ATOMIC FRAGMENTS RECEIVED
		728578 PACKETS FOR THIS HOST
		0 PACKET FORWARDED
		37198 PACKETS NOT FORWARDABLE
		0 REDIRECT SENT
		37141 MULTICAST PACKETS WHICH WE DON'T JOIN
		0 PACKET WHOSE HEADERS ARE NOT CONTINUOUS
		0 TUNNELING PACKET THAT CAN'T FIND GIF
		0 PACKET DISCARDED DUE TO TOO MAY HEADERS
		0 FORWARD CACHE HIT
		0 FORWARD CACHE MISS
		0 PACKET DROPPED DUE TO NO BUFS FOR CONTROL DATA
	352392 PACKETS SENT FROM THIS HOST
		0 PACKET SENT WITH FABRICATED IP HEADER
		0 OUTPUT PACKET DROPPED DUE TO NO BUFS, ETC.
		2291 OUTPUT PACKETS DISCARDED DUE TO NO ROUTE
		0 OUTPUT DATAGRAM FRAGMENTED
		0 FRAGMENT CREATED
		0 DATAGRAM THAT CAN'T BE FRAGMENTED
		0 PACKET THAT VIOLATED SCOPE RULES
		0 PACKET DROPPED DUE TO NECP POLICY
	INPUT HISTOGRAM:
		HOP BY HOP: 6005
		TCP: 430610
		UDP: 327280
		FRAGMENT: 8
		ICMP6: 43257
		PIM: 1194
	MBUF STATISTICS:
		1787 ONE MBUF
		TWO OR MORE MBUF:
			LO0= 11148
			UTUN1= 12
		795575 ONE EXT MBUF
		0 TWO OR MORE EXT MBUF
		0 FAILURE OF SOURCE ADDRESS SELECTION
		SOURCE ADDRESSES ON AN OUTGOING I/F
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESSES ON A NON-OUTGOING I/F
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESSES OF SAME SCOPE
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESSES OF A DIFFERENT SCOPE
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		DEPRECATED SOURCE ADDRESSES
			0 ADDRESSES SCOPE=0
			0 NODE-LOCAL
			0 LINK-LOCAL
			0 ADDRESSES SCOPE=3
			0 ADDRESSES SCOPE=4
			0 SITE-LOCAL
			0 ADDRESSES SCOPE=6
			0 ADDRESSES SCOPE=7
			0 ADDRESSES SCOPE=8
			0 ADDRESSES SCOPE=9
			0 ADDRESSES SCOPE=A
			0 ADDRESSES SCOPE=B
			0 ADDRESSES SCOPE=C
			0 ADDRESSES SCOPE=D
			0 GLOBAL
			0 ADDRESSES SCOPE=F
		SOURCE ADDRESS SELECTION
			19258 RULES DEFAULT
			0 RULE PREFER SAME ADDRESS
			6005 RULES PREFER APPROPRIATE SCOPE
			0 RULE AVOID DEPRECATED ADDRESSES
			0 RULE PREFER HOME ADDRESSES
			0 RULE PREFER OUTGOING INTERFACE
			10 RULES PREFER MATCHING LABEL
			47351 RULES PREFER TEMPORARY ADDRESSES
			0 RULE PREFER ADDRESSES ON ALIVE INTERFACES
			0 RULE USE LONGEST MATCHING PREFIX
		0 DUPLICATE ADDRESS DETECTION COLLISION
		0 DUPLICATE ADDRESS DETECTION NS LOOP
		0 TIME IGNORED SOURCE ON SECONDARY EXPENSIVE I/F
ICMP6:
	1736 CALLS TO ICMP_ERROR
	0 ERROR NOT GENERATED BECAUSE OLD MESSAGE WAS ICMP ERROR OR SO
	0 ERROR NOT GENERATED BECAUSE RATE LIMITATION
	OUTPUT HISTOGRAM:
		UNREACH: 1736
		MLDV1 LISTENER REPORT: 77
		MLDV1 LISTENER DONE: 11
		ROUTER SOLICITATION: 123
		NEIGHBOR SOLICITATION: 5384
		NEIGHBOR ADVERTISEMENT: 4416
		MLDV2 LISTENER REPORT: 1338
	0 MESSAGE WITH BAD CODE FIELDS
	0 MESSAGE < MINIMUM LENGTH
	0 BAD CHECKSUM
	0 MESSAGE WITH BAD LENGTH
	INPUT HISTOGRAM:
		UNREACH: 150
		MULTICAST LISTENER QUERY: 2255
		ROUTER ADVERTISEMENT: 31295
		NEIGHBOR SOLICITATION: 4416
		NEIGHBOR ADVERTISEMENT: 4531
	HISTOGRAM OF ERROR MESSAGES TO BE GENERATED:
		0 NO ROUTE
		0 ADMINISTRATIVELY PROHIBITED
		0 BEYOND SCOPE
		150 ADDRESS UNREACHABLE
		1586 PORT UNREACHABLE
		0 PACKET TOO BIG
		0 TIME EXCEED TRANSIT
		0 TIME EXCEED REASSEMBLY
		0 ERRONEOUS HEADER FIELD
		0 UNRECOGNIZED NEXT HEADER
		0 UNRECOGNIZED OPTION
		0 REDIRECT
		0 UNKNOWN
	0 MESSAGE RESPONSE GENERATED
	0 MESSAGE WITH TOO MANY ND OPTIONS
	0 MESSAGE WITH BAD ND OPTIONS
	0 BAD NEIGHBOR SOLICITATION MESSAGE
	0 BAD NEIGHBOR ADVERTISEMENT MESSAGE
	0 BAD ROUTER SOLICITATION MESSAGE
	0 BAD ROUTER ADVERTISEMENT MESSAGE
	0 BAD REDIRECT MESSAGE
	0 PATH MTU CHANGE
	0 DROPPED FRAGMENTED NDP MESSAGE
IPSEC6:
	0 INBOUND PACKET PROCESSED SUCCESSFULLY
	0 INBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 INBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID INBOUND PACKET
	0 INBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 INBOUND PACKET FAILED GETTING SPI
	0 INBOUND PACKET FAILED ON AH REPLAY CHECK
	0 INBOUND PACKET FAILED ON ESP REPLAY CHECK
	0 INBOUND PACKET CONSIDERED AUTHENTIC
	0 INBOUND PACKET FAILED ON AUTHENTICATION
	0 OUTBOUND PACKET PROCESSED SUCCESSFULLY
	0 OUTBOUND PACKET VIOLATED PROCESS SECURITY POLICY
	0 OUTBOUND PACKET WITH NO SA AVAILABLE
	0 INVALID OUTBOUND PACKET
	0 OUTBOUND PACKET FAILED DUE TO INSUFFICIENT MEMORY
	0 OUTBOUND PACKET WITH NO ROUTE
RIP6:
	0 MESSAGE RECEIVED
	0 CHECKSUM CALCULATION ON INBOUND
	0 MESSAGE WITH BAD CHECKSUM
	0 MESSAGE DROPPED DUE TO NO SOCKET
	0 MULTICAST MESSAGE DROPPED DUE TO NO SOCKET
	0 MESSAGE DROPPED DUE TO FULL SOCKET BUFFERS
	0 DELIVERED
	0 DATAGRAM OUTPUT
PFKEY:
	0 REQUEST SENT TO USERLAND
	0 BYTE SENT TO USERLAND
	0 MESSAGE WITH INVALID LENGTH FIELD
	0 MESSAGE WITH INVALID VERSION FIELD
	0 MESSAGE WITH INVALID MESSAGE TYPE FIELD
	0 MESSAGE TOO SHORT
	0 MESSAGE WITH MEMORY ALLOCATION FAILURE
	0 MESSAGE WITH DUPLICATE EXTENSION
	0 MESSAGE WITH INVALID EXTENSION TYPE
	0 MESSAGE WITH INVALID SA TYPE
	0 MESSAGE WITH INVALID ADDRESS EXTENSION
	0 REQUEST SENT FROM USERLAND
	0 BYTE SENT FROM USERLAND
	0 MESSAGE TOWARD SINGLE SOCKET
	0 MESSAGE TOWARD ALL SOCKETS
	0 MESSAGE TOWARD REGISTERED SOCKETS
	0 MESSAGE WITH MEMORY ALLOCATION FAILURE
KEVT:
	24 CURRENT KERNEL CONTROL SOCKETS
	19074 KERNEL CONTROL GENERATION COUNT
	0 BAD VENDOR FAILURE
	7447 MESSAGE TOO BIG FAILURES
	0 OUT OF MEMORY FAILURE
	0 MESSAGE DROPPED DUE TO FULL SOCKET BUFFERS
	278707 MESSAGES POSTED
KCTL:
	0 TOTAL KERNEL CONTROL MODULE REGISTERED
	12 CURRENT KERNEL CONTROL MODULES REGISTERED
	55 CURRENT KERNEL CONTROL SOCKETS
	1119 KERNEL CONTROL GENERATION COUNT
	581 CONNECTION ATTEMPTS
	0 CONNECTION FAILURE
	35 SEND FAILURES
	0 SEND LIST FAILURE
	0 ENQUEUE FAILURE
	0 PACKET DROPPED DUE TO FULL SOCKET BUFFERS
XBKIDLE:
	1 MAX PER PROCESS
	600 MAXIMUM TIME (SECONDS)
	131072 HIGH WATER MARK
	0 SOCKET OPTION NOT SUPPORTED FAILURE
	0 TOO MANY SOCKETS FAILURE
	0 TOTAL SOCKET REQUESTED OK
	0 EXTENDED BK IDLE SOCKET
	0 NO CELLULAR FAILURE
	0 NO TIME FAILURES
	0 FORCED DEFUNCT SOCKET
	0 RESUMED SOCKET
	0 TIMEOUT EXPIRED FAILURE
	0 TIMER RESCHEDULED
	0 NO DELEGATED FAILURE
NET_API:
	2 INTERFACE FILTERS CURRENTLY ATTACHED
	2 INTERFACE FILTERS ATTACHED SINCE BOOT
	2 INTERFACE FILTERS ATTACHED SINCE BOOT BY OS
	0 IP FILTER CURRENTLY ATTACHED
	0 IP FILTER ATTACHED SINCE BOOT
	0 IP FILTER ATTACHED SINCE BOOT BY OS
	4 SOCKET FILTERS CURRENTLY ATTACHED
	4 SOCKET FILTERS ATTACHED SINCE BOOT
	4 SOCKET FILTERS ATTACHED SINCE BOOT BY OS
	328925 SOCKETS ALLOCATED SINCE BOOT
	75 SOCKETS ALLOCATED IN-KERNEL SINCE BOOT
	75 SOCKETS ALLOCATED IN-KERNEL BY OS
	2493 SOCKETS WITH NECP CLIENT UUID SINCE BOOT
	105006 LOCAL DOMAIN SOCKETS ALLOCATED SINCE BOOT
	1199 ROUTE DOMAIN SOCKETS ALLOCATED SINCE BOOT
	124898 INET DOMAIN SOCKETS ALLOCATED SINCE BOOT
	60788 INET6 DOMAIN SOCKETS ALLOCATED SINCE BOOT
	10130 SYSTEM DOMAIN SOCKETS ALLOCATED SINCE BOOT
	0 MULTIPATH DOMAIN SOCKET ALLOCATED SINCE BOOT
	0 KEY DOMAIN SOCKET ALLOCATED SINCE BOOT
	5 NDRV DOMAIN SOCKETS ALLOCATED SINCE BOOT
	0 OTHER DOMAINS SOCKET ALLOCATED SINCE BOOT
	15625 IPV4 STREAM SOCKETS CREATED SINCE BOOT
	109273 IPV4 DATAGRAM SOCKETS CREATED SINCE BOOT
	10493 IPV4 DATAGRAM SOCKETS CONNECTED
	38717 IPV4 DNS SOCKETS
	102542 IPV4 DATAGRAM SOCKETS WITHOUT DATA
	7671 IPV6 STREAM SOCKETS CREATED SINCE BOOT
	53117 IPV6 DATAGRAM SOCKETS CREATED SINCE BOOT
	35524 IPV6 DATAGRAM SOCKETS CONNECTED
	0 IPV6 DNS SOCKET
	28708 IPV6 DATAGRAM SOCKETS WITHOUT DATA
	1115 SOCKET MULTICAST JOINS SINCE BOOT
	1115 SOCKET MULTICAST JOINS SINCE BOOT BY OS
	0 IPV4 STREAM NEXUS FLOW ADDED SINCE BOOT
	0 IPV4 DATAGRAM NEXUS FLOW ADDED SINCE BOOT
	0 IPV6 STREAM NEXUS FLOW ADDED SINCE BOOT
	0 IPV6 DATAGRAM NEXUS FLOW ADDED SINCE BOOT
	12 INTERFACES CURRENTLY ALLOCATED
	12 INTERFACES ALLOCATED SINCE BOOT
	12 INTERFACES CURRENTLY ALLOCATED BY OS
	12 EXTENDED INTERFACES ALLOCATED SINCE BOOT BY OS
	2 PF ADDRULE OPERATIONS SINCE BOOT
	0 PF ADDRULE OPERATION SINCE BOOT BY OS
	0 VMNET START SINCE BOOT

raymond

/Users/raymond/a.txt



    echo $USER   -->  ['echo', os.environ['USER']]
    echo ~/a.txt 
Learn to communicate with other programs

    ECHO $USER   -->  ['ECHO', OS.ENVIRON['USER']]
    ECHO ~/A.TXT 

('<svg width="91pt" height="116pt"\n viewBox="0.00 0.00 91.09 116.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">\n<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 112)">\n<title>%3</title>\n<polygon fill="#ffffff" stroke="transparent" points="-4,4 -4,-112 87.0852,-112 87.0852,4 -4,4"/>\n<!-- raymond -->\n<g id="node1" class="node">\n<title>raymond</title>\n<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-90" rx="41.5852" ry="18"/>\n<text text-anchor="middle" x="41.5426" y="-85.8" font-family="Times,serif" font-size="14.00" fill="#000000">raymond</text>\n</g>\n<!-- matthew -->\n<g id="node2" class="node">\n<title>matthew</title>\n<ellipse fill="none" stroke="#000000" cx="41.5426" cy="-18" rx="40.6162" ry="18"/>\n<text text-anchor="middle" x="41.5426" y="-13.8" font-family="Times,serif" font-size="14.00" fill="#000000">matthew</text>\n</g>\n<!-- raymond&#45;&gt;matthew -->\n<g id="edge1" class="edge">\n<title>raymond&#45;&gt;matthew</title>\n<path fill="none" stroke="#000000" d="M41.5426,-71.8314C41.5426,-64.131 41.5426,-54.9743 41.5426,-46.4166"/>\n<polygon fill="#000000" stroke="#000000" points="45.0427,-46.4132 41.5426,-36.4133 38.0427,-46.4133 45.0427,-46.4132"/>\n</g>\n</g>\n</svg>\n', '')
>>> s = check_output(['python', 'hello.py'])
>>> s
'Hello World\n'
>>> import hello
Hello World
>>> 
>>> # Graphviz is written in C as standalone application that knows NOTHING about Python.
>>> # There are probably pythongraphviz packages:  they have python functions that call graphviz.exe underneath
>>> 
>>> 
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
>>> from notes2.bottle import template, view
>>> print template('The answer is {{ answer }} today', answer=10)
The answer is 10 today
>>> print template('The answer is {{ answer }} today and its square is {{ answer ** 2 }}', answer=10)
The answer is 10 today and its square is 100
>>> print template('The answer is {{ answer }} today and its square is {{ str(answer ** 2) * 3 }}', answer=10)
The answer is 10 today and its square is 100100100
>>> print template('The villain is {{ v }}', v='Cersei Lannister')
The villain is Cersei Lannister
>>> print template('The villain is {{ v }}', v='Cersei & Jamie Lannister')
The villain is Cersei &amp; Jamie Lannister
>>> print template('The villain is {{! v }}', v='Cersei & Jamie Lannister')
The villain is Cersei & Jamie Lannister
>>> 
>>> # Python statements are on lines where the first non-whitespace character is a %
>>> # Those lines don't print.  They execute.
>>> # To end a block, you need a % end entry.
>>> 
>>> mood_template = '''
I am feeling:
% if hs >= 50:
happy
% else:
sad
% end
today
'''
>>> print template(mood_template, hs=70)

I am feeling:
happy
today

>>> print template(mood_template, hs=40)

I am feeling:
sad
today

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
>>> # Counterpart
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The lannister Family

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
===========

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================

>>> 
>>> 
>>> for name in first_names:
	print name

	
tywin
cersei&jamie
tyrion
jeoffrey
tommin
mycella
>>> for i, name in enumerate(first_names):
	print i, name

	
0 tywin
1 cersei&jamie
2 tyrion
3 jeoffrey
4 tommin
5 mycella
>>> for i, name in enumerate(first_names, start=1):
	print i, name

	
1 tywin
2 cersei&jamie
3 tyrion
4 jeoffrey
5 tommin
6 mycella
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
name
name
name
name
name
name

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
tywin
cersei&amp;jamie
tyrion
jeoffrey
tommin
mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
tywin
cersei&jamie
tyrion
jeoffrey
tommin
mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
Tywin
Cersei&jamie
Tyrion
Jeoffrey
Tommin
Mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
Tywin
Cersei&Jamie
Tyrion
Jeoffrey
Tommin
Mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
i. Tywin
i. Cersei&Jamie
i. Tyrion
i. Jeoffrey
i. Tommin
i. Mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
1. Tywin
2. Cersei&Jamie
3. Tyrion
4. Jeoffrey
5. Tommin
6. Mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
1. Tywin
    ^-- Very important person
2. Cersei&Jamie
3. Tyrion
4. Jeoffrey
5. Tommin
6. Mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Lannister Family
====================
1. Tywin
    ^-- Very important person
2. Cersei&Jamie
3. Tyrion
4. Jeoffrey
5. Tommin
6. Mycella

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======

====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======

====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title> Lannister Family </title>
</head>
<body>
</body>
</html>

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title> Lannister Family </title>
</head>
<body>
<h1> The <em> Lannister </em> Family </h1>
</body>
</html>

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title> Lannister Family </title>
</head>
<body>
<h1> The <em> Lannister </em> Family </h1>
<hr>
<ol>
  <li> Tywin </li>
  <li> Cersei&amp;Jamie </li>
  <li> Tyrion </li>
  <li> Jeoffrey </li>
  <li> Tommin </li>
  <li> Mycella </li>
</ol>
</body>
</html>

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title> Lannister Family </title>
</head>
<body>
<h1> The <em> Lannister </em> Family </h1>
<hr>
<ol>
  <li> Tywin </li>
  <li> Cersei&amp;Jamie </li>
  <li> Tyrion </li>
  <li> Jeoffrey </li>
  <li> Tommin </li>
  <li> Mycella </li>
</ol>
</body>
</html>

stark eddard catelyn robb jonsnow sansa arya bran rickon
targaryen aegon danyeres ameon vasayres
simpsons homer marge bart lisa maggie
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
stark eddard catelyn robb jonsnow sansa arya bran rickon
targaryen aegon danyeres ameon vasayres
simpsons homer marge bart lisa maggie
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
['stark', 'eddard', 'catelyn', 'robb', 'jonsnow', 'sansa', 'arya', 'bran', 'rickon']
['targaryen', 'aegon', 'danyeres', 'ameon', 'vasayres']
['simpsons', 'homer', 'marge', 'bart', 'lisa', 'maggie']
>>> fields[0]
'simpsons'
>>> fields[1:]
['homer', 'marge', 'bart', 'lisa', 'maggie']
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Stark Family
================
1. Eddard
    ^-- Very important person
2. Catelyn
3. Robb
4. Jonsnow
5. Sansa
6. Arya
7. Bran
8. Rickon

The Targaryen Family
====================
1. Aegon
    ^-- Very important person
2. Danyeres
3. Ameon
4. Vasayres

The Simpsons Family
===================
1. Homer
    ^-- Very important person
2. Marge
3. Bart
4. Lisa
5. Maggie

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Stark Family
================
1. Eddard
    ^-- Very important person
2. Catelyn
3. Robb
4. Jonsnow
5. Sansa
6. Arya
7. Bran
8. Rickon

The Targaryen Family
====================
1. Aegon
    ^-- Very important person
2. Danyeres
3. Ameon
4. Vasayres

The Simpsons Family
===================
1. Homer
    ^-- Very important person
2. Marge
3. Bart
4. Lisa
5. Maggie

>>> line
'simpsons homer marge bart lisa maggie'
>>> get_family
<function get_family at 0x10382bcf8>
>>> get_family(line)

Traceback (most recent call last):
  File "<pyshell#61>", line 1, in <module>
    get_family(line)
  File "/Users/raymond/Dropbox/Public/sj178/templating_demo.py", line 61, in get_family
    return dict(family_plain_text, lastname=fields[0], first_names=fields[1:])
ValueError: dictionary update sequence element #0 has length 1; 2 is required
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Stark Family
================
1. Eddard
    ^-- Very important person
2. Catelyn
3. Robb
4. Jonsnow
5. Sansa
6. Arya
7. Bran
8. Rickon

The Targaryen Family
====================
1. Aegon
    ^-- Very important person
2. Danyeres
3. Ameon
4. Vasayres

The Simpsons Family
===================
1. Homer
    ^-- Very important person
2. Marge
3. Bart
4. Lisa
5. Maggie

>>> get_family(line)
{'first_names': ['homer', 'marge', 'bart', 'lisa', 'maggie'], 'lastname': 'simpsons'}
>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Stark Family
================
1. Eddard
    ^-- Very important person
2. Catelyn
3. Robb
4. Jonsnow
5. Sansa
6. Arya
7. Bran
8. Rickon

The Targaryen Family
====================
1. Aegon
    ^-- Very important person
2. Danyeres
3. Ameon
4. Vasayres

The Simpsons Family
===================
1. Homer
    ^-- Very important person
2. Marge
3. Bart
4. Lisa
5. Maggie

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Stark Family
================
1. Eddard
    ^-- Very important person
2. Catelyn
3. Robb
4. Jonsnow
5. Sansa
6. Arya
7. Bran
8. Rickon

The Targaryen Family
====================
1. Aegon
    ^-- Very important person
2. Danyeres
3. Ameon
4. Vasayres

The Simpsons Family
===================
1. Homer
    ^-- Very important person
2. Marge
3. Bart
4. Lisa
5. Maggie

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Stark Family
================
1. Eddard
    ^-- Very important person
2. Catelyn
3. Robb
4. Jonsnow
5. Sansa
6. Arya
7. Bran
8. Rickon

The Targaryen Family
====================
1. Aegon
    ^-- Very important person
2. Danyeres
3. Ameon
4. Vasayres

The Simpsons Family
===================
1. Homer
    ^-- Very important person
2. Marge
3. Bart
4. Lisa
5. Maggie

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title> Stark Family </title>
</head>
<body>
<h1> The <em> Stark </em> Family </h1>
<hr>
<ol>
  <li> Eddard </li>
  <li> Catelyn </li>
  <li> Robb </li>
  <li> Jonsnow </li>
  <li> Sansa </li>
  <li> Arya </li>
  <li> Bran </li>
  <li> Rickon </li>
</ol>
</body>
</html>

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title> Targaryen Family </title>
</head>
<body>
<h1> The <em> Targaryen </em> Family </h1>
<hr>
<ol>
  <li> Aegon </li>
  <li> Danyeres </li>
  <li> Ameon </li>
  <li> Vasayres </li>
</ol>
</body>
</html>

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title> Simpsons Family </title>
</head>
<body>
<h1> The <em> Simpsons </em> Family </h1>
<hr>
<ol>
  <li> Homer </li>
  <li> Marge </li>
  <li> Bart </li>
  <li> Lisa </li>
  <li> Maggie </li>
</ol>
</body>
</html>

>>> 
====== RESTART: /Users/raymond/Dropbox/Public/sj178/templating_demo.py ======
The Stark Family
================
1. Eddard
    ^-- Very important person
2. Catelyn
3. Robb
4. Jonsnow
5. Sansa
6. Arya
7. Bran
8. Rickon

The Targaryen Family
====================
1. Aegon
    ^-- Very important person
2. Danyeres
3. Ameon
4. Vasayres

The Simpsons Family
===================
1. Homer
    ^-- Very important person
2. Marge
3. Bart
4. Lisa
5. Maggie

>>> import sqlite3
>>> conn = sqlite3.connect('example.db')
>>> c = conn.cursor()
>>> c.execute('CREATE TABLE Stocks (date text, trans text, symbol text, qty real, price real)')
<sqlite3.Cursor object at 0x104c32dc0>
>>> c.execute("INSERT INTO Stocks VALUES ('2006-01-05', 'BUY', 'RHAT', 100, 35.14);")
<sqlite3.Cursor object at 0x104c32dc0>
>>> conn.commit()
>>> conn.close()
>>> import sqlite3
>>> conn = sqlite3.connect('example.db')
>>> c = conn.cursor()
>>> symbol = 'RHAT'
>>> c.execute('SELECT * FROM Stocks WHERE symbol=?' % symbol)

Traceback (most recent call last):
  File "<pyshell#74>", line 1, in <module>
    c.execute('SELECT * FROM Stocks WHERE symbol=?' % symbol)
TypeError: not all arguments converted during string formatting
>>> c.execute('SELECT * FROM Stocks WHERE symbol=%s' % symbol)

Traceback (most recent call last):
  File "<pyshell#75>", line 1, in <module>
    c.execute('SELECT * FROM Stocks WHERE symbol=%s' % symbol)
OperationalError: no such column: RHAT
>>> c.execute('SELECT * FROM Stocks WHERE symbol="%s"' % symbol)
<sqlite3.Cursor object at 0x104c32e30>
>>> c.fetchone()
(u'2006-01-05', u'BUY', u'RHAT', 100.0, 35.14)
>>> purchases = [('2006-03-28', 'BUY', 'IBM', 1000, 45.00),
             ('2006-04-05', 'BUY', 'MSFT', 1000, 72.00),
             ('2006-04-06', 'SELL', 'IBM', 500, 53.00),
            ]
>>> c.executemany('INSERT INTO Stocks VALUES (?,?,?,?,?)', purchases)
<sqlite3.Cursor object at 0x104c32e30>
>>> for row in c.execute('SELECT * FROM Stocks;'):
	print row

	
(u'2006-01-05', u'BUY', u'RHAT', 100.0, 35.14)
(u'2006-03-28', u'BUY', u'IBM', 1000.0, 45.0)
(u'2006-04-05', u'BUY', u'MSFT', 1000.0, 72.0)
(u'2006-04-06', u'SELL', u'IBM', 500.0, 53.0)
>>> for row in c.execute('SELECT * FROM Stocks ORDER BY price;'):
	print row

	
(u'2006-01-05', u'BUY', u'RHAT', 100.0, 35.14)
(u'2006-03-28', u'BUY', u'IBM', 1000.0, 45.0)
(u'2006-04-06', u'SELL', u'IBM', 500.0, 53.0)
(u'2006-04-05', u'BUY', u'MSFT', 1000.0, 72.0)
>>> 
========== RESTART: /Users/raymond/Dropbox/Public/sj178/sql_demo.py ==========
>>> 
========== RESTART: /Users/raymond/Dropbox/Public/sj178/sql_demo.py ==========
>>> 
========== RESTART: /Users/raymond/Dropbox/Public/sj178/sql_demo.py ==========
(4219, u'Advanced Git')
(5103, u'SDN and ACI')
>>> 
========== RESTART: /Users/raymond/Dropbox/Public/sj178/sql_demo.py ==========
(5103, u'SDN and ACI')
(4219, u'Advanced Git')
>>> 
========== RESTART: /Users/raymond/Dropbox/Public/sj178/sql_demo.py ==========
(5103, u'SDN and ACI')
(4219, u'Advanced Git')
(u'Python III',)
>>> 
>>> 
>>> # Build an Amazon or BH Photo Video
>>> import antigravity
>>> import webbrowser
>>> webbrowser.open('file:///Users/raymond/sj/lannisters.html')
True
>>> 
