Home | History | Annotate | Download | only in scripts

Lines Matching refs:bot

7 A copy of this file is downloaded to every swarming bot automatically.
11 - bot has eurtest_libs installed via: cipd install home_internal/eurtest_libs
15 - get_*() to return properties to describe this bot.
16 - on_*() as hooks based on events happening on the bot.
35 # each bot must be run in a virtualenv that has eurtest_libs in PYTHONPATH
47 # Unused argument 'bot' - pylint: disable=W0613
69 ### home-demo pool ### - enforced via bot name prefix
175 def get_dimensions(bot):
177 """Returns dict with the bot's dimensions.
178 The dimensions are what are used to select the bot that can run each task.
179 The bot id will be automatically selected based on the hostname with
183 (extracted from bots.cfg config file based on the bot id). Server defined
184 dimensions override the ones provided by the bot. See bot.Bot.dimensions for
188 - bot: bot.Bot instance or None. See ../api/bot.py.
191 # The bot base directory is formatted like <HOME>/bots/<Id>
194 os.path.basename(bot.base_dir))
217 def get_state(bot):
219 """Returns dict with a state of the bot reported to the server with each poll.
220 It is only for dynamic state that changes while bot is running for information
227 - bot: bot.Bot instance or None. See ../api/bot.py.
241 def get_authentication_headers(bot):
244 server (and only Swarming server). The bot will use the returned headers until
248 Can be used to implement per-bot authentication. If no headers are returned,
249 the server will use only IP whitelist for bot authentication.
256 - bot: bot.Bot instance. See ../api/bot.py.
267 def on_bot_shutdown(bot):
268 """Hook function called when the bot shuts down, usually rebooting.
271 - bot: bot.Bot instance. See ../api/bot.py.
276 def on_handshake(bot):
277 """Hook function called when the bot starts, after handshake with the server.
278 Here the bot already knows server enforced dimensions (defined in server side
284 - bot: bot.Bot instance. See ../api/bot.py.
289 def on_before_task(bot, bot_file):
294 - bot: bot.Bot instance. See ../api/bot.py.
295 - bot_file: Path to file to write information about the state of the bot.
296 This file can be used to pass certain info about the bot
301 json.dump(bot.dimensions, f)
304 def on_after_task(bot, failure, internal_failure, dimensions, summary):
310 - bot: bot.Bot instance. See ../api/bot.py.
318 # bot.restart('Task failure')
320 # bot.restart('Internal failure')
323 def on_bot_idle(bot, since_last_action):
324 """Hook function called once when the bot has been idle; when it has no
336 - bot: bot.Bot instance. See ../api/bot.py.
338 bot has been idle.