llama.files.slack package

FileHandler classes that log file uploads to Slack.

Slack API documentation: https://api.slack.com/methods/chat.postMessage https://api.slack.com/messaging/composing/formatting#

(Link to permissions in top right of the above pages.)

class llama.files.slack.RctSlkLmaLVAlertJSON

Bases: llama.files.slack.SlackReceiptLlama

digraph "llama.files.slack.RctSlkLmaLVAlertJSON" { charset="utf-8" splines=ortho bgcolor=none margin=0 rankdir=LR "llama.files.lvalert_json.LVAlertJSON" [label=<{{<B>LVAlertJSON</B>|<I>lvalert.json</I>|EventTriggeredFileHandler<BR/>JSONFile}}>, shape="record", style=filled, target=_top, URL="/llama.files.lvalert_json.html#llama.files.lvalert_json.LVAlertJSON", fillcolor="#cccccc"]; "llama.files.skymap_info.SkymapInfo" [label=<{{<B>SkymapInfo</B>|<I>skymap_info.json</I>|EventTriggeredFileHandler<BR/>JSONFile}}>, shape="record", style=filled, target=_top, URL="/llama.files.skymap_info.html#llama.files.skymap_info.SkymapInfo", fillcolor="#cccccc"]; "llama.files.slack.RctSlkLmaLVAlertJSON" [label=<{{<B>RctSlkLmaLVAlertJSON</B>|<I>rct_slk_lma_lvalert.json.json</I>|SlackReceiptLlama}}>, shape="record", style=filled, target=_top, URL="/llama.files.slack.html#llama.files.slack.RctSlkLmaLVAlertJSON", fillcolor="#cccccc"]; "llama.files.lvalert_json.LVAlertJSON" -> "llama.files.slack.RctSlkLmaLVAlertJSON" [arrowtail="none", color="red", ]; "llama.files.skymap_info.SkymapInfo" -> "llama.files.slack.RctSlkLmaLVAlertJSON" [arrowtail="none", color="red", ]; }

Required input files for llama.files.slack.RctSlkLmaLVAlertJSON (located on the far right of the graph). For a typical trigger, the leftmost files will be generated as triggers become available. They will be used as input for files to their right, eventually allowing llama.files.slack.RctSlkLmaLVAlertJSON to be generated.

DEPENDENCIES = (<class 'llama.files.lvalert_json.LVAlertJSON'>, <class 'llama.files.skymap_info.SkymapInfo'>)
FILENAME = 'rct_slk_lma_lvalert.json.json'
FILENAME_FMT = 'rct_slk_lma_{}.json'
MANIFEST_TYPES = (<class 'llama.files.slack.RctSlkLmaLVAlertJSON'>,)
UPLOAD

alias of llama.files.lvalert_json.LVAlertJSON

UR_DEPENDENCIES = (<class 'llama.files.lvalert_json.LVAlertJSON'>,)
UR_DEPENDENCY_TREE = ImmutableDict({<class 'llama.files.lvalert_json.LVAlertJSON'>: ImmutableDict({})})
class_vetoes = ()
class llama.files.slack.RctSlkLmaLVCInitialXml

Bases: llama.files.slack.SlackReceiptLlama

digraph "llama.files.slack.RctSlkLmaLVCInitialXml" { charset="utf-8" splines=ortho bgcolor=none margin=0 rankdir=LR "llama.files.lvc_gcn_xml.LVCInitialXml" [label=<{{<B>LVCInitialXml</B>|<I>lvc_initial.xml</I>|LVCGcnXml}}>, shape="record", style=filled, target=_top, URL="/llama.files.lvc_gcn_xml.html#llama.files.lvc_gcn_xml.LVCInitialXml", fillcolor="#cccccc"]; "llama.files.skymap_info.SkymapInfo" [label=<{{<B>SkymapInfo</B>|<I>skymap_info.json</I>|EventTriggeredFileHandler<BR/>JSONFile}}>, shape="record", style=filled, target=_top, URL="/llama.files.skymap_info.html#llama.files.skymap_info.SkymapInfo", fillcolor="#cccccc"]; "llama.files.slack.RctSlkLmaLVCInitialXml" [label=<{{<B>RctSlkLmaLVCInitialXml</B>|<I>rct_slk_lma_lvc_initial.xml.json</I>|SlackReceiptLlama}}>, shape="record", style=filled, target=_top, URL="/llama.files.slack.html#llama.files.slack.RctSlkLmaLVCInitialXml", fillcolor="#cccccc"]; "llama.files.lvc_gcn_xml.LVCInitialXml" -> "llama.files.slack.RctSlkLmaLVCInitialXml" [arrowtail="none", color="red", ]; "llama.files.skymap_info.SkymapInfo" -> "llama.files.slack.RctSlkLmaLVCInitialXml" [arrowtail="none", color="red", ]; }

Required input files for llama.files.slack.RctSlkLmaLVCInitialXml (located on the far right of the graph). For a typical trigger, the leftmost files will be generated as triggers become available. They will be used as input for files to their right, eventually allowing llama.files.slack.RctSlkLmaLVCInitialXml to be generated.

DEPENDENCIES = (<class 'llama.files.lvc_gcn_xml.LVCInitialXml'>, <class 'llama.files.skymap_info.SkymapInfo'>)
FILENAME = 'rct_slk_lma_lvc_initial.xml.json'
FILENAME_FMT = 'rct_slk_lma_{}.json'
MANIFEST_TYPES = (<class 'llama.files.slack.RctSlkLmaLVCInitialXml'>,)
UPLOAD

alias of llama.files.lvc_gcn_xml.LVCInitialXml

UR_DEPENDENCIES = (<class 'llama.files.lvc_gcn_xml.LVCInitialXml'>,)
UR_DEPENDENCY_TREE = ImmutableDict({<class 'llama.files.lvc_gcn_xml.LVCInitialXml'>: ImmutableDict({})})
class_vetoes = ()
class llama.files.slack.RctSlkLmaLVCPreliminaryXml

Bases: llama.files.slack.SlackReceiptLlama

digraph "llama.files.slack.RctSlkLmaLVCPreliminaryXml" { charset="utf-8" splines=ortho bgcolor=none margin=0 rankdir=LR "llama.files.lvc_gcn_xml.LVCPreliminaryXml" [label=<{{<B>LVCPreliminaryXml</B>|<I>lvc_preliminary.xml</I>|LVCGcnXml}}>, shape="record", style=filled, target=_top, URL="/llama.files.lvc_gcn_xml.html#llama.files.lvc_gcn_xml.LVCPreliminaryXml", fillcolor="#cccccc"]; "llama.files.skymap_info.SkymapInfo" [label=<{{<B>SkymapInfo</B>|<I>skymap_info.json</I>|EventTriggeredFileHandler<BR/>JSONFile}}>, shape="record", style=filled, target=_top, URL="/llama.files.skymap_info.html#llama.files.skymap_info.SkymapInfo", fillcolor="#cccccc"]; "llama.files.slack.RctSlkLmaLVCPreliminaryXml" [label=<{{<B>RctSlkLmaLVCPreliminaryXml</B>|<I>rct_slk_lma_lvc_preliminary.xml.json</I>|SlackReceiptLlama}}>, shape="record", style=filled, target=_top, URL="/llama.files.slack.html#llama.files.slack.RctSlkLmaLVCPreliminaryXml", fillcolor="#cccccc"]; "llama.files.lvc_gcn_xml.LVCPreliminaryXml" -> "llama.files.slack.RctSlkLmaLVCPreliminaryXml" [arrowtail="none", color="red", ]; "llama.files.skymap_info.SkymapInfo" -> "llama.files.slack.RctSlkLmaLVCPreliminaryXml" [arrowtail="none", color="red", ]; }

Required input files for llama.files.slack.RctSlkLmaLVCPreliminaryXml (located on the far right of the graph). For a typical trigger, the leftmost files will be generated as triggers become available. They will be used as input for files to their right, eventually allowing llama.files.slack.RctSlkLmaLVCPreliminaryXml to be generated.

DEPENDENCIES = (<class 'llama.files.lvc_gcn_xml.LVCPreliminaryXml'>, <class 'llama.files.skymap_info.SkymapInfo'>)
FILENAME = 'rct_slk_lma_lvc_preliminary.xml.json'
FILENAME_FMT = 'rct_slk_lma_{}.json'
MANIFEST_TYPES = (<class 'llama.files.slack.RctSlkLmaLVCPreliminaryXml'>,)
UPLOAD

alias of llama.files.lvc_gcn_xml.LVCPreliminaryXml

UR_DEPENDENCIES = (<class 'llama.files.lvc_gcn_xml.LVCPreliminaryXml'>,)
UR_DEPENDENCY_TREE = ImmutableDict({<class 'llama.files.lvc_gcn_xml.LVCPreliminaryXml'>: ImmutableDict({})})
class_vetoes = ()
class llama.files.slack.RctSlkLmaSkymapInfo

Bases: llama.files.slack.SlackReceiptLlama

digraph "llama.files.slack.RctSlkLmaSkymapInfo" { charset="utf-8" splines=ortho bgcolor=none margin=0 rankdir=LR "llama.files.skymap_info.SkymapInfo" [label=<{{<B>SkymapInfo</B>|<I>skymap_info.json</I>|EventTriggeredFileHandler<BR/>JSONFile}}>, shape="record", style=filled, target=_top, URL="/llama.files.skymap_info.html#llama.files.skymap_info.SkymapInfo", fillcolor="#cccccc"]; "llama.files.slack.RctSlkLmaSkymapInfo" [label=<{{<B>RctSlkLmaSkymapInfo</B>|<I>rct_slk_lma_skymap_info.json.json</I>|SlackReceiptLlama}}>, shape="record", style=filled, target=_top, URL="/llama.files.slack.html#llama.files.slack.RctSlkLmaSkymapInfo", fillcolor="#cccccc"]; "llama.files.skymap_info.SkymapInfo" -> "llama.files.slack.RctSlkLmaSkymapInfo" [arrowtail="none", color="red", ]; }

Required input files for llama.files.slack.RctSlkLmaSkymapInfo (located on the far right of the graph). For a typical trigger, the leftmost files will be generated as triggers become available. They will be used as input for files to their right, eventually allowing llama.files.slack.RctSlkLmaSkymapInfo to be generated.

DEPENDENCIES = (<class 'llama.files.skymap_info.SkymapInfo'>,)
FILENAME = 'rct_slk_lma_skymap_info.json.json'
FILENAME_FMT = 'rct_slk_lma_{}.json'
MANIFEST_TYPES = (<class 'llama.files.slack.RctSlkLmaSkymapInfo'>,)
UPLOAD

alias of llama.files.skymap_info.SkymapInfo

UR_DEPENDENCIES = (<class 'llama.files.skymap_info.SkymapInfo'>,)
UR_DEPENDENCY_TREE = ImmutableDict({<class 'llama.files.skymap_info.SkymapInfo'>: ImmutableDict({})})
class_vetoes = ()
class llama.files.slack.SlackReceipt

Bases: llama.com.utils.UploadReceipt, llama.filehandler.JSONFile

A log file created after an upload attempt to Slack. Use these filehandlers to upload files to slack. Additional vetoes that turn a specific upload receipt off are specified in VETOES.

ORGANIZATION = None
comment

An explanation of this upload FileHandler to be printed to team slack.

classmethod set_class_attributes(subclass)

See UploadReceipt.set_class_attributes; this method first sets the FILENAME_FMT and CLASSNAME_FMT attributes based on subclass.ORGANIZATION. Also adds SkymapInfo to subclass.DEPENDENCIES if it is not already a member and sets class_vetoes to the ones defined for this organization.

upload_title

Print a title for this upload.

class llama.files.slack.SlackReceiptIcecube

Bases: llama.files.slack.SlackReceipt

A SlackReceipt for organization IceCube.

CLASSNAME_FMT = 'RctSlkI3{}'
ORGANIZATION = 'IceCube'
class llama.files.slack.SlackReceiptLlama

Bases: llama.files.slack.SlackReceipt

A SlackReceipt for organization LLAMA.

CLASSNAME_FMT = 'RctSlkLma{}'
ORGANIZATION = 'LLAMA'
llama.files.slack.icecube_upload_flag_false(eventdir)

Return whether a trigger directory has its “ICECUBE_UPLOAD” flag set to “false”.

Submodules