1
0
mirror of https://github.com/gsi-upm/senpy synced 2025-08-24 02:22:20 +00:00

Add CI/CD and k8s

This commit is contained in:
J. Fernando Sánchez
2018-06-15 09:46:15 +02:00
parent 62142482dc
commit 54da48b548
7 changed files with 118 additions and 15 deletions

View File

@@ -1,9 +1,6 @@
from senpy.plugins import Analysis
from senpy.models import Response, Entry
import logging
logger = logging.getLogger(__name__)
class ExamplePlugin(Analysis):
'''A *VERY* simple plugin that exemplifies the development of Senpy Plugins'''
@@ -21,8 +18,8 @@ class ExamplePlugin(Analysis):
custom_attribute = "42"
def analyse_entry(self, entry, params):
logger.debug('Analysing with the example.')
logger.debug('The answer to this response is: %s.' % params['parameter'])
self.log.debug('Analysing with the example.')
self.log.debug('The answer to this response is: %s.' % params['parameter'])
resp = Response()
entry['example:reversed'] = entry.text[::-1]
entry['example:the_answer'] = params['parameter']