cwltool.validate_js
===================

.. py:module:: cwltool.validate_js


Classes
-------

.. autoapisummary::

   cwltool.validate_js.SuppressLog
   cwltool.validate_js.JSHintJSReturn


Functions
---------

.. autoapisummary::

   cwltool.validate_js.is_expression
   cwltool.validate_js.get_expressions
   cwltool.validate_js.jshint_js
   cwltool.validate_js.print_js_hint_messages
   cwltool.validate_js.validate_js_expressions


Module Contents
---------------

.. py:function:: is_expression(tool, schema)

   Test a field/schema combo to see if it is a CWL Expression.


.. py:class:: SuppressLog(name)

   Bases: :py:obj:`logging.Filter`

   .. autoapi-inheritance-diagram:: cwltool.validate_js.SuppressLog
      :parts: 1


   Filter instances are used to perform arbitrary filtering of LogRecords.

   Loggers and Handlers can optionally use Filter instances to filter
   records as desired. The base filter class only allows events which are
   below a certain point in the logger hierarchy. For example, a filter
   initialized with "A.B" will allow events logged by loggers "A.B",
   "A.B.C", "A.B.C.D", "A.B.D" etc. but not "A.BB", "B.A.B" etc. If
   initialized with the empty string, all events are passed.


   .. py:method:: filter(record)

      Never accept a record.



.. py:function:: get_expressions(tool, schema, source_line = None)

.. py:class:: JSHintJSReturn

   Bases: :py:obj:`NamedTuple`

   .. autoapi-inheritance-diagram:: cwltool.validate_js.JSHintJSReturn
      :parts: 1


   List of errors and the final values of the globals from running javascript.


   .. py:attribute:: errors
      :type:  list[str]


   .. py:attribute:: globals
      :type:  list[str]


.. py:function:: jshint_js(js_text, globals = None, options = None, container_engine = 'docker', eval_timeout = 60)

.. py:function:: print_js_hint_messages(js_hint_messages, source_line)

   Log the message from JSHint, using the line number.


.. py:function:: validate_js_expressions(tool, schema, jshint_options = None, container_engine = 'docker', eval_timeout = 60)

