From 6b631111d19171bb91ef50d64cd398a3e9ffef1c Mon Sep 17 00:00:00 2001 From: calle <93376500+callebtc@users.noreply.github.com> Date: Mon, 3 Apr 2023 20:52:14 +0200 Subject: [PATCH] Fix/ln unsuccessful payment (#159) * throws error for unsuccessful payment so that wallets get error message * bump to 0.11.2 --- README.md | 2 +- cashu/core/settings.py | 2 +- cashu/mint/ledger.py | 2 ++ pyproject.toml | 2 +- setup.py | 2 +- 5 files changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 9c6ea01..b9cdda0 100644 --- a/README.md +++ b/README.md @@ -115,7 +115,7 @@ cashu info Returns: ```bash -Version: 0.11.1 +Version: 0.11.2 Debug: False Cashu dir: /home/user/.cashu Wallet: wallet diff --git a/cashu/core/settings.py b/cashu/core/settings.py index bc4628b..5bd1886 100644 --- a/cashu/core/settings.py +++ b/cashu/core/settings.py @@ -8,7 +8,7 @@ from pydantic import BaseSettings, Extra, Field, validator env = Env() -VERSION = "0.11.1" +VERSION = "0.11.2" def find_env_file(): diff --git a/cashu/mint/ledger.py b/cashu/mint/ledger.py index 4b66a6b..5420ba6 100644 --- a/cashu/mint/ledger.py +++ b/cashu/mint/ledger.py @@ -614,6 +614,8 @@ class Ledger: ln_fee_msat=fee_msat, outputs=outputs, ) + else: + raise Exception("Lightning payment unsuccessful.") except Exception as e: raise e diff --git a/pyproject.toml b/pyproject.toml index 439fdb2..4913333 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "cashu" -version = "0.11.1" +version = "0.11.2" description = "Ecash wallet and mint." authors = ["calle "] license = "MIT" diff --git a/setup.py b/setup.py index b4ee7e6..47bf67d 100644 --- a/setup.py +++ b/setup.py @@ -13,7 +13,7 @@ entry_points = {"console_scripts": ["cashu = cashu.wallet.cli.cli:cli"]} setuptools.setup( name="cashu", - version="0.11.1", + version="0.11.2", description="Ecash wallet and mint for Bitcoin Lightning", long_description=long_description, long_description_content_type="text/markdown",