Commit graph

196 commits

Author SHA1 Message Date
Vlad Stan
63ea3369d3 fix: do not hide Exception message 2022-12-12 10:20:27 +02:00
Vlad Stan
3288722ef4 refactor: spit ReadOnlySettings 2022-12-09 15:13:58 +02:00
Vlad Stan
49855669a5 refactor: move init logic at the bottom 2022-12-09 13:40:22 +02:00
Vlad Stan
6d1db80bb3 refactor: build dynamically readonly_variables 2022-12-09 13:37:36 +02:00
Vlad Stan
d6d42250a9 refactor: use JSON for settings 2022-12-09 13:14:22 +02:00
Vlad Stan
0ed2ec6519 refactor: extract funding sources to their own classes 2022-12-09 11:35:46 +02:00
Vlad Stan
68b4a20e26 feat: enable validator for ReadonlySettings 2022-12-09 11:06:43 +02:00
Vlad Stan
7952a462e3 feat: extract parent LNbitsSetings class 2022-12-09 10:57:53 +02:00
Vlad Stan
0d4954c01a chore: temp commit (does not work); don't want to lose changes 2022-12-09 09:46:30 +02:00
Vlad Stan
d15782521d refactor: include admin extension into core 2022-12-08 15:41:52 +02:00
Tiago Vasconcelos
301cc6229e remove lnbits_admin_extensions from readonly variables 2022-12-08 10:15:34 +00:00
dni ⚡
b4e8659006 fix default value for reserve fee
format
2022-12-07 15:58:33 +01:00
dni ⚡
89933c2d30 test should pass now, WALLET is initialised after the settings are loaded from db. 2022-12-07 13:38:33 +01:00
dni ⚡
c189ec49e5 add superuser class to obscure superuser_id for admin in the ui 2022-12-07 11:00:48 +01:00
dni ⚡
344e951368 remove unused comment, and drop readonly settings on update 2022-12-06 15:30:53 +01:00
dni ⚡
d2cd972663 refactor from settings.py into admin crud, but broke frontend
formatting
2022-12-06 11:02:01 +01:00
dni ⚡
c56a31e6f5 add superuser and refactor check_admin function, also put it into satspay 2022-12-05 20:41:23 +01:00
dni ⚡
9d67c8e4e5 checks, redundant error handling 2022-12-05 17:50:13 +01:00
dni ⚡
e49112d4ee rename read_only_variables to readonly_variables 2022-12-05 16:13:26 +01:00
dni ⚡
9b37c68b7c calle, change logger.warning messages 2022-12-05 16:10:35 +01:00
dni ⚡
35920bae48 code improvements, bugfixes 2022-12-05 15:43:26 +01:00
Tiago Vasconcelos
c3e6ed9089 fix for default ad image URL 2022-12-02 14:59:02 +00:00
Tiago Vasconcelos
52cbc7d0f7 make format 2022-12-02 14:38:21 +00:00
Tiago Vasconcelos
4410968bf5 enable disable ads and display ads 2022-12-02 14:36:09 +00:00
Tiago Vasconcelos
f7dd533daa make ad space as a CSV formatted string 2022-12-01 22:16:55 +00:00
dni ⚡
e3e62fc073 formatting 2022-11-30 23:52:13 +01:00
dni ⚡
86d2780c9f fix template typos and also update settings in memory after a admin PUT 2022-11-30 23:47:52 +01:00
dni ⚡
e740ad3cf8 fix lnbitswallet issue, add ad_space_title, change lntips funding source 2022-11-30 16:53:46 +01:00
dni ⚡
b49545f48b exlude forwarded_allow_ips 2022-11-29 20:29:08 +01:00
dni ⚡
acc27a4714 fix lndgrpc regtest errors 2022-11-24 15:43:15 +01:00
dni ⚡
74eece78de merge from master 2022-11-24 14:35:32 +01:00
ben
71d105b5d5 Accidental delete 2022-11-23 17:06:45 +00:00
ben
f458fc416c black 2022-11-20 18:23:18 +00:00
ben
0c94b159e2 Improved ad space function 2022-11-20 17:29:07 +00:00
dni ⚡
0096ce8ad1
let poetry run lnbits recognize forwarded_ips for https (#1109) 2022-11-19 14:41:37 -06:00
dni ⚡
c9ead25d50 bugfixes and fix topup wallet 2022-10-12 13:08:59 +02:00
dni ⚡
91a5f7d214 add callback for saas app 2022-10-10 23:27:46 +02:00
dni ⚡
85cb2573f9 fix settings for lndgrpc and poetry lock 2022-10-06 10:13:45 +02:00
dni ⚡
282ef34d11 reintroduce signalhandler and ad encrypted macaroon 2022-10-05 13:12:16 +02:00
dni ⚡
c845502f28 fix WALLET initialisation 2022-10-05 13:05:09 +02:00
dni ⚡
36f54ff0c3 formatting and conftest 2022-10-05 13:04:38 +02:00
dni ⚡
d2c216d6db fix regtests, admin settings prints 2022-10-05 13:04:38 +02:00
dni ⚡
ec0375b47c trying to fix tests 2022-10-05 13:04:38 +02:00
dni ⚡
92e52cd883 overall fixes 2022-10-05 13:04:38 +02:00
dni ⚡
1ffc8c3498 use new settings and remove unused amdin extension stuff 2022-10-05 13:04:36 +02:00
Tiago vasconcelos
960598d5dc reserve fee added 2022-10-05 13:01:59 +02:00
Tiago vasconcelos
582cc52ac6 make it work from g() 2022-10-05 13:01:59 +02:00
Tiago vasconcelos
844e11edeb add admin_ui env 2022-10-05 13:01:59 +02:00
Jesse de Wit
d64feec2a5
strip environment variable list items (#993) 2022-09-23 11:01:14 +03:00
dni ⚡
78a98ca97d
Boltz.exchange Extension (#922)
* initial commit and still draft, ready for review

* forgot to uncomment this line

* fee estimation and blockheight

* resolve conversation with michael, to use mempool websockets instead of boltz status event

* Update lnbits/extensions/boltz/boltz.py

Co-authored-by: michael1011 <me@michael1011.at>

* add status to swaps, add sorting and data into listing

* add swap status checks, change urls to docker test setup, dynamic minimum and maximum limits

* fix docker hosts for development

* add api endpoints to _api_docs

* add wallet name and id, to list and status information

* fix status_update for reverse_swaps

* chore: format with black

* more blackformatting and refactoring create_swap()

* fix variable bug

* check if swap is already refunded

* use create_task instead of ensure_future

* add mempool and boltz urls depending on DEBUG .env

* raise exception in mempool fails

* fix onchain txs, sending funds to wrong address and add a refund address for normal swaps beforehand

* add status to swaps, add sorting and data into listing

* add swap status checks, change urls to docker test setup, dynamic minimum and maximum limits

* add wallet name and id, to list and status information

* fix status_update for reverse_swaps

* chore: format with black

* use create_task instead of ensure_future

* add mempool and boltz urls depending on DEBUG .env

* fix onchain txs, sending funds to wrong address and add a refund address for normal swaps beforehand

* black formatting

* add some logging with loguru, and remove function duplication

* cleanup readme

* updates/suggestions from calle

Co-authored-by: calle <93376500+callebtc@users.noreply.github.com>

* remove unused comments

* Update API Endpoints

Co-authored-by: calle <93376500+callebtc@users.noreply.github.com>

* un-factor get_boltz_pairs

* added a explaination for the onchain tx

* remove unused template file

* rename api endpoints

* fix isort and prettier

* more verbose logging!!

* add boltz to mock_data.zip

* new mockdata

* remove comment

* better readme

* fix mempool urls

* change /refund /check /status to post requests

* first step in tests2

* add first tests

* change refund,check,status to post requests

* next try on tests

* overall code improvements

* just testing tests

* throw http exceptions in views_api

* require admincheck for refund,check,status and added fastapi documentation for those

* added more tests

* black

* many code improvements

* adding tests

* temp fix test

* fix race condition when pay_invoice fails

* test are working

* add boltz env variables

* add startup check, bugfixes, improvements

* improve on status checking

* remove check_invoice_status

* more fixes and tests

* testing testing testing

* make tests run again inside regtest

* fix bad error :O

* fix postgres boolean bug and add swap test

* Update README.md

Update README.md

Update README.md

Update README.md

* some mypy

* blacked

* the missing commit?

* fix api_docs readme link

* better refunding error catching

fix

* check swaps now also shows pending reverse swap, ui improvements, tooltips

* add backend check for boltz limits

fixup

* many improvements, startup check for swaps working, reverse needs more testing

* little last fixes

* remove unused logic

* fastapi documentation

fixup

* formatting and remove unused tests

* fix test

* fix swapstatus model

* Update lnbits/extensions/boltz/tasks.py

Co-authored-by: calle <93376500+callebtc@users.noreply.github.com>

* Update lnbits/extensions/boltz/views_api.py

Co-authored-by: calle <93376500+callebtc@users.noreply.github.com>

* balance check msg, format

* fix mypy data override

* fix swapstatus, remove can refund column

* Update lnbits/extensions/boltz/README.md

Co-authored-by: michael1011 <me@michael1011.at>

* empty lines

* fix error message when swap is not found

* remove preimage_hash from database

* fix api_docs html

fix api_docs html

* catch boltz network exceptions better

* formatting

* check for timeout on swap at get request

Co-authored-by: michael1011 <me@michael1011.at>
Co-authored-by: fusion44 <some.fusion@gmail.com>
Co-authored-by: calle <93376500+callebtc@users.noreply.github.com>
2022-08-30 12:51:17 +02:00