This is an automated email from the ASF dual-hosted git repository.

lordgamez pushed a commit to annotated tag rel/minifi-cpp-0.99.2
in repository https://gitbox.apache.org/repos/asf/nifi-minifi-cpp.git

commit d91368332dce7ab3ec87027d3828466ee4e4491d
Author: Gabor Gyimesi <[email protected]>
AuthorDate: Fri Oct 3 10:04:23 2025 +0200

    Review update
---
 extensions/python/pythonprocessors/nifiapi/processorbase.py | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/extensions/python/pythonprocessors/nifiapi/processorbase.py 
b/extensions/python/pythonprocessors/nifiapi/processorbase.py
index 6c89aefd5..1ef376c4a 100644
--- a/extensions/python/pythonprocessors/nifiapi/processorbase.py
+++ b/extensions/python/pythonprocessors/nifiapi/processorbase.py
@@ -15,7 +15,7 @@
 
 from abc import ABC, abstractmethod
 from typing import List
-from .properties import ExpressionLanguageScope, PropertyDescriptor, 
translateStandardValidatorToMiNiFiPropertype
+from .properties import ExpressionLanguageScope, PropertyDescriptor, 
translateStandardValidatorToMiNiFiPropertype, MinifiPropertyTypes
 from .properties import ProcessContext as ProcessContextProxy
 from minifi_native import OutputStream, Processor, ProcessContext, 
ProcessSession
 
@@ -55,11 +55,12 @@ class ProcessorBase(ABC):
 
         for property in self.getPropertyDescriptors():
             expression_language_supported = True if 
property.expressionLanguageScope != ExpressionLanguageScope.NONE else False
-            property_type_code = None
+            property_type_code = 
translateStandardValidatorToMiNiFiPropertype(property.validators)
 
             # MiNiFi C++ does not support validators for expression language 
enabled properties
-            if not expression_language_supported:
-                property_type_code = 
translateStandardValidatorToMiNiFiPropertype(property.validators)
+            if expression_language_supported and property_type_code is not 
None and property_type_code != MinifiPropertyTypes.NON_BLANK_TYPE:
+                self.logger.warn("Property '{}' has validators defined, but 
since it also supports Expression Language, the validators will be 
ignored.".format(property.name))
+                property_type_code = None
 
             # MiNiFi C++ does not support dependant properties, so if a 
property depends on another property, it should not be required
             is_required = True if property.required and not 
property.dependencies else False

Reply via email to