de_henne has quit [Remote host closed the connection]
de_henne has joined #stellar-dev
<stellar-slack>
<sacarlson> what is needed in your browser with js-stellar-sdk to expose StellarBase? example var asset = new StellarBase.Asset("USD", "GDGU5OAPHNPU5UCLE5RDJHG7PXZFQYWKCFOEXSXNMR6KRQRI5T6XXCD7"); I'm getting error ReferenceError: StellarBase is not defined
<stellar-slack>
<sacarlson> cancel last request the answer in this case is var asset = new StellarSdk.Asset('USD', "GDVDKQFP665JAO7A2LSHNLQIUNYNAAIGJ6FYJVMG4DT3YJQQJSRBLQDG"); but I'm still wondering how to create an account in stallarsdk but this may have already answered that
<stellar-slack>
<garbage> sacarlson, what exactly wondering? How generates key pair?
<stellar-slack>
<sacarlson> no how to create an active account from a key pair
<stellar-slack>
<garbage> As far as I understand the need to replenish his account.
<stellar-slack>
<garbage> commit the transaction
<stellar-slack>
<sacarlson> can't send funds to an inactive account
<stellar-slack>
<garbage> I'm just only testnet trying. therefore probably I can not say anything
<stellar-slack>
<garbage> Into testnet used friendbot which funds your account
<stellar-slack>
<sacarlson> I'm reading the first link but don't see anything that looks to create an active account
<stellar-slack>
<buhrmi> @powderfan: that's sweet. it should run in the browser too right?
<stellar-slack>
<sacarlson> oh but the secound looks like it might be it
<stellar-slack>
<powderfan> yes, the first is just to determine, that the destination account needs initial funding instead of an ordinary payment
<stellar-slack>
<sacarlson> so in yours the sender of any asset finances the creation of the account if needed?
<stellar-slack>
<sacarlson> or maybe just for a native transaction I guess
<stellar-slack>
<powderfan> No, an unfunded account cannot have any trustline and thus cannot accept anything but XLM
<stellar-slack>
<sacarlson> right
<stellar-slack>
<sacarlson> makes total sense if your sending XLM to create the account if not already existing
<stellar-slack>
<powderfan> Question: in the #general channel, eva stated that network upgrade wil come Nov. 3rd. I would like to provide a 'migrate funds' button for my users from the very beginning. How do I do this and is there a way to test it?
<stellar-slack>
<sacarlson> very good question that I have been asking for some time. how to migrate funds from old stellard to new network
<stellar-slack>
<powderfan> @buhrmi: yes, my whole app more or less also runs in the browser except some cordova plugin functionality like camara or sharing text via social channels
<stellar-slack>
<sacarlson> ya it's cool as you can test it without an android just by bring up the files index in like firefox
<stellar-slack>
<sacarlson> my translation of powerderfan's createaccount in a click
<stellar-slack>
<sacarlson> but as yet not tested
<stellar-slack>
<sacarlson> last thing to add to my simple client is to get the balance
pixelbeat_ has joined #stellar-dev
<stellar-slack>
<jed> Powderfan check out how we did it in stellar-client. Look at upgrade branch
<stellar-slack>
<powderfan> great thx! I'll try with this doc
<stellar-slack>
<bartek> please note that it won't work for you now because it's not deployed yet.
<stellar-slack>
<powderfan> ah ok, so I assume it will be deployed to test (stellard and stellar-core) first, right?
stellar-slack has quit [Remote host closed the connection]
stellar-slack1 has joined #stellar-dev
Kwelstr has quit [Ping timeout: 246 seconds]
Kwelstr has joined #stellar-dev
<stellar-slack1>
<brian.ebert> Is test net down again?
<stellar-slack1>
<brian.ebert> sorry, I see it now
<stellar-slack1>
<jed> yeah should be up
de_henne has quit [Remote host closed the connection]
<stellar-slack1>
<jed> nice
<stellar-slack1>
<powderfan> Yes, but maybe I found a bug
<stellar-slack1>
<jed> does your wallet support other currencies?
<stellar-slack1>
<powderfan> if you display the balance of the issuer, it should show -100, right?
<stellar-slack1>
<jed> if you want to you can
<stellar-slack1>
<powderfan> but it doesn't GC7DJUFVMD5BYXS67MWAAQSJF6UASF47RY2AUCKOR5J2YTWS6ZNIGS6Y
<stellar-slack1>
<powderfan> ok, how?
<stellar-slack1>
<jed> trustlines in the ledger are just one directional now
<stellar-slack1>
<jed> you want a list of everyone holding credit from GC7D ?
<stellar-slack1>
<powderfan> no, I want to know, how much EUR GC7D has issued
<stellar-slack1>
<powderfan> I supported cross currency on stellard, so I plan to have the same feature on stellar-core
<stellar-slack1>
<jed> yeah horizon doesn't give you this right now. You would have to pull it out of the stellar-core DB. Which isn't that hard to do.
<stellar-slack1>
<jed> make a feature request for horizon if you think this is useful
<stellar-slack1>
<powderfan> I think, it is useful if I'm a gateway, at least. But also for my app. Let me explain: I want to determine all currencies, accepted by a destination address. Now of course an issuer accepts its own currencies. But I cannot get the information
<stellar-slack1>
<powderfan> currently I get the account balances to see whom the destination address trusts on which asset
<stellar-slack1>
<jed> you are saying you want to list assets the gateway has already issued as possibilities for you to send to them?
<stellar-slack1>
<jed> do you think you would need to list ones it issued taht the user doesn't hold?
<stellar-slack1>
<powderfan> first I thought no, but then I think Stellar could find a path from any asset I hold to the issuer's asset and then I could send it without holding it
<stellar-slack1>
<powderfan> should I just create an issue in the horizon project with label "enhancement"?
<stellar-slack1>
<jed> feel free to comment if that isn't what you had in mind
<stellar-slack1>
<powderfan> cool should I create one for js-stellar-sdk as well, or do you think it will be implemented that way, that it works with the current balance mechanism
<stellar-slack1>
<jed> once it is in horizon it will make it into the sdk
<stellar-slack1>
<powderfan> ok nice
<stellar-slack1>
<powderfan> any comment on my problem following links allong this chain: effect -> operation -> transaction? Is it supposed to work?
<stellar-slack1>
<jed> you mean following the links returned from horizon?
<stellar-slack1>
<jed> yeah it should work
<stellar-slack1>
<powderfan> yes in stellar-sdk. cause currently it works from effect to operation but then the resulting object has not function transaction() to call
<stellar-slack1>
<powderfan> ok, should I create an issue for that?
DomKM has quit [Quit: Connection closed for inactivity]
pixelbeat_ has quit [Ping timeout: 240 seconds]
pixelbeat_ has joined #stellar-dev
<stellar-slack1>
<scott> yeah, that would be great
<stellar-slack1>
<powderfan> I've been hunting a bug in my app for a while now and finally found it. Now I don't know, what's the correct way to solve it. 1. I load lets say 20 most recent effects and display in a list 2. Im listening to the effects for account stream with the cursor put to the latest paging_token in order to immediately update the list 3. Under certain circumstances I want to clear my list and go back to step 1 ->
<stellar-slack1>
twice to the stream and get every effect twice
<stellar-slack1>
<powderfan> Can I detach from a stream or detect that I'm already attached?
Trasp has joined #stellar-dev
<stellar-slack1>
<scott> powderfan; call `close()` on the return value of you call to `stream()`
<stellar-slack1>
<scott> It’s an instance of `EventSource`, a standard browser javascript feature
<stellar-slack1>
<powderfan> ok, thanks
<stellar-slack1>
<scott> np :)
<stellar-slack1>
<powderfan> yes this fixed it. great!
Trasp_ has joined #stellar-dev
Trasp has quit [Read error: Connection reset by peer]