当前位置: 首页>>代码示例>>Python>>正文


Python Release.get方法代码示例

本文整理汇总了Python中sentry.models.Release.get方法的典型用法代码示例。如果您正苦于以下问题:Python Release.get方法的具体用法?Python Release.get怎么用?Python Release.get使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在sentry.models.Release的用法示例。


在下文中一共展示了Release.get方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: get_release

# 需要导入模块: from sentry.models import Release [as 别名]
# 或者: from sentry.models.Release import get [as 别名]
    def get_release(self, project, data):
        if not data.get('release'):
            return

        return Release.get(
            project=project,
            version=data['release'],
        )
开发者ID:haojiang1,项目名称:sentry,代码行数:10,代码来源:processor.py

示例2: preprocess_step

# 需要导入模块: from sentry.models import Release [as 别名]
# 或者: from sentry.models.Release import get [as 别名]
    def preprocess_step(self, processing_task):
        frames = self.get_valid_frames()
        if not frames:
            logger.debug('Event %r has no frames with enough context to '
                         'fetch remote source', self.data['event_id'])
            return False

        if self.data.get('release'):
            self.release = Release.get(
                project=self.project,
                version=self.data['release'],
            )
        self.populate_source_cache(frames)
        return True
开发者ID:rlugojr,项目名称:sentry,代码行数:16,代码来源:processor.py

示例3: get_release

# 需要导入模块: from sentry.models import Release [as 别名]
# 或者: from sentry.models.Release import get [as 别名]
 def get_release(self, create=False):
     """Convenient helper to return the release for the current data
     and optionally creates the release if it's missing.  In case there
     is no release info it will return `None`.
     """
     release = self.data.get('release')
     if not release:
         return None
     if not create:
         return Release.get(project=self.project, version=self.data['release'])
     timestamp = self.data.get('timestamp')
     if timestamp is not None:
         date = datetime.fromtimestamp(timestamp).replace(tzinfo=timezone.utc)
     else:
         date = None
     return Release.get_or_create(
         project=self.project,
         version=self.data['release'],
         date_added=date,
     )
开发者ID:getsentry,项目名称:sentry,代码行数:22,代码来源:processing.py

示例4: get_release

# 需要导入模块: from sentry.models import Release [as 别名]
# 或者: from sentry.models.Release import get [as 别名]
    def get_release(self, project, data):
        if not data.get("release"):
            return

        return Release.get(project=project, version=data["release"])
开发者ID:keimlink,项目名称:sentry,代码行数:7,代码来源:processor.py


注:本文中的sentry.models.Release.get方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。