The world needs more Lightning!

Overview

10101 (a.k.a TenTenOne)

Dependencies

This project requires Flutter and Rust. Rust toolchain can be installed via Rustup. In order to setup Flutter (as well as mobile simulators etc), please see the excellent Flutter guide here

A lot of complexity for building the app has been encapsulated in a Makefile. To see the available commands, simply run make help or make.

To install necessary project dependencies for all targets, run the following:

make deps

Documentation

This project uses flutter-rust-bridge. It is strongly encouraged to read its documentation before jumping into the project in order to understand the project's structure, conventions and ways of integrating between Rust and Flutter.

Building

The instructions below allow building the Rust backend for 10101 application.

Bindings to Flutter

Bindings for Flutter can be generated with the following command:

make gen

Native (desktop)

make native

iOS

make ios

Android

Native

For building for target devices, run:

make android

Simulator

make android-sim

Formatting

We strive to keep the code consistent, therefore before submitting PRs one should run: make format to ensure code is properly formatted.

Linting

Static analysers (clippy and flutter analyze) can be run by calling make lint.

Running

After compiling the relevant Rust backend in the previous section, invoke Flutter:

flutter run

note: Flutter might ask you which target you'd like to run.

Running 10101 for web target is currently unsupported.

Comments
  • Combine DLCs and Lightning Channels

    Combine DLCs and Lightning Channels

    Goal

    We want to build a wallet which speaks lightning and is able to do DLCs.

    Possible approaches

    Virtual channels

    Probably the most complex solution is to have 2 virtual channels. One speaking lightning, the other one speaking DLCs. E.g. something like this:

    Diagram
    flowchart LR
        A1((Alice))
        B1((Bob))
       
    
        txf[tx_fund]
        
        txc_outer[tx_commit]
        
        txs[tx_settle]
        
        txcis[tx_commit_itchysats]
        txcln[tx_commit_ln]
        or{or}
        and{and}
    
    
        A1 -- fund --> txf
        B1 -- fund --> txf
        txf --> or
        or --> txs
        or --> txc_outer
        txc_outer --> and
        and --> txcis
        and --> txcln
        
        subgraph ItchySats
          txcet_is[tx_cetN]
          txr_is[tx_refund]
          txp_is[tx_punish]
          or_is{or}
          
          txcis --> or_is
          or_is --> txp_is
          or_is --> txcet_is
          or_is --> txr_is
        end
        
        
        subgraph LN
          htlc1((htlc1))
          htlc2((htlc2))
          htlcN((htlcN))
          txp_ln[tx_punish]
    
          txcln --> txp_ln
          txcln --> htlc1
          txcln --> htlc2
          txcln --> htlcN
    
        end
    

    Advantages:

    • we might be able to use ldk, this needs to be evaluated.
    • we might be able to use maia.
    • we should be able to receive standard LN payments from anyone in LN.

    Disadvantage:

    • clearly complex
    • channels can only be opened to nodes running the same code because of the custom transaction structure. i.e. you can't open a channel to other LN nodes (LND or CLightning) with this.

    Maia speak LN

    We could implement the needed bolts into https://github.com/comit-network/maia/

    Advantage:

    • full control over the code base. We can decide to only implement what we really need
    • we should be able to receive standard LN payments from anyone in LN.

    Disadvantage:

    • complexity
    • only compatible with our own nodes, i.e. you can't open channels to other LN nodes (LND, Clightning) with this.

    LN speak DLC

    We could add the DLC feature to a lightning implementation (e.g. use LDK and extend it). The it's ok to be odd would allow us to add features to our client without breaking compatibility with other LN implementations.

    Advantage:

    • we can open a channel with other LN nodes
    • we speak native lightning out of the box

    Disadvantage:

    • Complexity
    • If we build on LDK we probably will need to fork the library to add what we need which could become a nightmare in pulling in upstream changes.
    Legends of Lightning 
    opened by holzeis 14
  • Maker closes channel due to unconfirmed funding transaction

    Maker closes channel due to unconfirmed funding transaction

    env: regtest

    2022-11-29 10:08:56 DEBUG ten_ten_one::lightning: Received ChannelClosed { channel_id: [244, 7, 171, 215, 235, 60, 118, 135, 15, 108, 121, 122, 8, 175, 213, 174, 63, 41, 130, 20, 7, 19, 82, 83, 170, 226, 233, 87, 56, 116, 61, 173], user_channel_id: 0, reason: CounterpartyForceClosed { peer_msg: "Channel closed because of an exception: Funding transaction was un-confirmed. Locked at 0 confs, now have 0 confs." } }
    

    Even though I am fauceting several times after opening a channel.

    How to reproduce

    1. clean maker and taker directories
    2. fund taker (and maker if not already)
    3. open channel (this will succeed)
    4. mine a block

    This might not be necessary, but I always did in my test scenarios. At least it verifies that the channel is actually usable.

    1. open a cfd
    2. settle cfd

    1. close channel
    2. mine a block
    3. open channel
    4. mine a block

    --- It seems at this point we are in a broken state, opening a CFD will fail, even though we got a ChannelReady event.

    Eventually the channel will be force-closed with the message above.

    bug Legends of Lightning Release 0.3.0 
    opened by holzeis 13
  • Allow taker to close channel with 10101 maker

    Allow taker to close channel with 10101 maker

    Fixes #373.

    For now it defaults to a collaborative closure. Eventually, we might want to let the taker force-close.

    https://user-images.githubusercontent.com/9418575/204174964-f09e3854-f911-496a-abfb-24b4a9962530.mp4

    opened by luckysori 13
  • feat: parse flutter arguments

    feat: parse flutter arguments

    This will allow for providing configurations using the command line when running flutter.

    e.g.

    flutter run -d macos --dart-define="NETWORK=testnet" --dart-define="[email protected]:9045"
    

    The following parameter are supported

    • MAKER_IP
    • MAKER_PK
    • MAKER_PORT_LIGHTNING
    • MAKER_PORT_HTTP
    • MAKER_P2P_ENDPOINT (will overwrite MAKER_IP, MAKER_PK and MAKER_PORT_LIGHTNING if set)
    opened by holzeis 12
  • Take into account pending on-chain balance

    Take into account pending on-chain balance

    Fixes https://github.com/itchysats/10101/issues/352.

    Depending on the situation we make use of different values:

    • The balance widget now displays the total balance by default, but on hover one can see a tooltip with the breakdown between confirmed and pending.
    • We use the confirmed on-chain balance to determine how much bitcoin they user can use to either open a channel or send on-chain.
    • We use the total on-chain balance to determine if the initial deposit-bitcoin card should be rendered or not.

    image


    The first commit (https://github.com/itchysats/10101/commit/f56ab4895d9f2fbb20f4e36f00ccdc719cf970e4) was useful for testing so I decided to keep it around.

    opened by luckysori 10
  • Create user journey for the TenTenOne wallet

    Create user journey for the TenTenOne wallet

    A lowfi set of user interfaces depicting the user journey through the app including the following flows.

    • Initialize wallet
    • Create payment channel with maker.
    • Navigation to the CFD trading app (itchysats)
    • Open a CFD trade (funding through the lightning wallet)
    • Close a CFD trade
    Legends of Lightning 
    opened by holzeis 10
  • Add sqlite support for storing lightning payments

    Add sqlite support for storing lightning payments

    note: this is just the insert/load API with tests, adding it now to avoid trouble rebasing later (and to spark a conversation whether we should use one or two tables (inbound / outbound payments)

    opened by klochowicz 9
  • BIP39 derived seed for a BIP84 wallet

    BIP39 derived seed for a BIP84 wallet

    This PR derives a BIP84 wallet from a BIP39 seed phrase and exposes a corresponding rust api through the flutter rust bridge. Additionally this PR already improves the structuring (to the best of my limited flutter skills).

    resolves #68 #11

    This PR is still draft as the seed screen needs a little bit more care.

    opened by holzeis 9
  • feat: Add market view

    feat: Add market view

    Embed a TradingView bitmex XBTUSD widget inside a webview.

    Note: it works on Android/iOS. Desktop platforms get a placeholder that the functionality is not supported yet.

    I've recorded in landscape, as it's much nicer for viewing charts like that 😁 https://user-images.githubusercontent.com/8319440/203267520-dd5b8835-12e2-4ca1-8aa9-579b5e8f081a.mov

    opened by klochowicz 8
  • feat: Generate lightning invoices

    feat: Generate lightning invoices

    • align the API to allow passing custom description when creating invoice
    • Add a Flutter widget that allows creating an invoice. You can specify amount, expiry time, and add a custom description. It generates a QR code and allows you to copy invoice to clipboard.
    opened by klochowicz 8
  • Add service selector to dashboard

    Add service selector to dashboard

    Includes navigation to CFD Trading screen, but we need more complex routing and should plug in a routing library as recommended here: https://docs.flutter.dev/development/ui/navigation#using-the-navigator

    Screenshot 2022-11-01 at 3 07 23 pm

    I will work on introducing go_router routing library so we can depict the routing between the wallet and the service screens.

    Note on naming: I don't particularly like the name service for trading/bets (...) - I thought about different names (e.g. feature or in-app-...?) but did not come up with anything satisfying so I just went with service for now.

    opened by da-kami 8
  • Create a signet setup

    Create a signet setup

    So far, we used regtest or testnet for testing.

    We should evaluate how easy it is to setup a bitcoin signet including additional services like a blockexplorer and electrs.

    opened by bonomat 4
  • feat: Restart failed background processor

    feat: Restart failed background processor

    Adds and handling in case the background processor stops, by simply trying to start the background processor again.

    Some more refactoring could be probably done there, but I tried to keep the changes to a minimum.

    opened by holzeis 1
  • chore: Introduce dedicated runtime

    chore: Introduce dedicated runtime

    Annotating the function with #[tokio::main] killed the runtime after the function completes. Thus we had to block the run function indefinitely for the long living threads to keep going.

    This change introduces a runtime managed outside of the function scope and thus allows the run function to return bringing the following advantages.

    • We don't block a whole frb worker thread just to run the lightning node, sync tasks, background processor, etc.
    • We are using a multi threaded runtime instead of the current thread
      • allowing to actually join the background processor without blocking all other tasks.
      • making better use of multiple cpu cores.
    • We are not creating a new runtime on every async bridge call.
    opened by holzeis 0
  • Only log rust in case of android or ios

    Only log rust in case of android or ios

    I primarily work with the simulator and it bugged me to disable this if all the time. Only logging if on android or ios will not polute the logging if working with native.

    opened by holzeis 1
  • Opening channel fails sometimes

    Opening channel fails sometimes

    Tested on testnet stable 0.3.2 android

    Opening a channel, does not always succeed. It looks like the maker is busy and we are constantly loosing the connection. During channel creation this is critical as the exchange between both parties is required. see logs below.

    Open Channel HTTP Request

    2022-12-07 14:55:13  INFO rocket::server: POST /api/channel/open application/json:    
    2022-12-07 14:55:13  INFO _: Matched: (post_open_channel) POST /api/channel/open application/json    
    2022-12-07 14:55:13 DEBUG ten_ten_one::wallet: Sending to address address=tb1q0zqkdj72pda06k4605nk8f5us29la2qyat4vjw sats=30500
    2022-12-07 14:55:13  WARN electrum_client::client: call 'estimate_fee' failed with EOF while parsing a value at line 1 column 0, retry: 1/1    
    2022-12-07 14:55:15 DEBUG electrum_client::raw_client: new_ssl socket_addrs.domain():Some("blockstream.info") validate_domain:true timeout:None    
    2022-12-07 14:55:15  INFO electrum_client::client: Succesfully created new client    
    2022-12-07 14:55:16 DEBUG ten_ten_one::wallet: Sent to address address=tb1q0zqkdj72pda06k4605nk8f5us29la2qyat4vjw sats=30500 txid=2668d12c9db9e3c5e2bbc5d552529c285541266cf8ec1dd6fa6f11a803218e01
    

    Open Channel LDK Request

    raw_log="Received message OpenChannel(OpenChannel { chain_hash: 000000000933ea01ad0ee984209779baaec3ced90fa3f408719526f8d77f4943, temporary_channel_id: [67, 203, 55, 17, 143, 255, 49, 187, 129, 167, 164, 56, 113, 5, 221, 77, 167, 236, 49, 212, 122, 47, 227, 235, 76, 164, 209, 93, 12, 194, 44, 179], funding_satoshis: 45000, push_msat: 30000000, dust_limit_satoshis: 354, max_htlc_value_in_flight_msat: 4500000, channel_reserve_satoshis: 1000, htlc_minimum_msat: 1, feerate_per_kw: 253, to_self_delay: 144, max_accepted_htlcs: 50, funding_pubkey: PublicKey(40bbffa9a84c985d1b940e888eb773894da2cb4a085128425381423dd09d21a3f530af302cd86aece877942c241878121102e7ff050b1e235087c6019d7e7030), revocation_basepoint: PublicKey(d3b74fd54644768651180d56811f6a96609379faa100e41c6a5e3a19660c7328e4ea3b642c745223af119678645ca3c735cac6d9850effc1014aeba1e799968d), payment_point: PublicKey(6095d415d5119d98e5eb7986c2a82872b3ba144f4269c09ab6046d753e9f0f933d38569c17aa51b54a0a6b9bc0666966ab683b89f7d6d7d49a81ec48ee88bf7e), delayed_payment_basepoint: PublicKey(d29fe58a207ebe67e5065896b950b6bca7691ce828e7f1d33768492319e04ed33af748b726be152ec7b4f14c0054c191f4711cab790ee8704bccac5f67da9123), htlc_basepoint: PublicKey(1d9e9393db9d4cca44595390b24f55ef60ac1b5529890b53372586b3701399d39608d6b4eed16d920a8ffbe93ee500a8276357fdc90e95524d39e085677831fd), first_per_commitment_point: PublicKey(640cb5f219fc8c73f877220d13aa9b3d1cb95d131a3941b68d0f2920979d6d8d06891fe6be55cbf9bfda8bc129d1d49b5008904170560a35b9364800c29cb406), channel_flags: 1, shutdown_scriptpubkey: Present(Script(OP_0 OP_PUSHBYTES_20 eda326297491e33ac62b78f8e3c2761b2b26f746)), channel_type: Some([0, 16]) }) from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:55:36 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::peer_handler" line=1626 raw_log="Handling SendAcceptChannel event in peer_handler for node 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef for channel 43cb37118fff31bb81a7a4387105dd4da7ec31d47a2fe3eb4ca4d15d0cc22cb3"
    2022-12-07 14:55:36 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message AcceptChannel { temporary_channel_id: [67, 203, 55, 17, 143, 255, 49, 187, 129, 167, 164, 56, 113, 5, 221, 77, 167, 236, 49, 212, 122, 47, 227, 235, 76, 164, 209, 93, 12, 194, 44, 179], dust_limit_satoshis: 354, max_htlc_value_in_flight_msat: 4500000, channel_reserve_satoshis: 1000, htlc_minimum_msat: 1, minimum_depth: 1, to_self_delay: 144, max_accepted_htlcs: 50, funding_pubkey: PublicKey(8f1691e5f70d8edd7cb83e5d615e7e96e003b04859383f50e494bac00ca87a9ef3bbcccd314966cf1ff13ea7a7f7bbfc72a317cc0895536c0705cda543927585), revocation_basepoint: PublicKey(b8ae54753a340c25dfb1114214a8d2b36189504b671a50cc3ac5d517759777b978039c672b42916019e051064684bec9759b1bf264543f32deab5cb33d506e61), payment_point: PublicKey(51a66ab04f996ce0bd9f74087d3ad9ed72cd1aade805443415b50601539c67029b61bfd93f76a1fcce25cf4c624f9e5dd3202c9398f4403fa75a8b5a231bb581), delayed_payment_basepoint: PublicKey(81400626532948ea7a4a1a22c42e8153e050185b5c1ca7071fd57d35485442cb1bb4ea7c34075f5e85da2dcfbfc5ebb0ad60bd492e1e228e6ad6a10cda94c120), htlc_basepoint: PublicKey(73c240c00019e9044da117c43212aebf094a2c0a747f17d09d79ead5524d79e524fc3fe8e5372ff3bf28d27a4e8fe26b6d5e4f6306ce9866786359a2e1e8e35b), first_per_commitment_point: PublicKey(dfff833ff49407a3d07117292f1ed5a06e7c3bccbf61a3444805d75ba3d3c2055f6cfce7a28f6a3f21524c1a021833b509d1ee7d5abba795e811bd2e62a9beb9), shutdown_scriptpubkey: Present(Script(OP_0 OP_PUSHBYTES_20 e9571a9901769c3537e1b060092dd35935a37766)), channel_type: Some([0, 16]) } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=1290 raw_log="Received message FundingCreated(FundingCreated { temporary_channel_id: [67, 203, 55, 17, 143, 255, 49, 187, 129, 167, 164, 56, 113, 5, 221, 77, 167, 236, 49, 212, 122, 47, 227, 235, 76, 164, 209, 93, 12, 194, 44, 179], funding_txid: 250ad0ed727946389d93c6dd4f03364e934b2a1564e06bc88640805c3a8a6c71, funding_output_index: 0, signature: 3044022028a4aa4c7831ad13b9d4c67187b215b4aad67f8ab565606bb6fbf2fb1cd3e26b02207933c4ea95e76e6c9f765da67659165db65621e70d60cdba3c0cd6449f583134 }) from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=1556 raw_log="Building commitment transaction number 281474976710655 (really 0 xor 120000230322308) for channel 43cb37118fff31bb81a7a4387105dd4da7ec31d47a2fe3eb4ca4d15d0cc22cb3 for us, generated by remote with fee 253..."
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=1797 raw_log="   ...including to_local output with value 30000"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=1803 raw_log="   ...including to_remote output with value 14817"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=2342 raw_log="Checking funding_created tx signature 28a4aa4c7831ad13b9d4c67187b215b4aad67f8ab565606bb6fbf2fb1cd3e26b7933c4ea95e76e6c9f765da67659165db65621e70d60cdba3c0cd6449f583134 by key 03a3219dd03d428153422851084acba24d8973b78e880e941b5d984ca8a9ffbb40 against tx 0200000001716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a250000000000bb236d8002e139000000000000160014fa0613f84635d8f75b2d49c1f4c3065dc005a0b13075000000000000220020cde8ee971869e832749e37dc107958d24359d7bd361db43a062e79532b86786184f01920 (sighash 28c692165db829da6b259e8a9f056300c350881b51dedc630af3730f487cc565) with redeemscript 475221039e7aa80cc0ba94e4503f385948b003e0967e5e615d3eb87cdd8e0df7e591168f2103a3219dd03d428153422851084acba24d8973b78e880e941b5d984ca8a9ffbb4052ae for channel 43cb37118fff31bb81a7a4387105dd4da7ec31d47a2fe3eb4ca4d15d0cc22cb3."
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=1556 raw_log="Building commitment transaction number 281474976710655 (really 0 xor 120000230322308) for channel 43cb37118fff31bb81a7a4387105dd4da7ec31d47a2fe3eb4ca4d15d0cc22cb3 for remote, generated by remote with fee 253..."
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=1797 raw_log="   ...including to_remote output with value 14817"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=1803 raw_log="   ...including to_local output with value 30000"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=2354 raw_log="Initial counterparty tx for channel 43cb37118fff31bb81a7a4387105dd4da7ec31d47a2fe3eb4ca4d15d0cc22cb3 is: txid 68d066c8705b90b924a61d4aaf12f98068eae6322d59c716543a85d907d4bb80 tx 0200000001716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a250000000000bb236d8002e13900000000000022002009a5d105f56d008c53a8ede2f6aaec05560b926403a8ac10cdf0b5a61ae512283075000000000000160014f43a32aee348fc7bf9aa0a5dce02a50b7acd00b984f01920"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::chain::channelmonitor" line=2092 raw_log="Tracking new counterparty commitment transaction with txid 68d066c8705b90b924a61d4aaf12f98068eae6322d59c716543a85d907d4bb80 at commitment number 281474976710655 with 0 HTLC outputs"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Info) module_path="lightning::ln::channel" line=2438 raw_log="Generated funding_signed for peer for channel 716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a25"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::chain::chainmonitor" line=583 raw_log="Got new ChannelMonitor for channel 716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a25"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Info) module_path="lightning::chain::chainmonitor" line=597 raw_log="Persistence of new ChannelMonitor for channel 716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a25 completed"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::peer_handler" line=1647 raw_log="Handling SendFundingSigned event in peer_handler for node 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef for channel 716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a25"
    2022-12-07 14:55:37 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message FundingSigned { channel_id: [113, 108, 138, 58, 92, 128, 64, 134, 200, 107, 224, 100, 21, 42, 75, 147, 78, 54, 3, 79, 221, 198, 147, 157, 56, 70, 121, 114, 237, 208, 10, 37], signature: 304402207968f254589c84cab013c28350945d668ac3f2fade7db1a3a9835328fe0a58120220097fff4a3f1c1677c2703a6b32b1c1e007cc8ebccdcc07dddf0a2f3720f6c6eb } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    

    Don't know what this is about - Unsure if this is even an issue.

    2022-12-07 14:55:42 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=6167 raw_log="New best block: 0000000000000003efc12b6443ef9d6f279982ca288917f8d95266a5764f155a at height 2410224"
    2022-12-07 14:55:42 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=5867 raw_log="Cannot create an announcement_signatures as our peer is disconnected"
    2022-12-07 14:55:42 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=5867 raw_log="Cannot create an announcement_signatures as our peer is disconnected"
    2022-12-07 14:55:42 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=5867 raw_log="Cannot create an announcement_signatures as our peer is disconnected"
    2022-12-07 14:55:42 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=5867 raw_log="Cannot create an announcement_signatures as our peer is disconnected"
    2022-12-07 14:55:42 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=5867 raw_log="Cannot create an announcement_signatures as our peer is disconnected"
    

    Ping Pong Looks like the taker is still able to reach the maker

    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=1290 raw_log="Received message Ping(Ping { ponglen: 0, byteslen: 64 }) from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message Pong { byteslen: 0 } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    

    Failing HTLC / Duplicative fail for HTLC

    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=5618 raw_log="Failing HTLC with hash ca5112e4d5715691dbdef5abd73df96f70f64053781316e29b940c10d9f64630 from our monitor"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=4191 raw_log="Received duplicative fail for HTLC with payment_hash ca5112e4d5715691dbdef5abd73df96f70f64053781316e29b940c10d9f64630"
    

    Disconnection from taker even if at the very same second a ping pong was processed.

    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=1862 raw_log="Handling disconnection of peer 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef, with future connection to the peer possible."
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::channelmanager" line=6534 raw_log="Marking channels with 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef disconnected and generating channel_updates. We believe we can make future connections to this peer."
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channel" line=4202 raw_log="Peer disconnection resulted in 0 remote-announced HTLC drops on channel 716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a25"
    

    Finished noise handshake: ?

    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::peer_handler" line=1118 raw_log="Finished noise handshake for connection with 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message Init { features: [162, 81, 10, 8, 128, 160, 8], remote_network_address: Some(IPv4 { addr: [194, 166, 99, 139], port: 49548 }) } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    

    Peer init message: I guess the taker is trying to reconnect?

    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Info) module_path="lightning::ln::peer_handler" line=1246 raw_log="Received peer Init message from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef: DataLossProtect: supported, InitialRoutingSync: not supported, UpfrontShutdownScript: supported, GossipQueries: supported, VariableLengthOnion: required, StaticRemoteKey: required, PaymentSecret: required, BasicMPP: supported, Wumbo: supported, ShutdownAnySegwit: supported, OnionMessages: supported, ChannelType: supported, SCIDPrivacy: supported, ZeroConf: supported, unknown flags: none"
    

    Maker tries to reestablish the channel <- this is repeated several times - I guess this is due to an unstable connection between the maker and the taker.

    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::channelmanager" line=6590 raw_log="Generating channel_reestablish events for 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=2474 raw_log="Attempting to generate broadcast channel update for channel fedba3852b899aea200fcf76ae0dadca6a4a03857eb6e39bbadeedb41d9877f1"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=2484 raw_log="Attempting to generate channel update for channel fedba3852b899aea200fcf76ae0dadca6a4a03857eb6e39bbadeedb41d9877f1"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=2493 raw_log="Generating channel update for channel fedba3852b899aea200fcf76ae0dadca6a4a03857eb6e39bbadeedb41d9877f1"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Info) module_path="lightning::ln::channel" line=5985 raw_log="Sending a data_loss_protect with no previous remote per_commitment_secret for channel 716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a25"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=2474 raw_log="Attempting to generate broadcast channel update for channel 2786d3cbf977d02d0a1a074300e665a467f7f4695c478975ca57f5968e7a2824"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=2484 raw_log="Attempting to generate channel update for channel 2786d3cbf977d02d0a1a074300e665a467f7f4695c478975ca57f5968e7a2824"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::channelmanager" line=2493 raw_log="Generating channel update for channel 2786d3cbf977d02d0a1a074300e665a467f7f4695c478975ca57f5968e7a2824"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::peer_handler" line=1722 raw_log="Handling SendChannelAnnouncement event in peer_handler for node 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef for short channel id 2649625110852861953"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::peer_handler" line=1716 raw_log="Handling SendChannelReestablish event in peer_handler for node 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef for channel 716c8a3a5c804086c86be064152a4b934e36034fddc6939d38467972edd00a25"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message ChannelReestablish { channel_id: [113, 108, 138, 58, 92, 128, 64, 134, 200, 107, 224, 100, 21, 42, 75, 147, 78, 54, 3, 79, 221, 198, 147, 157, 56, 70, 121, 114, 237, 208, 10, 37], next_local_commitment_number: 1, next_remote_commitment_number: 0, data_loss_protect: Present(DataLossProtect { your_last_per_commitment_secret: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], my_current_per_commitment_point: PublicKey(02020202020202020202020202020202020202020202020202020202020202ffcee50f772e0a9972250d4b61b3e5beb95de897c73b4ed1cc35ed013accf1c840) }) } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Debug) module_path="lightning::ln::peer_handler" line=1722 raw_log="Handling SendChannelAnnouncement event in peer_handler for node 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef for short channel id 2649654797664387073"
    2022-12-07 14:57:29 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message GossipTimestampFilter { chain_hash: 000000000933ea01ad0ee984209779baaec3ced90fa3f408719526f8d77f4943, first_timestamp: 1670421449, timestamp_range: 4294967295 } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:30 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=1290 raw_log="Received message ChannelReestablish(ChannelReestablish { channel_id: [113, 108, 138, 58, 92, 128, 64, 134, 200, 107, 224, 100, 21, 42, 75, 147, 78, 54, 3, 79, 221, 198, 147, 157, 56, 70, 121, 114, 237, 208, 10, 37], next_local_commitment_number: 1, next_remote_commitment_number: 0, data_loss_protect: Present(DataLossProtect { your_last_per_commitment_secret: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], my_current_per_commitment_point: PublicKey(02020202020202020202020202020202020202020202020202020202020202ffcee50f772e0a9972250d4b61b3e5beb95de897c73b4ed1cc35ed013accf1c840) }) }) from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    

    Ping pong

    2022-12-07 14:57:30 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message Ping { ponglen: 0, byteslen: 64 } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:30 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=1290 raw_log="Received message Ping(Ping { ponglen: 0, byteslen: 64 }) from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:30 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message Pong { byteslen: 0 } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:30 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=1290 raw_log="Received message Pong(Pong { byteslen: 0 }) from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:32 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=1290 raw_log="Received message Ping(Ping { ponglen: 0, byteslen: 64 }) from 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    2022-12-07 14:57:32 DEBUG ldk: log_level=Level(Trace) module_path="lightning::ln::peer_handler" line=987 raw_log="Enqueueing message Pong { byteslen: 0 } to 021e132fd64d457a507b56c1e67aa03a65913c176d733b8e9b110fe164063ce4ef"
    
    bug testnet 
    opened by holzeis 1
  • Channel gets force-closed when opening another CFD

    Channel gets force-closed when opening another CFD

    I opened 3 cfds in total (one of them got closed).

    At some point, the CFD was "open", but the channel was force-closed as I could not create new CFDs.

    I found this log that might be relevant here:

    2022-12-07 02:51:38  INFO ten_ten_one::lightning: EVENT: Channel 56b173e607c51cd83ad807e03f438076ef77bcfa64d4bba7b521d13c83e62ca5 closed due to: CounterpartyForceClosed { peer_msg: "Invalid commitment tx signature from peer" }
    
    bug 
    opened by klochowicz 0
Releases(0.3.2)
  • 0.3.2(Dec 7, 2022)

    Fixed

    • Action button that enables simple navigation to the wallet dashboard from all screens that show the balance.
    • Don't auto open the keyboard in the CFD trading screen.
    • Default invoice description keyboard to text.
    • Persist feed backup state over restarts.

    Added

    • Settings screen that shows some useful app information but does not allow changes yet.
    • Show connection status to 10101 in the app.

    Changed

    • Form validation for the open channel screen providing the user with more information.
    • Detect expired lightning payments and show them.
    • Show the confirmed balance as on-chain balance instead of the total balance to avoid confusion when opening a channel.
    Source code(tar.gz)
    Source code(zip)
    tentenone-0.3.2.apk(52.09 MB)
  • 0.3.1(Dec 2, 2022)

  • 0.3.0(Dec 2, 2022)

  • 0.2.1(Nov 25, 2022)

    Fixed

    • Opening CFDs works again. We had introduced a regression with patch 38c09b25c8903e2aeb6831c637493f88e5731ff1 which prevented the taker from noticing that the channel was ready.
    • Stopped hanging on the splash screen if the 10101 maker is unreachable.

    Changed

    • Improve UI error message after opening a channel fails.
    Source code(tar.gz)
    Source code(zip)
    tentenone-0.2.1.apk(40.68 MB)
  • 0.2.0(Nov 24, 2022)

    Added

    • A mobile Lightning node that can be used to send and receive payments. The backend code is based on our fork of ldk-bdk-sample.
    • Support for CFD trading on Lightning. This is made possible by depending on our our rust-lightning fork.
    • A combined view of all incoming and outgoing payments and transactions to the dashboard.
    • The ability to send and receive on-chain transactions.
    • A history for on-chain transactions and off-chain payments.
    • Added CFD trading screens: offer screen; order confirmation screen; My CFDs screen; and a CFD details screen that allows settlement.
    • Support for CFD trading against the 10101 node on Bitcoin testnet.
    • Placeholder cards and screens for additional services that showcase our vision to add sports betting, a Taro exchange and savings products.

    Changed

    • Overhauled the app's look and feel. We are using blue as the main color and have aligned the theme throughout the application elements.
    Source code(tar.gz)
    Source code(zip)
    tentenone-0.2.0.apk(40.70 MB)
  • 0.1.0(Nov 9, 2022)

Owner
ItchySats
Trade derivatives peer-to-peer on Bitcoin
ItchySats
Lightning fast, strongly typed network protocol

What is Bolt Bolt is a network protocol written in Dart to send and receive strongly typed data objects. It is designed to be easy to use and to be as

Jochum van der Ploeg 42 Dec 3, 2022
World Time App - World time application made using flutter

World Time App Flutter Application to view time in different parts of world. This was my first app built while learning flutter App Screenshots Loadin

Akash Rajpurohit 0 Jan 17, 2020
Flutter-world-time-practice - World Time Tutorial App For Flutter

world_time Result of Flutter Tutorial for Beginners Navigation: pushNamed, pop r

Seonghyeon Cho 1 Feb 7, 2022
A platform for car sharing where users can book any car that suits their needs and wants for their intended journey, from the closest hosts in the community.

Getting Started This project is a starting point for a Flutter application. For help getting started with Flutter, view our online documentation, whic

Faisal Ramdan 28 Apr 29, 2022
AMURoboclub is the official app of AMURoboclub, a student body of ZHCET that nurtures the needs of curious and innovative minds

AMURoboclub is the official app of AMURoboclub, a student body of ZHCET that nurtures the needs of curious and innovative minds. It is the nerve center of robotics enthusiasts who are curious and innovative and wish to come together to learn and share. With the motto 'Where Innovation Meets Implementation', it endeavors to ignite young minds with the fuel of robotics. Enabling that, the app ensures to acquaint its users with the various activities and achievements of AMURoboclub.

AMU Roboclub 9 Dec 6, 2022
With TOT you can find a teacher that is suitable for your needs with less effort, less time, and less money.

TOT App In TOT we are here to help you find a teacher at any aspect of science you want from kindergarten to secondary schools. Instead of searching m

Ahmed Hussein 2 Sep 29, 2022
DoItEverywhere fitnessApp - DIE - A project created in flutter for the needs of classes

DIE - DoItEverywhere DIE is a project created in flutter for the needs of classe

Grzegorz Kucharski 0 Jan 31, 2022
Magpie-fly is a component library produced by 58 Group, which encapsulates a variety of common components to meet the needs of developers

[toc] magpie_fly Magpie-fly 是58集体出品组件库,封装了多种常用组件,以满足开发者需求。(Magpie-fly is a component library produced by 58 Group, which encapsulates a variety of com

Wuba 40 Mar 18, 2022
The application contains the Noble Qur’an, Qur’an radio stations, morning and evening remembrances, and some supplications that a Muslim needs in his life, as well as prayer times, the direction of the qiblah, and the Forty-Nawawi book

The application contains the Noble Qur’an, Qur’an radio stations, morning and evening remembrances, and some supplications that a Muslim needs in his life, as well as prayer times, the direction of the qiblah, and the Forty-Nawawi book

Mohamed Ayad 14 Dec 15, 2022
Application that calculates the calorie needs of a person.

calories_app It is an application that calculates a person's calorie requirement. Getting Started This project is a starting point for a Flutter appli

Edghi 3 Oct 12, 2022
Weather app using Bloc architecture pattern & generic HTTP client with interface implementation and much more for more detail read Readme

weather Weather application for current weather, hourly forecast for 48 hours, Daily forecast for 7 days and national weather alerts. How to Run Insta

Jibran Ahmed SiddiQui 9 Oct 29, 2022
More than 130+ pages in this beautiful app and more than 45 developers has contributed to it.

flutter-ui-nice ❤️ Star ❤️ the repo to support the project or ?? Follow Me.Thanks! Facebook Page Twitter Medium QQ Group Flutter Open NieBin Flutter O

Flutter开源社区 3.4k Jan 3, 2023
An extended version of Flutter Colors with more swatches and more flexibility to generate your own custom swatch.

Colours An extended version of Flutter Colors with more swatches and more flexibility to generate your own custom swatch. Getting Started In your flut

Salman S 4 Nov 23, 2021
More than 130+ pages in this beautiful app and more than 45 developers has contributed to it.

flutter-ui-nice ❤️ Star ❤️ the repo to support the project or ?? Follow Me.Thanks! Facebook Page Twitter Medium QQ Group Flutter Open NieBin Flutter O

Flutter开源社区 3.4k Jan 5, 2023
An easy-to-use flutter http network requests handler with more functionality than http but more simpler than dio.

network_requests An easy-to-use flutter http network requests handler with more functionality than http but more simpler than dio. Platform Supported

Coder_Manuel 3 Dec 15, 2022
A set of real world timelines to showcase the use of timeline_tile package, built with Flutter.

beatiful_timelines Beautiful timelines built with Flutter and timeline_tile. Current examples: Timeline Showcase Football Timeline Activity Timeline S

null 233 Dec 21, 2022
Breathe is a mental health blogging app where users can join communities of doctors and other users from around the world and both share their problems as well as lend a ear to and help others

?????????????? ?????????????? In a condensed, suffocating society you can feel closed off, when you can't process your emotions and are going through

Soham Sen 3 May 16, 2022
An application to track bitcoin prices around the world.

![App Brewery Banner](https://github.com/londonappbrewery/Images/blob/master/AppBreweryBanner.png) # Bitcoin Ticker ?? ## Our Goal The object

Aryaman Prakash 1 Jan 7, 2022
Sample flutter project to show exchange Rates of leading cryptos to different currencies in the world.

bitcointicker A bitcoin ticker project Getting Started This project is a starting point for a Flutter application. A few resources to get you started

null 0 Feb 15, 2022