summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel O'Neil2019-02-23 13:25:39 -0500
committerMarcel O'Neil2019-02-23 13:25:39 -0500
commit59e370d5b4e6aa4ae23e4150fdebef90677bf088 (patch)
tree1e30d143ca272b304034eb02e52dbd272055c7e7
parenta26ed2cf89f7a82b626e888afeaad584461a9895 (diff)
downloadaur-59e370d5b4e6aa4ae23e4150fdebef90677bf088.tar.gz
3.3.6
-rw-r--r--.SRCINFO10
-rw-r--r--0001-Qt-Fix-1157-Qt-5.12-also-exports-Decimal.patch124
-rw-r--r--PKGBUILD16
3 files changed, 8 insertions, 142 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 1378228df5fa..58b655193b72 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = electron-cash
pkgdesc = Lightweight Bitcoin Cash wallet
- pkgver = 3.3.5
- pkgrel = 2
+ pkgver = 3.3.6
+ pkgrel = 1
url = http://www.electroncash.org/
arch = any
license = MIT
@@ -34,10 +34,8 @@ pkgbase = electron-cash
optdepends = zbar: QR code reading support
provides = electron-cash
conflicts = electron-cash
- source = electron-cash-3.3.5.tar.gz::https://github.com/Electron-Cash/Electron-Cash/archive/3.3.5.tar.gz
- source = 0001-Qt-Fix-1157-Qt-5.12-also-exports-Decimal.patch
- sha256sums = aa0500a133d93cb24612297b83c7227ee9a66028b2b4e92ea134c69fd9a81623
- sha256sums = 51b7c35e209501002ee585b02c84be2d5daba7a962c86a1b21cca9dd48d4bde7
+ source = electron-cash-3.3.6.tar.gz::https://github.com/Electron-Cash/Electron-Cash/archive/3.3.6.tar.gz
+ sha256sums = 470dc7c200045ffade3bc45aa2ba0042fad0c23b9dfac6a52b7dcb6466c4870f
pkgname = electron-cash
diff --git a/0001-Qt-Fix-1157-Qt-5.12-also-exports-Decimal.patch b/0001-Qt-Fix-1157-Qt-5.12-also-exports-Decimal.patch
deleted file mode 100644
index f9aa2bd28719..000000000000
--- a/0001-Qt-Fix-1157-Qt-5.12-also-exports-Decimal.patch
+++ /dev/null
@@ -1,124 +0,0 @@
-From 432edfd6a690db744667ed72e1333c709e6d84e6 Mon Sep 17 00:00:00 2001
-From: Calin Culianu <calin.culianu@gmail.com>
-Date: Thu, 14 Feb 2019 02:38:55 +0200
-Subject: [PATCH] [Qt] Fix #1157 -- Qt 5.12 also exports Decimal
-
-So we had to rename decimal.Decimal to PyDecimal where we use it.
-
-The other alternative was to not import PyQt5.QtCore.* ... but... it's
-super convenient to have access to all of Qt. So, instead we import
-decimal.Decimal as PyDecimal
----
- RELEASE-NOTES | 1 +
- gui/qt/amountedit.py | 8 ++++----
- gui/qt/main_window.py | 6 +++---
- gui/qt/paytoedit.py | 4 ++--
- 4 files changed, 10 insertions(+), 9 deletions(-)
-
-# Don't patch release notes
-# diff --git a/RELEASE-NOTES b/RELEASE-NOTES
-# index 23658a42..e2707ea3 100644
-# --- a/RELEASE-NOTES
-# +++ b/RELEASE-NOTES
-# @@ -269,3 +269,4 @@ and there is no warning message.
-# * Android fixes (mhsmith)
-# * Various internal bugfixes and code refactoring (cculianu, ecdsa, SomberNight)
-# * servers.json updated (torusJKL)
-# +* Fixed a compatibility issue with Qt 5.12 (SomberNight, cculianu)
-
-diff --git a/gui/qt/amountedit.py b/gui/qt/amountedit.py
-index 97b53428..fdb647cd 100644
---- a/gui/qt/amountedit.py
-+++ b/gui/qt/amountedit.py
-@@ -4,7 +4,7 @@ from PyQt5.QtCore import *
- from PyQt5.QtGui import *
- from PyQt5.QtWidgets import (QLineEdit, QStyle, QStyleOptionFrame)
-
--from decimal import Decimal
-+from decimal import Decimal as PyDecimal # Qt 5.12 also exports Decimal
- from electroncash.util import format_satoshis_plain
-
-
-@@ -65,7 +65,7 @@ class AmountEdit(MyLineEdit):
-
- def get_amount(self):
- try:
-- return (int if self.is_int else Decimal)(str(self.text()))
-+ return (int if self.is_int else PyDecimal)(str(self.text()))
- except:
- return None
-
-@@ -89,7 +89,7 @@ class BTCAmountEdit(AmountEdit):
-
- def get_amount(self):
- try:
-- x = Decimal(str(self.text()))
-+ x = PyDecimal(str(self.text()))
- except:
- return None
- p = pow(10, self.decimal_point())
-@@ -112,7 +112,7 @@ class BTCSatsByteEdit(BTCAmountEdit):
- return 'sats' + '/B'
- def get_amount(self):
- try:
-- x = float(Decimal(str(self.text())))
-+ x = float(PyDecimal(str(self.text())))
- except:
- return None
- return x if x > 0.0 else None
-diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py
-index e07739a1..f6fac935 100644
---- a/gui/qt/main_window.py
-+++ b/gui/qt/main_window.py
-@@ -28,7 +28,7 @@ import os, json, traceback
- import shutil
- import webbrowser
- import csv
--from decimal import Decimal
-+from decimal import Decimal as PyDecimal # Qt 5.12 also exports Decimal
- import base64
- from functools import partial
-
-@@ -695,7 +695,7 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError):
- else:
- if edit is fiat_e:
- btc_e.follows = True
-- btc_e.setAmount(int(amount / Decimal(rate) * COIN))
-+ btc_e.setAmount(int(amount / PyDecimal(rate) * COIN))
- btc_e.setStyleSheet(ColorScheme.BLUE.as_stylesheet())
- btc_e.follows = False
- if fee_e:
-@@ -703,7 +703,7 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError):
- else:
- fiat_e.follows = True
- fiat_e.setText(self.fx.ccy_amount_str(
-- amount * Decimal(rate) / COIN, False))
-+ amount * PyDecimal(rate) / COIN, False))
- fiat_e.setStyleSheet(ColorScheme.BLUE.as_stylesheet())
- fiat_e.follows = False
-
-diff --git a/gui/qt/paytoedit.py b/gui/qt/paytoedit.py
-index 261fcd26..ecc0d2e4 100644
---- a/gui/qt/paytoedit.py
-+++ b/gui/qt/paytoedit.py
-@@ -29,7 +29,7 @@ from PyQt5.QtWidgets import QCompleter, QPlainTextEdit
- from .qrtextedit import ScanQRTextEdit
-
- import re
--from decimal import Decimal
-+from decimal import Decimal as PyDecimal # Qt 5.12 also exports Decimal
- from electroncash import bitcoin
- from electroncash.address import Address, ScriptOutput
- from electroncash import networks
-@@ -97,7 +97,7 @@ class PayToEdit(ScanQRTextEdit):
- if x.strip() == '!':
- return '!'
- p = pow(10, self.amount_edit.decimal_point())
-- return int(p * Decimal(x.strip()))
-+ return int(p * PyDecimal(x.strip()))
-
- def check_text(self):
- self.errors = []
---
-2.20.1
-
diff --git a/PKGBUILD b/PKGBUILD
index 0112ce542c60..8034b5b6efdd 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -6,8 +6,8 @@
pkgname='electron-cash'
pkgdesc='Lightweight Bitcoin Cash wallet'
-pkgver=3.3.5
-pkgrel=2
+pkgver=3.3.6
+pkgrel=1
url='http://www.electroncash.org/'
arch=('any')
license=('MIT')
@@ -46,15 +46,8 @@ optdepends=(
)
provides=("${pkgname}")
conflicts=("${pkgname}")
-source=("${pkgname}-${pkgver}.tar.gz::https://github.com/Electron-Cash/Electron-Cash/archive/${pkgver/.0}.tar.gz"
- "0001-Qt-Fix-1157-Qt-5.12-also-exports-Decimal.patch")
-sha256sums=('aa0500a133d93cb24612297b83c7227ee9a66028b2b4e92ea134c69fd9a81623'
- '51b7c35e209501002ee585b02c84be2d5daba7a962c86a1b21cca9dd48d4bde7')
-prepare() {
- cd "Electron-Cash-${pkgver/.0}"
-
- patch -Np1 -i "${srcdir}/0001-Qt-Fix-1157-Qt-5.12-also-exports-Decimal.patch"
-}
+source=("${pkgname}-${pkgver}.tar.gz::https://github.com/Electron-Cash/Electron-Cash/archive/${pkgver/.0}.tar.gz")
+sha256sums=('470dc7c200045ffade3bc45aa2ba0042fad0c23b9dfac6a52b7dcb6466c4870f')
build() {
cd "Electron-Cash-${pkgver/.0}"
@@ -83,5 +76,4 @@ package() {
python setup.py install --root="${pkgdir}" --optimize=1
}
-
# vim: ts=2 sw=2 et: