Skip to content

Commit

Permalink
feat: update to lnbits 1.0.0 (#19)
Browse files Browse the repository at this point in the history
* feat: update to lnbits 1.0.0
* bye coinflips
* missed a bit
* added tag
* temp hack
* format
* reset min version
* fix: typing update error
* fix multiplier

---------

Co-authored-by: Arc <[email protected]>
Co-authored-by: Tiago Vasconcelos <[email protected]>
  • Loading branch information
3 people authored Nov 27, 2024
1 parent 1392314 commit 9ffe6ee
Show file tree
Hide file tree
Showing 21 changed files with 1,603 additions and 2,681 deletions.
7 changes: 0 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,3 @@

- Gambling in a qrcode
- Pay sats with x chance of winning x

## Coinflips

- Create coinflips, x users pay to join and winner takes all (minus registration fee)

Gambling is dangerous, gamble responsibly.
https://www.gambleaware.org
21 changes: 0 additions & 21 deletions __init__.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
import asyncio

from fastapi import APIRouter
from lnbits.tasks import create_permanent_unique_task
from loguru import logger

from .crud import db
from .tasks import wait_for_paid_invoices
from .views import satsdice_generic_router
from .views_api import satsdice_api_router
from .views_lnurl import satsdice_lnurl_router
Expand All @@ -22,20 +17,4 @@
}
]

scheduled_tasks: list[asyncio.Task] = []


def satsdice_stop():
for task in scheduled_tasks:
try:
task.cancel()
except Exception as ex:
logger.warning(ex)


def satsdice_start():
task = create_permanent_unique_task("ext_satsdice", wait_for_paid_invoices)
scheduled_tasks.append(task)


__all__ = ["db", "satsdice_ext", "satsdice_static_files"]
3 changes: 2 additions & 1 deletion config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
"name": "Sats Dice",
"short_description": "LNURL Satoshi dice",
"tile": "/satsdice/static/image/satsdice.png",
"min_lnbits_version": "0.11.0",
"min_lnbits_version": "1.0.0",
"tags": ["gambling"],
"contributors": [
{
"name": "arcbtc",
Expand Down
Loading

0 comments on commit 9ffe6ee

Please sign in to comment.