From eedd0b1d62c9ba4d964c01ca9737bf0385dca0f2 Mon Sep 17 00:00:00 2001 From: rudolfkoenig <> Date: Tue, 20 Oct 2020 09:12:13 +0000 Subject: [PATCH] 98_autocreate.pm: ignoreTypes is checked for type:name too (Forum #115128) git-svn-id: https://svn.fhem.de/fhem/trunk@22996 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/98_autocreate.pm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/fhem/FHEM/98_autocreate.pm b/fhem/FHEM/98_autocreate.pm index da787d977..c37d19e0a 100644 --- a/fhem/FHEM/98_autocreate.pm +++ b/fhem/FHEM/98_autocreate.pm @@ -136,6 +136,7 @@ autocreate_Notify($$) $it = "^$it\$" if($featurelevel > 5.8); # Forum #80775 next if($it && $name =~ m/$it/i); + next if($it && "$type:$name" =~ m/$it/i); my $at = AttrVal($me, "autocreateThreshold", undef); LoadModule($type) if( !$at ); @@ -810,11 +811,11 @@ autocreate_Attr(@) This is a regexp, to ignore certain devices, e.g. the neighbours FHT. You can specify more than one, with usual regexp syntax, e.g.
attr autocreate ignoreTypes (CUL_HOERMANN.*|FHT_1234|CUL_WS_7)
- The word "Types" is somehow misleading, as it actually checks the - generated device name.
+ The word "Types" is somehow misleading, as it first checks the + generated device name, and then the type:name pair.
Note: starting with featurelevel 5.8 the regexp is automatically - extended with ^ and $, so that it must match the whole name (same - procedure as in notify and FileLog). + extended with ^ and $, so that it must match the whole name or + type:name (same procedure as in notify and FileLog).
@@ -977,8 +978,8 @@ autocreate_Attr(@) mehr als ein Gerät über die normale Regexp-Syntax angegeben werden. Beispiel:
attr autocreate ignoreTypes (CUL_HOERMANN.*|FHT_1234|CUL_WS_7)
- Das Wort "Types" ist etwas irreführend, da der Gerätename - geprüft wird, und nicht der Typ.
+ Das Wort "Types" ist etwas irreführend, da erst der Gerätename + geprüft wird, und dann der Konstrukt Typ:Gerätename.
Achtung: ab featurelevel 5.8 wird der Regexp automatisch mit ^ und $ ergänzt, muss also den kompletten Namen matchen (genau wie bei notify und FileLog).