mirror of
				https://github.com/python-escpos/python-escpos
				synced 2025-10-23 09:30:00 +00:00 
			
		
		
		
	Fix mypy complains
This commit is contained in:
		@@ -53,7 +53,7 @@ class Network(Escpos):
 | 
			
		||||
 | 
			
		||||
    def __init__(
 | 
			
		||||
        self,
 | 
			
		||||
        host: str = None,
 | 
			
		||||
        host: str = "",
 | 
			
		||||
        port: int = 9100,
 | 
			
		||||
        timeout: Union[int, float] = 60,
 | 
			
		||||
        *args,
 | 
			
		||||
 
 | 
			
		||||
@@ -10,7 +10,7 @@
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
import functools
 | 
			
		||||
from typing import Union
 | 
			
		||||
from typing import Union, Optional
 | 
			
		||||
 | 
			
		||||
from ..escpos import Escpos
 | 
			
		||||
 | 
			
		||||
@@ -78,8 +78,8 @@ class Serial(Escpos):
 | 
			
		||||
        baudrate: int = 9600,
 | 
			
		||||
        bytesize: int = 8,
 | 
			
		||||
        timeout: Union[int, float] = 1,
 | 
			
		||||
        parity=None,  # type: str?
 | 
			
		||||
        stopbits=None,  # type: int?
 | 
			
		||||
        parity: Optional[str] = None,
 | 
			
		||||
        stopbits: Optional[int] = None,
 | 
			
		||||
        xonxoff: bool = False,
 | 
			
		||||
        dsrdtr: bool = True,
 | 
			
		||||
        *args,
 | 
			
		||||
 
 | 
			
		||||
@@ -77,8 +77,8 @@ class Usb(Escpos):
 | 
			
		||||
        idProduct: str = "",
 | 
			
		||||
        usb_args: Dict[str, str] = {},
 | 
			
		||||
        timeout: Union[int, float] = 0,
 | 
			
		||||
        in_ep=0x82,  # type: int?
 | 
			
		||||
        out_ep=0x01,  # type: int?
 | 
			
		||||
        in_ep: int = 0x82,
 | 
			
		||||
        out_ep: int = 0x01,
 | 
			
		||||
        *args,
 | 
			
		||||
        **kwargs
 | 
			
		||||
    ):
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user