mirror of
				https://github.com/python-kasa/python-kasa.git
				synced 2025-11-03 22:22:06 +00:00 
			
		
		
		
	Update readme fixture checker and readme (#699)
This commit is contained in:
		@@ -282,11 +282,13 @@ At the moment, the following devices have been confirmed to work:
 | 
			
		||||
#### Plugs
 | 
			
		||||
 | 
			
		||||
* Tapo P110
 | 
			
		||||
* Tapo P125M
 | 
			
		||||
* Tapo P135 (dimming not yet supported)
 | 
			
		||||
 | 
			
		||||
#### Bulbs
 | 
			
		||||
 | 
			
		||||
* Tapo L510B
 | 
			
		||||
* Tapo L510E
 | 
			
		||||
* Tapo L530E
 | 
			
		||||
 | 
			
		||||
#### Light strips
 | 
			
		||||
@@ -334,7 +336,7 @@ use it directly you should expect it could break in future releases until this s
 | 
			
		||||
Other TAPO libraries are:
 | 
			
		||||
 | 
			
		||||
* [PyTapo - Python library for communication with Tapo Cameras](https://github.com/JurajNyiri/pytapo)
 | 
			
		||||
* [Tapo P100 (Tapo P105/P100 plugs, Tapo L510E bulbs)](https://github.com/fishbigger/TapoP100)
 | 
			
		||||
* [Tapo P100 (Tapo plugs, Tapo bulbs)](https://github.com/fishbigger/TapoP100)
 | 
			
		||||
  * [Home Assistant integration](https://github.com/fishbigger/HomeAssistant-Tapo-P100-Control)
 | 
			
		||||
* [plugp100, another tapo library](https://github.com/petretiandrea/plugp100)
 | 
			
		||||
  * [Home Assistant integration](https://github.com/petretiandrea/home-assistant-tapo-p100)
 | 
			
		||||
 
 | 
			
		||||
@@ -1,4 +1,5 @@
 | 
			
		||||
"""Script that checks if README.md is missing devices that have fixtures."""
 | 
			
		||||
import re
 | 
			
		||||
import sys
 | 
			
		||||
 | 
			
		||||
from kasa.tests.conftest import (
 | 
			
		||||
@@ -32,10 +33,11 @@ def _get_device_type(dev, typemap):
 | 
			
		||||
 | 
			
		||||
found_unlisted = False
 | 
			
		||||
for dev in ALL_DEVICES:
 | 
			
		||||
    if dev not in readme:
 | 
			
		||||
    regex = rf"^\*.*\s{dev}"
 | 
			
		||||
    match = re.search(regex, readme, re.MULTILINE)
 | 
			
		||||
    if match is None:
 | 
			
		||||
        print(f"{dev} not listed in {_get_device_type(dev, typemap)}")
 | 
			
		||||
        found_unlisted = True
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
if found_unlisted:
 | 
			
		||||
    sys.exit(-1)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user