• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Python event_processed.send函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Python中sentry.signals.event_processed.send函数的典型用法代码示例。如果您正苦于以下问题:Python send函数的具体用法?Python send怎么用?Python send使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



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

示例1: test_bulk_create

    def test_bulk_create(self):
        group = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        event = self.create_full_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        javascript = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="javascript"
        )
        assert javascript

        environment_tracking = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="environment_tracking"
        )
        assert environment_tracking

        release_tracking = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="release_tracking"
        )
        assert release_tracking

        feature_complete = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="user_tracking"
        )
        assert feature_complete
开发者ID:yaoqi,项目名称:sentry,代码行数:28,代码来源:test_featureadoption.py


示例2: test_event_processed

    def test_event_processed(self):
        project = self.create_project(first_event=timezone.now())
        event = self.create_full_event()
        event_processed.send(project=project, group=self.group, event=event, sender=type(project))

        task = OrganizationOnboardingTask.objects.get(
            organization=project.organization,
            task=OnboardingTask.RELEASE_TRACKING,
            status=OnboardingTaskStatus.COMPLETE,
        )
        assert task is not None

        task = OrganizationOnboardingTask.objects.get(
            organization=project.organization,
            task=OnboardingTask.USER_CONTEXT,
            status=OnboardingTaskStatus.COMPLETE,
        )
        assert task is not None

        task = OrganizationOnboardingTask.objects.get(
            organization=project.organization,
            task=OnboardingTask.SOURCEMAPS,
            status=OnboardingTaskStatus.COMPLETE,
        )
        assert task is not None
开发者ID:Parthas-Menethil,项目名称:sentry,代码行数:25,代码来源:test_onboarding.py


示例3: test_csp

    def test_csp(self):
        group = self.create_group(project=self.project, platform='csp', message='C# error message')
        event = self.create_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        csp = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="csp")
        assert csp.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:9,代码来源:test_featureadoption.py


示例4: test_go

    def test_go(self):
        group = self.create_group(project=self.project, platform='go', message='go error message')
        event = self.create_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        go = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="go")
        assert go.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:9,代码来源:test_featureadoption.py


示例5: test_node

    def test_node(self):
        group = self.create_group(
            project=self.project, platform='node', message='node error message'
        )
        event = self.create_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        node = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="node")
        assert node.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:11,代码来源:test_featureadoption.py


示例6: test_python

    def test_python(self):
        group = self.create_group(
            project=self.project, platform='python', message='python error message'
        )
        event = self.create_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        python = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="python")
        assert python.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:11,代码来源:test_featureadoption.py


示例7: test_javascript

    def test_javascript(self):
        group = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        event = self.create_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        js = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="javascript")
        assert js.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:11,代码来源:test_featureadoption.py


示例8: test_objc

    def test_objc(self):
        group = self.create_group(
            project=self.project, platform='objc', message='objc error message'
        )
        event = self.create_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        objc = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="objc")
        assert objc.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:11,代码来源:test_featureadoption.py


示例9: test_ruby

    def test_ruby(self):
        group = self.create_group(
            project=self.project, platform='ruby', message='ruby error message'
        )
        event = self.create_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        ruby = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="ruby")
        assert ruby.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:11,代码来源:test_featureadoption.py


示例10: test_breadcrumbs

    def test_breadcrumbs(self):
        group = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        event = self.create_full_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        breadcrumbs = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="breadcrumbs"
        )
        assert breadcrumbs
开发者ID:yaoqi,项目名称:sentry,代码行数:13,代码来源:test_featureadoption.py


示例11: test_environment_tracking

    def test_environment_tracking(self):
        group = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        event = self.create_full_event()
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        environment_tracking = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="environment_tracking"
        )
        assert environment_tracking
开发者ID:yaoqi,项目名称:sentry,代码行数:13,代码来源:test_featureadoption.py


示例12: test_custom_tags

    def test_custom_tags(self):
        group = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        event = self.create_full_event()
        event.data['tags'].append(('foo', 'bar'))
        assert event.get_tag('foo') == 'bar'
        event_processed.send(
            project=self.project, group=group, event=event, sender=type(self.project)
        )

        custom_tags = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="custom_tags"
        )
        assert custom_tags
开发者ID:yaoqi,项目名称:sentry,代码行数:15,代码来源:test_featureadoption.py


示例13: test_multiple_events

    def test_multiple_events(self):
        group = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        simple_event = self.create_event()
        first_event_received.send(project=self.project, group=group, sender=type(self.project))
        event_processed.send(
            project=self.project, group=group, event=simple_event, sender=type(self.project)
        )

        first_event = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="first_event"
        )

        assert first_event.complete

        js = FeatureAdoption.objects.get_by_slug(organization=self.organization, slug="javascript")
        assert js.complete

        full_event = self.create_full_event()
        event_processed.send(
            project=self.project, group=group, event=full_event, sender=type(self.project)
        )

        release_tracking = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="release_tracking"
        )
        assert release_tracking

        environment_tracking = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="environment_tracking"
        )
        assert environment_tracking

        feature_complete = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="user_tracking"
        )
        assert feature_complete

        source_maps = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="source_maps"
        )
        assert source_maps

        breadcrumbs = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="breadcrumbs"
        )
        assert breadcrumbs
开发者ID:yaoqi,项目名称:sentry,代码行数:48,代码来源:test_featureadoption.py


示例14: test_all_passed_feature_slugs_are_complete

    def test_all_passed_feature_slugs_are_complete(self):
        group1 = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        event1 = self.create_full_event()
        group2 = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        event2 = self.create_full_event(event_id='b')
        event_processed.send(
            project=self.project, group=group1, event=event1, sender=type(self.project)
        )
        event_processed.send(
            project=self.project, group=group2, event=event2, sender=type(self.project)
        )

        feature_complete = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="environment_tracking"
        )
        assert feature_complete.complete
开发者ID:yaoqi,项目名称:sentry,代码行数:20,代码来源:test_featureadoption.py


示例15: test_onboarding_complete

    def test_onboarding_complete(self):
        user = self.create_user(email='[email protected]')
        project = self.create_project(first_event=timezone.now())
        second_project = self.create_project(first_event=timezone.now())
        second_group = self.create_group(project=second_project, platform='python', message='python error message')
        event = self.create_full_event()
        member = self.create_member(organization=self.organization, teams=[self.team], user=user)

        event_processed.send(project=project, group=self.group, event=event, sender=type(project))
        project_created.send(project=project, user=user, sender=type(project))
        project_created.send(project=second_project, user=user, sender=type(second_project))

        first_event_received.send(project=project, group=self.group, sender=type(project))
        first_event_received.send(project=second_project, group=second_group, sender=type(second_project))
        member_joined.send(member=member, sender=type(member))
        plugin_enabled.send(plugin=IssueTrackingPlugin(), project=project, user=user, sender=type(IssueTrackingPlugin))
        issue_tracker_used.send(plugin=IssueTrackingPlugin(), project=project, user=user, sender=type(IssueTrackingPlugin))
        plugin_enabled.send(plugin=NotificationPlugin(), project=project, user=user, sender=type(NotificationPlugin))

        assert OrganizationOption.objects.filter(organization=self.organization, key="onboarding:complete").count() == 1
开发者ID:280185386,项目名称:sentry,代码行数:20,代码来源:test_onboarding.py


示例16: test_no_env_tracking

    def test_no_env_tracking(self):
        """test to see if just sending ip address doesn't check the user tracking box"""
        envless_payload = """
            {
                "id": "f5dd88e612bc406ba89dfebd09120769",
                "project": 11276,
                "release": "e1b5d1900526feaf20fe2bc9cad83d392136030a",
                "platform": "javascript",
                "culprit": "app/components/events/eventEntries in map",
                "message": "TypeError: Cannot read property '1' of null",
                "tags": [
                    ["sentry_version", "e1b5d1900526feaf20fe2bc9cad83d392136030a"],
                    ["level", "error"],
                    ["logger", "javascript"],
                    ["sentry:release", "e1b5d1900526feaf20fe2bc9cad83d392136030a"],
                    ["browser", "Chrome 48.0"],
                    ["device", "Other"],
                    ["os", "Windows 10"],
                    ["url", "https://sentry.io/katon-direct/localhost/issues/112734598/"],
                    ["sentry:user", "id:41656"]
                ],
                "errors": [{
                    "url": "<anonymous>",
                    "type": "js_no_source"
                }],
                "extra": {
                    "session:duration": 40364
                },
                "exception": {
                    "exc_omitted": null,
                    "values": [{
                        "stacktrace": {
                            "frames": [{
                                "function": "batchedUpdates",
                                "abs_path": "webpack:////usr/src/getsentry/src/sentry/~/react/lib/ReactUpdates.js",
                                "pre_context": ["  // verify that that's the case. (This is called by each top-level update", "  // function, like setProps, setState, forceUpdate, etc.; creation and", "  // destruction of top-level components is guarded in ReactMount.)", "", "  if (!batchingStrategy.isBatchingUpdates) {"],
                                "post_context": ["    return;", "  }", "", "  dirtyComponents.push(component);", "}"],
                                "filename": "~/react/lib/ReactUpdates.js",
                                "module": "react/lib/ReactUpdates",
                                "colno": 0,
                                "in_app": false,
                                "data": {
                                    "orig_filename": "/_static/29e365f8b0d923bc123e8afa38d890c3/sentry/dist/vendor.js",
                                    "orig_abs_path": "https://media.sentry.io/_static/29e365f8b0d923bc123e8afa38d890c3/sentry/dist/vendor.js",
                                    "sourcemap": "https://media.sentry.io/_static/29e365f8b0d923bc123e8afa38d890c3/sentry/dist/vendor.js.map",
                                    "orig_lineno": 37,
                                    "orig_function": "Object.s [as enqueueUpdate]",
                                    "orig_colno": 16101
                                },
                                "context_line": "    batchingStrategy.batchedUpdates(enqueueUpdate, component);",
                                "lineno": 176
                            }],
                            "frames_omitted": null
                        },
                        "type": "TypeError",
                        "value": "Cannot read property '1' of null",
                        "module": null
                    }]
                },
                "request": {
                    "url": "https://sentry.io/katon-direct/localhost/issues/112734598/",
                    "headers": [
                        ["Referer", "https://sentry.io/welcome/"],
                        ["User-Agent", "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.109 Safari/537.36"]
                    ]
                },
                "user": {
                    "ip_address": "0.0.0.0"
                },
                "version": "7",
                "breadcrumbs": {
                    "values": [
                        {
                            "category": "xhr",
                            "timestamp": 1496395011.63,
                            "type": "http",
                            "data": {
                                "url": "/api/path/here",
                                "status_code": "500",
                                "method": "POST"
                            }
                        }
                    ]
                }
            }"""
        group = self.create_group(
            project=self.project, platform='javascript', message='javascript error message'
        )
        envless_event = self.create_event(
            event_id='a', platform='javascript', data=json.loads(envless_payload)
        )
        event_processed.send(
            project=self.project, group=group, event=envless_event, sender=type(self.project)
        )

        feature_complete = FeatureAdoption.objects.get_by_slug(
            organization=self.organization, slug="environment_tracking"
        )
        assert feature_complete is None
开发者ID:yaoqi,项目名称:sentry,代码行数:99,代码来源:test_featureadoption.py



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Python pending_delete.send函数代码示例发布时间:2022-05-27
下一篇:
Python utils.parse_query函数代码示例发布时间:2022-05-27
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap