mirror of
				https://github.com/onyx-and-iris/vban-cmd-python.git
				synced 2025-11-03 23:11:48 +00:00 
			
		
		
		
	check vban direction
check that index is numeric remove button as possible key. not defined in RT packets anyway patch bump
This commit is contained in:
		
							parent
							
								
									f9bcbfa74a
								
							
						
					
					
						commit
						79260a0e47
					
				@ -94,6 +94,7 @@ def main():
 | 
			
		||||
            {
 | 
			
		||||
                "strip-2": {"A1": True, "B1": True, "gain": -6.0},
 | 
			
		||||
                "bus-2": {"mute": True, "eq": {"on": True}},
 | 
			
		||||
                "vban-in-0": {"on": True},
 | 
			
		||||
            }
 | 
			
		||||
        )
 | 
			
		||||
 | 
			
		||||
@ -355,6 +356,7 @@ vban.apply(
 | 
			
		||||
        "strip-0": {"A1": True, "B1": True, "gain": -6.0},
 | 
			
		||||
        "bus-1": {"mute": True, "mode": "composite"},
 | 
			
		||||
        "bus-2": {"eq": {"on": True}},
 | 
			
		||||
        "vban-in-0": {"on": True},
 | 
			
		||||
    }
 | 
			
		||||
)
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
@ -37,6 +37,7 @@ def main():
 | 
			
		||||
            {
 | 
			
		||||
                "strip-2": {"A1": True, "B1": True, "gain": -6.0},
 | 
			
		||||
                "bus-2": {"mute": True},
 | 
			
		||||
                "vban-in-0": {"on": True},
 | 
			
		||||
            }
 | 
			
		||||
        )
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -1,6 +1,6 @@
 | 
			
		||||
[tool.poetry]
 | 
			
		||||
name = "vban-cmd"
 | 
			
		||||
version = "2.4.7"
 | 
			
		||||
version = "2.4.8"
 | 
			
		||||
description = "Python interface for the VBAN RT Packet Service (Sendtext)"
 | 
			
		||||
authors = ["onyx-and-iris <code@onyxandiris.online>"]
 | 
			
		||||
license = "MIT"
 | 
			
		||||
 | 
			
		||||
@ -184,10 +184,16 @@ class VbanCmd(metaclass=ABCMeta):
 | 
			
		||||
 | 
			
		||||
        def target(key):
 | 
			
		||||
            match key.split("-"):
 | 
			
		||||
                case ["strip" | "bus" | "button" as kls, index]:
 | 
			
		||||
                case ["strip" | "bus" as kls, index] if index.isnumeric():
 | 
			
		||||
                    target = getattr(self, kls)
 | 
			
		||||
                case ["vban", direction, index]:
 | 
			
		||||
                    target = getattr(self.vban, f"{direction.rstrip('stream')}stream")
 | 
			
		||||
                case [
 | 
			
		||||
                    "vban",
 | 
			
		||||
                    "in" | "instream" | "out" | "outstream" as direction,
 | 
			
		||||
                    index,
 | 
			
		||||
                ] if index.isnumeric():
 | 
			
		||||
                    target = getattr(
 | 
			
		||||
                        self.vban, f"{direction.removesuffix('stream')}stream"
 | 
			
		||||
                    )
 | 
			
		||||
                case _:
 | 
			
		||||
                    ERR_MSG = f"invalid config key '{key}'"
 | 
			
		||||
                    self.logger.error(ERR_MSG)
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user