Skip to content
Snippets Groups Projects
Commit 1cc03e38 authored by André Anjos's avatar André Anjos :speech_balloon:
Browse files

Merge branch '12-example-in-documentation-does-not-work' into 'master'

Fixed documentation and preovided default value for database in JobManager

Closes #12 

Fixed it.

See merge request !2
parents 9ade1d13 95724925
No related branches found
No related tags found
1 merge request!2Fixed documentation and preovided default value for database in JobManager
Pipeline #
......@@ -15,10 +15,10 @@ submit a python script:
.. code-block:: python
import sys
from gridtk.sge import JobManager
from gridtk.sge import JobManagerSGE
from gridtk.tools import make_shell
manager = JobManager()
manager = JobManagerSGE()
command = make_shell(sys.executable, ['myscript.py', '--help'])
job = manager.submit(command)
......
......@@ -15,7 +15,7 @@ from distutils.version import LooseVersion
class JobManager:
"""This job manager defines the basic interface for handling jobs in the SQL database."""
def __init__(self, database, wrapper_script = None, debug = False):
def __init__(self, database = 'submitted.sql3', wrapper_script = None, debug = False):
self._database = os.path.realpath(database)
self._engine = sqlalchemy.create_engine("sqlite:///"+self._database, connect_args={'timeout': 600}, echo=debug)
self._session_maker = sqlalchemy.orm.sessionmaker(bind=self._engine)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment