Fix: For some reason, the last commit is not updating the webapp on webfaction. This is to try and fix it.
Chore: Bumped the version to 3.3
This commit is contained in:
parent
29653b524a
commit
018391f733
@ -2,8 +2,10 @@ import csv
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
from io import StringIO
|
from io import StringIO
|
||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
from pyramid.renderers import JSON
|
from pyramid.renderers import JSON
|
||||||
|
|
||||||
|
|
||||||
__author__ = 'tanshu'
|
__author__ = 'tanshu'
|
||||||
|
|
||||||
|
|
||||||
@ -35,16 +37,22 @@ class CSVRenderer(object):
|
|||||||
|
|
||||||
json_renderer = JSON()
|
json_renderer = JSON()
|
||||||
|
|
||||||
|
|
||||||
class DecimalAsFloatHack(float):
|
class DecimalAsFloatHack(float):
|
||||||
def __init__(self, d):
|
def __init__(self, d):
|
||||||
self.d = d
|
self.d = d
|
||||||
|
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
# return format(self.d, '.5f')
|
|
||||||
return str(self.d)
|
return str(self.d)
|
||||||
|
|
||||||
|
|
||||||
def decimal_adaptor(obj, request):
|
def decimal_adaptor(obj, request):
|
||||||
return DecimalAsFloatHack(obj)
|
return DecimalAsFloatHack(obj)
|
||||||
|
|
||||||
|
|
||||||
def uuid_adaptor(obj, request):
|
def uuid_adaptor(obj, request):
|
||||||
return str(obj)
|
return str(obj)
|
||||||
|
|
||||||
|
|
||||||
json_renderer.add_adapter(Decimal, decimal_adaptor)
|
json_renderer.add_adapter(Decimal, decimal_adaptor)
|
||||||
json_renderer.add_adapter(uuid.UUID, uuid_adaptor)
|
json_renderer.add_adapter(uuid.UUID, uuid_adaptor)
|
||||||
|
2
setup.py
2
setup.py
@ -15,7 +15,7 @@ requires = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
setup(name='brewman',
|
setup(name='brewman',
|
||||||
version='3.2',
|
version='3.3',
|
||||||
description='brewman',
|
description='brewman',
|
||||||
long_description=README + '\n\n' + CHANGES,
|
long_description=README + '\n\n' + CHANGES,
|
||||||
classifiers=[
|
classifiers=[
|
||||||
|
Loading…
x
Reference in New Issue
Block a user