1 2017-03-14T00:00:03  *** PRab has joined #bitcoin-dev
  2 2017-03-14T00:00:45  *** chjj has joined #bitcoin-dev
  3 2017-03-14T00:04:03  *** musalbas has quit IRC
  4 2017-03-14T00:24:31  *** porquilho has quit IRC
  5 2017-03-14T00:30:25  *** musalbas has joined #bitcoin-dev
  6 2017-03-14T00:46:01  *** moa has joined #bitcoin-dev
  7 2017-03-14T00:54:35  *** Beef has quit IRC
  8 2017-03-14T00:56:48  *** Beef has joined #bitcoin-dev
  9 2017-03-14T01:04:22  *** blueness has quit IRC
 10 2017-03-14T01:13:01  *** jpe has quit IRC
 11 2017-03-14T01:20:03  *** blueness has joined #bitcoin-dev
 12 2017-03-14T01:21:20  *** blueness has quit IRC
 13 2017-03-14T01:21:52  *** blueness has joined #bitcoin-dev
 14 2017-03-14T01:32:25  *** Pasha has joined #bitcoin-dev
 15 2017-03-14T01:32:48  *** Cory has quit IRC
 16 2017-03-14T01:38:14  *** CheckDavid has joined #bitcoin-dev
 17 2017-03-14T01:40:37  *** Pasha is now known as Cory
 18 2017-03-14T02:24:44  <Iriez> achow101: could you explain the 75 contributor gap outlined by the poster in that thread?
 19 2017-03-14T02:25:26  <Iriez> Im interested in determining how many contributors to the codebase there was.
 20 2017-03-14T02:33:32  *** HostFat__ has joined #bitcoin-dev
 21 2017-03-14T02:34:51  <achow101> Iriez: what is that thread even discussing? What repo?
 22 2017-03-14T02:35:23  <achow101> oh, nvm, didn't scroll down far enough
 23 2017-03-14T02:36:53  <achow101> Iriez: for one thing, you can't compare the branches like that because the branches have changed since the respective .0 releases you are talking about. Also, IIRC the changelog is based on the differences between the latest minor version, and the major release
 24 2017-03-14T02:37:04  *** HostFat_ has quit IRC
 25 2017-03-14T02:39:05  <achow101> secondly the github compare does not show all commits, only the first 250, out of hundreds, possibly more than a thousand commits made between releases. It is not going to show every commit. You will need to use the git commands for that
 26 2017-03-14T02:39:57  *** spinza has quit IRC
 27 2017-03-14T03:27:13  *** spinza has joined #bitcoin-dev
 28 2017-03-14T03:46:31  *** Subo1977_ has joined #bitcoin-dev
 29 2017-03-14T03:50:35  *** Subo1977 has quit IRC
 30 2017-03-14T04:06:27  *** iv3c has quit IRC
 31 2017-03-14T04:52:45  *** ThomasV has joined #bitcoin-dev
 32 2017-03-14T04:54:19  *** Xanather has joined #bitcoin-dev
 33 2017-03-14T04:56:15  *** Xanather_ has joined #bitcoin-dev
 34 2017-03-14T04:57:33  *** Xanather has quit IRC
 35 2017-03-14T04:57:59  *** Xanather has joined #bitcoin-dev
 36 2017-03-14T04:58:58  *** Xanather_ has quit IRC
 37 2017-03-14T05:07:55  *** janko33 has joined #bitcoin-dev
 38 2017-03-14T05:15:56  *** windsok has joined #bitcoin-dev
 39 2017-03-14T05:44:43  *** [7] has quit IRC
 40 2017-03-14T05:44:52  *** TheSeven has joined #bitcoin-dev
 41 2017-03-14T06:04:08  *** copumpkin has quit IRC
 42 2017-03-14T06:05:46  *** jtimon has quit IRC
 43 2017-03-14T06:10:47  *** janko33 has quit IRC
 44 2017-03-14T06:17:25  *** copumpkin has joined #bitcoin-dev
 45 2017-03-14T06:30:08  *** cesurasean has joined #bitcoin-dev
 46 2017-03-14T06:34:47  <wumpus> the commit I use to create the committers list is
 47 2017-03-14T06:35:11  *** fnb_theory has joined #bitcoin-dev
 48 2017-03-14T06:35:19  <wumpus> LC_ALL=C git log --use-mailmap --format='%aN' "$*" | sort -uif | sed -e 's/^/- /'
 49 2017-03-14T06:35:39  <wumpus> Example: list_authors.sh v0.9.0rc2..0.9.0
 50 2017-03-14T06:37:02  <wumpus> also sometimes we manually add names if people have done important things for a release but haven't directly committed.  it's usually better to over-credit than under-credit
 51 2017-03-14T06:37:18  <wumpus> but this is only 0-2 names per release, not a whole bunch
 52 2017-03-14T06:54:15  *** ThomasV has quit IRC
 53 2017-03-14T07:24:30  *** ongolaBoy has joined #bitcoin-dev
 54 2017-03-14T07:28:24  *** Fr4n has quit IRC
 55 2017-03-14T07:29:10  *** Fr4n has joined #bitcoin-dev
 56 2017-03-14T07:45:00  *** BashCo has quit IRC
 57 2017-03-14T07:51:43  *** Fr4n has quit IRC
 58 2017-03-14T07:57:17  *** ThomasV has joined #bitcoin-dev
 59 2017-03-14T08:01:40  *** MoALTz has joined #bitcoin-dev
 60 2017-03-14T08:04:59  *** Fr4n has joined #bitcoin-dev
 61 2017-03-14T08:18:25  *** BashCo has joined #bitcoin-dev
 62 2017-03-14T08:24:53  *** Xanather has quit IRC
 63 2017-03-14T08:59:27  *** nazarewk has joined #bitcoin-dev
 64 2017-03-14T09:05:35  *** wasi has joined #bitcoin-dev
 65 2017-03-14T09:17:23  *** paveljanik has quit IRC
 66 2017-03-14T09:24:27  *** Burrito has quit IRC
 67 2017-03-14T09:24:46  *** Burrito has joined #bitcoin-dev
 68 2017-03-14T09:34:41  *** Guyver2 has joined #bitcoin-dev
 69 2017-03-14T09:36:48  *** belcher has quit IRC
 70 2017-03-14T09:49:45  *** belcher has joined #bitcoin-dev
 71 2017-03-14T09:55:25  *** weedcoder has joined #bitcoin-dev
 72 2017-03-14T10:18:46  *** airbreather has quit IRC
 73 2017-03-14T10:31:56  *** airbreather has joined #bitcoin-dev
 74 2017-03-14T10:45:37  *** windsok has quit IRC
 75 2017-03-14T10:57:44  *** airbreather has quit IRC
 76 2017-03-14T10:59:26  *** airbreather has joined #bitcoin-dev
 77 2017-03-14T11:12:08  *** chjj has quit IRC
 78 2017-03-14T11:26:09  *** chjj has joined #bitcoin-dev
 79 2017-03-14T11:28:04  *** moa has quit IRC
 80 2017-03-14T11:36:40  *** ThomasV has quit IRC
 81 2017-03-14T12:02:08  *** ThomasV has joined #bitcoin-dev
 82 2017-03-14T12:26:05  <GAit> wumpus: on https://bitcoin.org/en/release/v0.14.0#minimum-fee-rate-policies it says "(effectively 3 * 1000 satoshis/kB)" - in the code https://github.com/bitcoin/bitcoin/commit/dd98f04 I see the constant but I'm missing the 3 x, is this an error in the release notes I suppose? the threshold is 1/3 of the spending fee so maybe brought confusion?
 83 2017-03-14T12:26:59  *** Newyorkadam has joined #bitcoin-dev
 84 2017-03-14T12:29:01  <GAit> jonasschnelli: yes we support opt-in rbf since mid May of last year
 85 2017-03-14T12:32:17  <wumpus> GAit: I'm not sure,  from the source you'd indeed say it'd be 1000 not 3*1000
 86 2017-03-14T12:32:44  <wumpus> morcos: any idea?
 87 2017-03-14T12:51:21  *** iv3c has joined #bitcoin-dev
 88 2017-03-14T12:55:28  *** Newyorkadam has quit IRC
 89 2017-03-14T12:59:16  *** ongolaBoy has quit IRC
 90 2017-03-14T13:00:36  *** agricocb has quit IRC
 91 2017-03-14T13:06:06  *** ongolaBoy has joined #bitcoin-dev
 92 2017-03-14T13:11:24  *** ongolaBoy has quit IRC
 93 2017-03-14T13:13:21  *** ongolaBoy has joined #bitcoin-dev
 94 2017-03-14T13:19:13  *** To7 has quit IRC
 95 2017-03-14T13:58:36  *** agricocb has joined #bitcoin-dev
 96 2017-03-14T14:03:13  *** cybrNaut has quit IRC
 97 2017-03-14T14:08:57  *** ThomasV has quit IRC
 98 2017-03-14T14:12:52  *** ongolaBoy has quit IRC
 99 2017-03-14T14:13:49  *** Tristan-Speccy has joined #bitcoin-dev
100 2017-03-14T14:14:54  *** ongolaBoy has joined #bitcoin-dev
101 2017-03-14T14:36:48  <morcos> GAit: wumpus: Sorry i wasn't sure how to make that text clear...   the dust calculation has always included a multiple of 3 in it.
102 2017-03-14T14:37:10  <morcos> I was just trying to indicate how to translate from the option you are passing to what is considered a dust amount
103 2017-03-14T14:39:28  *** schmidty has quit IRC
104 2017-03-14T14:40:08  <morcos> whoops that didn't render well.. i wonder if somehow that text got changed.. but yeah the rate you pass in in is the rate such that at a feerate on a future transaction of (3 * that) it would be a wash to include as input any output created at the threshold
105 2017-03-14T14:41:49  <wumpus> thanks, that makes it clearer, so the factor 3 is implicit
106 2017-03-14T14:42:03  <morcos> yes...
107 2017-03-14T14:42:20  <morcos> nothing has changed..
108 2017-03-14T14:42:48  <morcos> interpreted the exact same way it was with the minrelaytxfee option before.. but now that option only controls dust threshold so i wanted to explain it..
109 2017-03-14T15:02:48  *** agricocb has quit IRC
110 2017-03-14T15:02:50  *** kryptynasium has joined #bitcoin-dev
111 2017-03-14T15:02:55  *** weedcoder has quit IRC
112 2017-03-14T15:04:11  <kryptynasium> How big is the blockchain dump and how many days would it take to download all the way to the genesis block?
113 2017-03-14T15:05:30  <kryptynasium> Forums are saying: The blockchain currently weighs in at about 45 GB  - is it still around this number?
114 2017-03-14T15:05:44  *** To7 has joined #bitcoin-dev
115 2017-03-14T15:07:09  <kryptynasium> Bitcoin is doomed
116 2017-03-14T15:08:25  *** afk11_ has joined #bitcoin-dev
117 2017-03-14T15:12:12  <wumpus> about 100GB, if you have a fast computer and network connection you can download and validate it in a few hours
118 2017-03-14T15:12:39  <wumpus> as for the nihilism take it somewhere else we don't react well to that here
119 2017-03-14T15:18:52  *** nazarewk has quit IRC
120 2017-03-14T15:19:18  *** rublev has joined #bitcoin-dev
121 2017-03-14T15:20:54  *** nazarewk has joined #bitcoin-dev
122 2017-03-14T15:23:52  <kryptynasium> wumpus: would you be able to estimate the total number of transactions?
123 2017-03-14T15:24:35  <wumpus> I don't have those statistics, but I'm sure you can find that somewhere
124 2017-03-14T15:28:53  *** weedcoder has joined #bitcoin-dev
125 2017-03-14T15:32:29  *** ongolaBoy has quit IRC
126 2017-03-14T15:42:03  *** rublev has quit IRC
127 2017-03-14T15:42:14  *** rublev has joined #bitcoin-dev
128 2017-03-14T15:43:21  <kryptynasium> wumpus: ~220 million: https://blockchain.info/charts/n-transactions-total?timespan=all  FYI
129 2017-03-14T15:43:58  *** rublev has quit IRC
130 2017-03-14T15:44:06  *** rublev has joined #bitcoin-dev
131 2017-03-14T15:44:28  *** ThomasV has joined #bitcoin-dev
132 2017-03-14T15:44:57  *** rublev has joined #bitcoin-dev
133 2017-03-14T15:45:05  <rublev> tes
134 2017-03-14T15:49:20  *** rublev has quit IRC
135 2017-03-14T15:49:27  *** rublev has joined #bitcoin-dev
136 2017-03-14T15:49:56  *** rublev has left #bitcoin-dev
137 2017-03-14T15:51:36  *** agricocb has joined #bitcoin-dev
138 2017-03-14T15:56:50  *** abpa has joined #bitcoin-dev
139 2017-03-14T16:00:00  *** molz_ is now known as moli
140 2017-03-14T16:09:20  *** kryptynasium has left #bitcoin-dev
141 2017-03-14T16:15:19  *** abpa has quit IRC
142 2017-03-14T16:16:23  *** abpa has joined #bitcoin-dev
143 2017-03-14T16:23:32  *** Arthur33 has joined #bitcoin-dev
144 2017-03-14T16:25:14  <Arthur33> Hi everyone. Can somebody help me with something. I have modified net.cpp code in bitcoin core and I'd like to link to new static librairies to make it work. However I cannot where I need to modify the makefile to make it works.
145 2017-03-14T16:27:23  *** jtimon has joined #bitcoin-dev
146 2017-03-14T16:30:33  *** paveljanik has joined #bitcoin-dev
147 2017-03-14T16:35:24  *** Fr4n has quit IRC
148 2017-03-14T16:46:20  *** Arthur33 has quit IRC
149 2017-03-14T16:47:49  *** Fr4n has joined #bitcoin-dev
150 2017-03-14T17:00:37  <cluelessperson> I'm working on parsing the blockchain  when I view a CTxIn, I can't seem to manually spot the input amount, what am I missing here?
151 2017-03-14T17:00:40  <cluelessperson> CTxIn(COutPoint(lx('fe2a3e06c80d43797403b4ffa4d070347b41cf5bf7094c41b417308dcb7a2db2'), 1), CScript([x('3044022056f3471291c76281edd02554d893c5bdd3a3c9ec5a3af9e685714d843c2ef81e02207e74d7a583472833053def680475d50b112b4d6ca375e6fdc64ca9f8718ae6cf01'), x('03eef298060801ef649c84a0b616179ca4da87653e5e75e41137fe7f235f1563da')]), 0xffffffff)
152 2017-03-14T17:01:09  <abpa> cluelessperson inputs don't contain the values
153 2017-03-14T17:01:18  <abpa> Kind of a design oversight in my opinion
154 2017-03-14T17:01:18  <cluelessperson> abpa: oh, what does?
155 2017-03-14T17:01:33  <abpa> You have to cross reference it with the outpoint utxo
156 2017-03-14T17:01:37  <cluelessperson> abpa: probably trying to get size down as much as possible.
157 2017-03-14T17:01:50  <cluelessperson> abpa: thanks
158 2017-03-14T17:03:51  *** crudel has joined #bitcoin-dev
159 2017-03-14T17:08:30  *** nazarewk has quit IRC
160 2017-03-14T17:22:32  *** BashCo has quit IRC
161 2017-03-14T17:23:10  *** BashCo has joined #bitcoin-dev
162 2017-03-14T17:27:37  *** BashCo has quit IRC
163 2017-03-14T17:33:02  *** agricocb has quit IRC
164 2017-03-14T17:33:16  *** agricocb has joined #bitcoin-dev
165 2017-03-14T17:33:42  *** ThomasV has quit IRC
166 2017-03-14T17:35:28  *** weedcoder has quit IRC
167 2017-03-14T17:36:55  *** Newyorkadam has joined #bitcoin-dev
168 2017-03-14T17:39:55  <GAit> thanks wumpus morcos
169 2017-03-14T17:42:31  *** janko33 has joined #bitcoin-dev
170 2017-03-14T17:46:32  *** Sosumi has joined #bitcoin-dev
171 2017-03-14T17:51:07  *** rublev has joined #bitcoin-dev
172 2017-03-14T17:51:52  <rublev> quit
173 2017-03-14T17:51:54  *** rublev has quit IRC
174 2017-03-14T17:57:00  *** Fr4n has quit IRC
175 2017-03-14T17:57:47  *** BashCo has joined #bitcoin-dev
176 2017-03-14T18:02:29  <cluelessperson> abpa: what exactly is the utxo?
177 2017-03-14T18:02:41  <abpa>  just outputs that are not yet spent
178 2017-03-14T18:02:49  <abpa> a combination of transaction id and output index
179 2017-03-14T18:03:03  <cluelessperson> abpa: so you're saying, I have to reference previous blocks/transaction outputs to determine the input of this block?
180 2017-03-14T18:03:15  <abpa> To determine the input value, that's correct
181 2017-03-14T18:03:26  <abpa> The input value is the output value it references
182 2017-03-14T18:04:16  <cluelessperson> abpa: so I'm thinking I have to query the input referenced utxo from bitcoin rpc?
183 2017-03-14T18:04:19  *** CheckDavid has quit IRC
184 2017-03-14T18:05:43  <abpa> cluelessperson yes and you'll need tx index
185 2017-03-14T18:06:21  <cluelessperson> abpa: my node has txindex=1  so I think I'm good
186 2017-03-14T18:07:49  *** ThomasV has joined #bitcoin-dev
187 2017-03-14T18:09:58  *** Fr4n has joined #bitcoin-dev
188 2017-03-14T18:18:47  <cluelessperson> I'm a bit confused, how do you refere to the unspent of a previous transaction?
189 2017-03-14T18:18:53  <cluelessperson> you're not always sending the full amount.
190 2017-03-14T18:19:03  <abpa> cluelessperson you are always sending the full amount
191 2017-03-14T18:19:15  <cluelessperson> abpa: wut?
192 2017-03-14T18:19:24  <abpa> You can only fully spend an output
193 2017-03-14T18:19:54  <cluelessperson> abpa: I don't understand, how does that allow from splitting 1BTC to 0.5 BTC?
194 2017-03-14T18:20:25  <abpa> cluelessperson you can't, you must create a new change output
195 2017-03-14T18:21:02  <cluelessperson> abpa: What?
196 2017-03-14T18:21:15  <cluelessperson> I remember being able to leave a balance at an address?
197 2017-03-14T18:21:25  <cluelessperson> you're saying now that you must send the entire amount always?
198 2017-03-14T18:21:35  <abpa> You can only fully spend an output in a transaction, if you want to send a partial amount you send part to the partial destination and part back to yourself to an output you control
199 2017-03-14T18:21:52  <abpa> addresses don't really have balances
200 2017-03-14T18:22:06  <abpa> That's just a way to visualize multiple outputs that happen to be similar
201 2017-03-14T18:22:25  <abpa> cluelessperson you must send the entire output value always
202 2017-03-14T18:23:01  <cluelessperson> abpa: so, a transaction where someone left value attached to their own address, was actually a transaction where they had two outputs, to their destination, and the remaining to themselves, anything unaccountd for is a fee?
203 2017-03-14T18:25:57  <abpa> cluelessperson if you see a "balance at an address" it is just referencing that they re-used an address
204 2017-03-14T18:26:10  <abpa> Which is a no-no
205 2017-03-14T18:27:18  <cluelessperson> I understand, however it's only recently that bitcoin core even allowed a deterministic wallet for change addresses and similar.
206 2017-03-14T18:27:37  <abpa> Bitcoin Core before that just made new addresses for change
207 2017-03-14T18:27:43  <cluelessperson> ah
208 2017-03-14T18:28:12  <cluelessperson> abpa: also, when you reference a previous transaction, you're only paying attention to the amount that was sent to your current address?
209 2017-03-14T18:28:37  <abpa> The address just encodes what an output would look like
210 2017-03-14T18:29:06  <abpa> When you reference a previous transaction you are talking about the transaction that has an output at a certain index
211 2017-03-14T18:29:35  <cluelessperson> abpa: I'm confused, addresses are derived from private/public key pairs, no?
212 2017-03-14T18:30:08  <cluelessperson> I thought addresses were just used as "id"s to attach values to, then the controlling party can sign ownership to another address
213 2017-03-14T18:30:26  <cluelessperson> brb, sorry
214 2017-03-14T18:30:26  *** Newyorkadam has quit IRC
215 2017-03-14T18:34:33  <abpa> addresses are just encodings of common output scripts that include hashes of key pairs
216 2017-03-14T18:35:08  *** Fr4n has quit IRC
217 2017-03-14T18:38:11  <cluelessperson> abpa: they can't be, I've generated addresses
218 2017-03-14T18:38:35  <cluelessperson> private -> public -> address
219 2017-03-14T18:38:39  <abpa> What it does it generate a new key, then encodes the key as a part of an output script, then encode that as an address basically
220 2017-03-14T18:39:12  <abpa> It's more like private -> public -> pkhash as part of an output script -> address that encodes the output script into a minimal sharing format
221 2017-03-14T18:39:46  <cluelessperson> ...
222 2017-03-14T18:42:00  <cluelessperson> abpa: You're making it sound like the transaction itself is what generates an address
223 2017-03-14T18:42:03  <cluelessperson> and it simply does not
224 2017-03-14T18:42:39  <abpa> Transactions have output scripts that describe unlocking conditions
225 2017-03-14T18:42:49  <abpa> Addresses are short ways to describe these output scripts
226 2017-03-14T18:43:14  <cluelessperson> What do you mean "short way to describe these output script"
227 2017-03-14T18:43:26  <cluelessperson> I can generate an address right now, without and output script related to it
228 2017-03-14T18:43:45  <cluelessperson> you mean an output script can be setup to deliver to an address under certain unlocking condition?
229 2017-03-14T18:43:48  <cluelessperson> like nlock
230 2017-03-14T18:44:07  <cluelessperson> abpa: sorry, I don't mean to be difficult, just don't understand.
231 2017-03-14T18:44:38  <abpa> Well so a 1** address basically says it is an output script on main network, of script type pay to public key hash, using the hash $hash
232 2017-03-14T18:44:49  <abpa> So then you make a transaction with that script type with that $hash value
233 2017-03-14T18:45:27  <abpa> Then when the person goes to claim the money they present the public key that goes along with that public key hash and the signature as well to signal that they control the private key that goes along with the public key
234 2017-03-14T18:45:57  *** xnyhps_ is now known as xnyhps
235 2017-03-14T18:46:28  <cluelessperson> how is it an "output script on main network" ?
236 2017-03-14T18:46:35  <cluelessperson> addresses are generated outside of the network
237 2017-03-14T18:46:48  <Chris_Stewart_5> cluelessperson: if it starts with a '1' it has the main network byte prepended to it
238 2017-03-14T18:46:53  <abpa> Right but it describes which network it should be used on
239 2017-03-14T18:47:09  <abpa> That just communicates your preference for where to receive the money
240 2017-03-14T18:47:14  <cluelessperson> what do you mean which network?  mainnet?
241 2017-03-14T18:47:19  <abpa> Testnet vs mainnet yes
242 2017-03-14T18:47:36  <abpa> It's actually just part of the script type byte
243 2017-03-14T18:47:44  <cluelessperson> this isn't making any sense
244 2017-03-14T18:47:55  <abpa> Maybe you need to read about the fundamentals a bit more
245 2017-03-14T18:48:03  <abpa> Like look what data the address is actually encoding
246 2017-03-14T18:48:25  <abpa> Look at what output scripts actually look like
247 2017-03-14T18:48:25  <cluelessperson> Why would you use an address byte to determine if any value is on the network,  If you're using that address on this network, it either has value attached it or it doesn't.
248 2017-03-14T18:48:27  *** Fr4n has joined #bitcoin-dev
249 2017-03-14T18:48:46  <abpa> It's not related to value, just which network you want to be talking about
250 2017-03-14T18:48:52  <Chris_Stewart_5> ^
251 2017-03-14T18:49:07  <Chris_Stewart_5> I can use the same private key -> public key -> pubkey hash on any network
252 2017-03-14T18:49:12  <cluelessperson> abpa:   an address is just a simple    prefix + X + checksum
253 2017-03-14T18:49:28  <abpa> the prefix is the network you are talking about + the script type you are talking about
254 2017-03-14T18:49:36  <abpa> X is the hash argument to the script type
255 2017-03-14T18:50:16  <cluelessperson> abpa: X is a public key...
256 2017-03-14T18:50:29  <abpa> Generally it's a hash, in 1xx it is a hash of a public key
257 2017-03-14T18:51:00  <Chris_Stewart_5> cluelessperson: https://github.com/bitcoin/bitcoin/blob/master/src/chainparams.cpp#L130-L133 is where the prefixes are defined
258 2017-03-14T18:51:14  <Chris_Stewart_5> cluelessperson: and X is a public key hash (if you are using P2PKH)
259 2017-03-14T19:00:46  <cluelessperson> abpa: yeah, but you're saying an address is an output script, I don't understand that
260 2017-03-14T19:01:13  <cluelessperson> an output script might contain an address I believe, along with rules for unlocking..
261 2017-03-14T19:03:36  <Chris_Stewart_5> ^, at best an address is the hash of a script
262 2017-03-14T19:04:09  <Chris_Stewart_5> + network byte and checksum
263 2017-03-14T19:04:21  *** Newyorkadam has joined #bitcoin-dev
264 2017-03-14T19:06:15  <cluelessperson> Chris_Stewart_5: what do you mean "script"
265 2017-03-14T19:06:25  <cluelessperson> addresses are generated completely offline
266 2017-03-14T19:06:29  <cluelessperson> scripts are used on the blockchain
267 2017-03-14T19:06:41  <cluelessperson> that's mutually exclusive.
268 2017-03-14T19:07:34  <Chris_Stewart_5> pay to script hash literally means you are paying to the 'hash of a script'
269 2017-03-14T19:08:07  <Chris_Stewart_5> so you can generate that script offline, then send the *hash* of that script to an online machine, turn it into an address then sending it to your counterparty
270 2017-03-14T19:08:36  <cluelessperson> Chris_Stewart_5: that describes a contract?
271 2017-03-14T19:08:37  <Chris_Stewart_5> that is how multisig works, you are paying to the hash of a multsig script
272 2017-03-14T19:08:55  <Chris_Stewart_5> I think you can use the word 'contract' and 'script' interchangably
273 2017-03-14T19:09:35  *** Fr4n has quit IRC
274 2017-03-14T19:11:14  *** Fr4n has joined #bitcoin-dev
275 2017-03-14T19:12:21  <cluelessperson> Chris_Stewart_5: oh, so in that case, you create a script/contract offline,  send to itss hash, once the terms are filled, the outputs are resolved?
276 2017-03-14T19:12:27  *** Wayward has quit IRC
277 2017-03-14T19:12:49  <cluelessperson> Chris_Stewart_5: the the other, is just sending to a hash/address,  in which the sender can then sign sending to another hash
278 2017-03-14T19:12:49  <Chris_Stewart_5> cluelessperson: Not sure what you mean by 'once the terms are filled'
279 2017-03-14T19:13:03  <cluelessperson> Chris_Stewart_5: Contracts/Scripts have inputs.
280 2017-03-14T19:13:06  <cluelessperson> no?
281 2017-03-14T19:13:20  <Chris_Stewart_5> cluelessperson: Yes, are you talking about spending a p2sh output?
282 2017-03-14T19:14:09  <Chris_Stewart_5> inputs don't care about what outputs they are funding. All that matters is (sum of inputs) <= (sum of outputs) in terms of coins
283 2017-03-14T19:14:43  <Chris_Stewart_5> wait I got that backwards -- oops.
284 2017-03-14T19:15:17  <Chris_Stewart_5> I suppose we don't want to create coins out of thin air :P.
285 2017-03-14T19:18:03  <cluelessperson> AH,  so that's what that means
286 2017-03-14T19:18:05  <cluelessperson> pubkey hash
287 2017-03-14T19:18:07  <cluelessperson> and scripthash
288 2017-03-14T19:18:16  <Chris_Stewart_5> Yep :-). Light bulb going off?
289 2017-03-14T19:18:58  <cluelessperson> Chris_Stewart_5: little bit
290 2017-03-14T19:19:20  <cluelessperson> So there are two types of addresses,   1.  Pubkey hash. Derived from a public key
291 2017-03-14T19:19:28  <cluelessperson> 2.  Script hash... which I'm still confused on
292 2017-03-14T19:19:31  <Chris_Stewart_5> Eric Lombrozo explained it to me once at a meetup and it took me another 3 or 4 months to actually get what he said haha.
293 2017-03-14T19:19:40  <cluelessperson> starts with a 3
294 2017-03-14T19:20:13  <cluelessperson> So, I guess i've never used a pay to script hash
295 2017-03-14T19:20:17  <Chris_Stewart_5> cluelessperson: Imagine you have a multsig address that looks like this: OP_0 OP2 <pubkey1> <pubkey2> <pubkey3> OP_3 OP_CHECKMULTISIG
296 2017-03-14T19:20:42  <Chris_Stewart_5> you converact that to hex and then take HASH160(script_hex)
297 2017-03-14T19:21:12  <Chris_Stewart_5> and then add network byte and checksum and voila you have an address that starts with a '3' (p2sh)
298 2017-03-14T19:21:33  *** kexkey has joined #bitcoin-dev
299 2017-03-14T19:23:04  <arubi> the address doesn't have the 0x00
300 2017-03-14T19:23:15  <arubi> it's only in scriptsig, as an input for checkmultisig
301 2017-03-14T19:23:51  <arubi> well, the scriptpubkey is what I mean
302 2017-03-14T19:23:53  <cluelessperson> okay, so, going back
303 2017-03-14T19:24:04  <cluelessperson> I'm trying to decode/view transactions in a block
304 2017-03-14T19:24:15  <cluelessperson> I can see outputs, but I cannot see the inputs
305 2017-03-14T19:24:20  <arubi> cluelessperson, you're in luck, the block is very mostly only transactions
306 2017-03-14T19:24:45  <arubi> really the first 80 bytes are header, then some varint of the amount of transactions, then transactions one after another :)
307 2017-03-14T19:25:16  <Chris_Stewart_5> arubi: Has a better memory than me (and is much better at answering question IMO) :-)
308 2017-03-14T19:25:46  <arubi> didn't mean to step on toes, just sharing my past mistakes :)
309 2017-03-14T19:26:40  <cluelessperson> https://hastebin.com/raw/epuhacukak
310 2017-03-14T19:27:04  <cluelessperson> So I have these inputs
311 2017-03-14T19:27:11  <cluelessperson> and two outputs
312 2017-03-14T19:27:16  <arubi> cluelessperson, in p2sh redeem, the script goes in first as a single push
313 2017-03-14T19:27:25  <arubi> there's one input there
314 2017-03-14T19:27:30  <arubi> 3 things on the stack
315 2017-03-14T19:27:52  <arubi> from bottom to up, script as a single data push, sig, sig
316 2017-03-14T19:28:04  <arubi> where's the 0x00, I don't know :)
317 2017-03-14T19:28:29  <arubi> it's a 2-of-2 multisig script which will fail on this stack
318 2017-03-14T19:28:55  <arubi> a final 0x00 has to also be pushed because of very cool bugs in checkmultisig(verify)
319 2017-03-14T19:29:18  <arubi> oh excuse me, the 0 is in its own line with the txin :)
320 2017-03-14T19:29:28  <arubi> should be find if the signatures are correct.
321 2017-03-14T19:29:52  <arubi> s/fine :P
322 2017-03-14T19:31:15  *** moli has quit IRC
323 2017-03-14T19:31:39  *** moli_ has joined #bitcoin-dev
324 2017-03-14T19:31:42  <arubi> cluelessperson, the input is 7d8c3a2bc4906994f2e4195c05c3fe88e08da9eaf760c598394fda45b057727e:1 , and is redeemed by the stack in CScript(..)
325 2017-03-14T19:32:01  <arubi> finally there's the sequence, then both outputs
326 2017-03-14T19:34:42  <cluelessperson> Is there some reading I can do that approaches how to understand all this?
327 2017-03-14T19:34:51  <cluelessperson> I'm coming in the middle and none of it is intuitive
328 2017-03-14T19:35:56  <arubi> hmm, did you see the developer documentation?  also the important parts in the code are either very well documented in the comments or are so pretty that you can just read :)
329 2017-03-14T19:36:25  <arubi> the wiki has some pretty interesting pages too.  the op_checksig page has a very good diagram
330 2017-03-14T19:36:26  <cluelessperson> arubi: I'm not sure where the developer documentation is
331 2017-03-14T19:36:37  <cluelessperson> I've been looking at the wiki, but it's not an education approach
332 2017-03-14T19:36:45  <arubi> https://bitcoin.org/en/developer-documentation
333 2017-03-14T19:36:58  <cluelessperson> arubi: thanks
334 2017-03-14T19:37:00  <arubi> https://en.bitcoin.it/wiki/OP_CHECKSIG
335 2017-03-14T19:37:05  <arubi> very good sources ^
336 2017-03-14T19:38:20  <arubi> also there's `bitcoin-tx`, and read the 'help' item for sign rawtransaction for how to set up a json referencing an input
337 2017-03-14T19:38:42  <arubi> if you can do that, you can practically run any script easy :)
338 2017-03-14T19:52:22  *** ThomasV has quit IRC
339 2017-03-14T19:58:34  *** blueness has quit IRC
340 2017-03-14T19:59:57  *** Newyorkadam has quit IRC
341 2017-03-14T20:05:44  *** blueness has joined #bitcoin-dev
342 2017-03-14T20:10:31  *** blueness has quit IRC
343 2017-03-14T20:17:13  *** blueness has joined #bitcoin-dev
344 2017-03-14T20:38:05  *** afk11_ has quit IRC
345 2017-03-14T20:38:18  *** afk11_ has joined #bitcoin-dev
346 2017-03-14T20:41:20  *** Sosumi has quit IRC
347 2017-03-14T21:17:57  *** blueness has quit IRC
348 2017-03-14T21:20:58  *** blueness has joined #bitcoin-dev
349 2017-03-14T21:22:24  *** ThomasV has joined #bitcoin-dev
350 2017-03-14T21:39:58  *** blueness has quit IRC
351 2017-03-14T21:44:06  *** blueness has joined #bitcoin-dev
352 2017-03-14T21:51:32  *** coin_trader has quit IRC
353 2017-03-14T22:16:57  *** NewLiberty_ has joined #bitcoin-dev
354 2017-03-14T22:18:58  *** NewLiberty has quit IRC
355 2017-03-14T22:19:58  *** Newyorkadam has joined #bitcoin-dev
356 2017-03-14T22:31:37  *** cyphase has quit IRC
357 2017-03-14T22:37:34  *** ThomasV has quit IRC
358 2017-03-14T22:42:15  *** Newyorkadam has quit IRC
359 2017-03-14T22:47:24  *** janko33 has quit IRC
360 2017-03-14T22:53:56  <cluelessperson> I have this
361 2017-03-14T22:54:00  <cluelessperson> 0000000000000000000000000000000000000000000000000000000000000000:4294967295     prevout
362 2017-03-14T22:54:04  <cluelessperson> what does that mean?
363 2017-03-14T22:55:06  <achow101> cluelessperson: coinbase I think
364 2017-03-14T22:55:46  <cluelessperson> trying to get the output to understand a transaction
365 2017-03-14T22:57:08  *** Fr4n has quit IRC
366 2017-03-14T22:57:21  *** dpk has joined #bitcoin-dev
367 2017-03-14T22:57:29  *** dpk has left #bitcoin-dev
368 2017-03-14T23:01:19  <cluelessperson> OH, there's no txid for the first transaction in a block right?
369 2017-03-14T23:01:48  <phantomcircuit> cluelessperson, right
370 2017-03-14T23:02:23  <phantomcircuit> or rather it's set to the null representation
371 2017-03-14T23:02:25  <cluelessperson> it's just describing who to send txout to
372 2017-03-14T23:02:28  *** cyphase has joined #bitcoin-dev
373 2017-03-14T23:02:32  <phantomcircuit> which is txid=0 and index=max
374 2017-03-14T23:02:50  <cluelessperson> 593a867c45dcf31975a8da2649f100c136d45cbf34aadf7e04115f0261079f09:1
375 2017-03-14T23:02:55  <cluelessperson> would be a txid right?
376 2017-03-14T23:04:05  <cluelessperson> alright, I'm getting somewhere
377 2017-03-14T23:10:34  *** Fr4n has joined #bitcoin-dev
378 2017-03-14T23:18:29  <cluelessperson> So, I'm supposed to get the utxo or prevout referred to by this transaction,  how do I know how much was there?  do I look at a certain output?
379 2017-03-14T23:18:41  * cluelessperson shuts up and reads the dev guide
380 2017-03-14T23:19:22  *** Fr4n has quit IRC
381 2017-03-14T23:23:18  *** blueness has quit IRC
382 2017-03-14T23:27:29  *** blueness has joined #bitcoin-dev
383 2017-03-14T23:31:36  <luke-jr> a number of decent BIPs have negative comments; I suggest perhaps people may wish to provide positive feedback to counter them. https://github.com/bitcoin/bips/pull/500
384 2017-03-14T23:33:06  *** Fr4n has joined #bitcoin-dev
385 2017-03-14T23:49:49  *** Guyver2 has quit IRC
386 2017-03-14T23:52:03  *** blueness has quit IRC
387 2017-03-14T23:52:47  *** Fr4n has quit IRC
388 2017-03-14T23:59:40  *** abpa has quit IRC