You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
xmrauctions/core/management/commands/show_mempool.py

18 lines
512 B
Python

import json
from django.core.management.base import BaseCommand
from django.contrib.auth.models import User
from core.monero import AuctionDaemon
from sales.models import ItemSale
class Command(BaseCommand):
help = 'Shows mempool'
def handle(self, *args, **kwargs):
ad = AuctionDaemon()
if ad.connected is False:
raise Exception('Unable to connect to auction daemon RPC endpoint.')
msg = str(ad.daemon.mempool())
self.stdout.write(self.style.SUCCESS(msg))