Skip to content

Commit

Permalink
Replace NamedTuple with plain class (#267)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamchainz committed Aug 16, 2023
1 parent 97aebb7 commit da9b455
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/blacken_docs/__init__.py
Expand Up @@ -6,7 +6,6 @@
import textwrap
from typing import Generator
from typing import Match
from typing import NamedTuple
from typing import Sequence

import black
Expand Down Expand Up @@ -88,9 +87,10 @@
TRAILING_NL_RE = re.compile(r"\n+\Z", re.MULTILINE)


class CodeBlockError(NamedTuple):
offset: int
exc: Exception
class CodeBlockError:
def __init__(self, offset: int, exc: Exception) -> None:
self.offset = offset
self.exc = exc


def format_str(
Expand Down

0 comments on commit da9b455

Please sign in to comment.