On this page
decimal.ConversionSyntax
Prev: decimal.Context | Up: decimal | Next: decimal.Decimal
Rel: decimal.Clamped, decimal.Context, decimal.Decimal, decimal.DecimalException
Ref: docs.python.org โ decimal.ConversionSyntax
Tags: #public #python3 #stdlib #decimal
Import
import decimal
from decimal import ConversionSyntax
Signature & Overview
decimal.ConversionSyntax(...)
decimal.ConversionSyntax class.
Methods & Attributes
ConversionSyntax.add_note(self, note, /)โ Add a note to the exceptionConversionSyntax.with_traceback(self, tb, /)โ Set self.traceback to tb and return self.
Usage
from decimal import ConversionSyntax, Decimal, InvalidOperation
try:
Decimal("not-a-number")
except InvalidOperation:
assert issubclass(ConversionSyntax, InvalidOperation)
Gotchas
- Subclass of
InvalidOperation: Raised when parsing a malformed decimal string.
REPL Inspect
from decimal import ConversionSyntax
help(ConversionSyntax)
Linked from
- tuts/python3/stdlib_module/decimal
- tuts/python3/stdlib_module/decimal/Clamped
- tuts/python3/stdlib_module/decimal/Context
- tuts/python3/stdlib_module/decimal/Decimal
- tuts/python3/stdlib_module/decimal/DecimalException
- tuts/python3/stdlib_module/decimal/DecimalTuple
- tuts/python3/stdlib_module/decimal/DivisionByZero
- tuts/python3/stdlib_module/decimal/DivisionImpossible
- tuts/python3/stdlib_module/decimal/DivisionUndefined
- tuts/python3/stdlib_module/decimal/FloatOperation
- tuts/python3/stdlib_module/decimal/getcontext
- tuts/python3/stdlib_module/decimal/IEEEContext
- tuts/python3/stdlib_module/decimal/Inexact
- tuts/python3/stdlib_module/decimal/InvalidContext
- tuts/python3/stdlib_module/decimal/InvalidOperation
- tuts/python3/stdlib_module/decimal/localcontext
- tuts/python3/stdlib_module/decimal/Overflow
- tuts/python3/stdlib_module/decimal/Rounded
- tuts/python3/stdlib_module/decimal/setcontext
- tuts/python3/stdlib_module/decimal/Subnormal
- tuts/python3/stdlib_module/decimal/Underflow
Related notes
- tuts/python3/stdlib_module/decimal/Clamped Linked here; links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/Context Linked here; links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/Decimal Linked here; links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/DecimalException Linked here; links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/DecimalTuple links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/DivisionByZero links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/DivisionImpossible links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/DivisionUndefined links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/FloatOperation links to this page; shared tags: #decimal, #stdlib
- tuts/python3/stdlib_module/decimal/getcontext links to this page; shared tags: #decimal, #stdlib