コード例 #1
0
ファイル: goal_runner.py プロジェクト: wolframarnold/pants
 def _maybe_launch_pantsd(self):
     """Launches pantsd if configured to do so."""
     if self._global_options.enable_pantsd:
         # Avoid runtracker output if pantsd is disabled. Otherwise, show up to inform the user its on.
         with self._run_tracker.new_workunit(name='pantsd',
                                             labels=[WorkUnitLabel.SETUP]):
             PantsDaemonLauncher.global_instance().maybe_launch()
コード例 #2
0
ファイル: commands.py プロジェクト: matthewrainville/pants
def pantsd():
  """Launches pantsd with a LocalScheduler instance for testing."""
  scheduler = setup()[0]
  pantsd_launcher = PantsDaemonLauncher.global_instance()
  pantsd_launcher.set_scheduler(scheduler)
  print('*** pantsd {} ***'.format('running' if pantsd_launcher.pantsd.is_alive() else 'launched'))
  pantsd_launcher.maybe_launch()
コード例 #3
0
ファイル: goal_runner.py プロジェクト: dfabulich/pants
 def _maybe_launch_pantsd(self):
     """Launches pantsd if configured to do so."""
     if self._global_options.enable_pantsd:
         # Avoid runtracker output if pantsd is disabled. Otherwise, show up to inform the user its on.
         with self._run_tracker.new_workunit(name="pantsd", labels=[WorkUnitLabel.SETUP]):
             PantsDaemonLauncher.global_instance().maybe_launch()
コード例 #4
0
ファイル: pantsd_kill.py プロジェクト: leloulight/pants
 def execute(self):
     try:
         PantsDaemonLauncher.global_instance().terminate()
     except ProcessManager.NonResponsiveProcess as e:
         raise TaskError("failure while terminating pantsd: {}".format(e))
コード例 #5
0
ファイル: commands.py プロジェクト: jayantak/pants
def maybe_launch_pantsd(options, scheduler):
  if options.for_global_scope().enable_pantsd is True:
    pantsd_launcher = PantsDaemonLauncher.global_instance()
    pantsd_launcher.set_scheduler(scheduler)
    pantsd_launcher.maybe_launch()
コード例 #6
0
ファイル: pantsd_kill.py プロジェクト: wolframarnold/pants
 def execute(self):
     try:
         PantsDaemonLauncher.global_instance().terminate()
     except ProcessManager.NonResponsiveProcess as e:
         raise TaskError('failure while terminating pantsd: {}'.format(e))
コード例 #7
0
ファイル: commands.py プロジェクト: wolframarnold/pants
def maybe_launch_pantsd(options, scheduler):
  if options.for_global_scope().enable_pantsd is True:
    pantsd_launcher = PantsDaemonLauncher.global_instance()
    pantsd_launcher.set_scheduler(scheduler)
    pantsd_launcher.maybe_launch()