Skip to content

feat(misc): Add platform categories for backend code #37894

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Aug 18, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
258 changes: 258 additions & 0 deletions src/sentry/utils/platform_categories.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,258 @@
# Mirrors sentry/static/app/data/platformCategories.tsx
# When changing this file, make sure to keep sentry/static/app/data/platformCategories.tsx in sync.

from django.utils.translation import ugettext_lazy as _

POPULAR_PLATFORM_CATEGORIES = [
"javascript",
"javascript-react",
"javascript-nextjs",
"python-django",
"python",
"python-flask",
"python-fastapi",
"ruby-rails",
"node-express",
"php-laravel",
"java",
"java-spring-boot",
"dotnet",
"dotnet-aspnetcore",
"csharp",
"go",
"php",
"ruby",
"node",
"react-native",
"javascript-angular",
"javascript-vue",
"android",
"apple-ios",
"flutter",
"dart-flutter",
"unity",
]

FRONTEND = [
"dart",
"javascript",
"javascript-react",
"javascript-angular",
"javascript-angularjs",
"javascript-backbone",
"javascript-ember",
"javascript-gatsby",
"javascript-vue",
"javascript-nextjs",
"javascript-remix",
"unity",
]

MOBILE = [
"android",
"apple-ios",
"cordova",
"capacitor",
"javascript-cordova",
"javascript-capacitor",
"ionic",
"react-native",
"flutter",
"dart-flutter",
"unity",
"dotnet-maui",
"dotnet-xamarin",
"unreal",
# Old platforms
"java-android",
"cocoa-objc",
"cocoa-swift",
]

BACKEND = [
"dotnet",
"dotnet-aspnetcore",
"dotnet-aspnet",
"elixir",
"go",
"go-http",
"java",
"java-appengine",
"java-log4j",
"java-log4j2",
"java-logback",
"java-logging",
"java-spring",
"java-spring-boot",
"native",
"node",
"node-express",
"node-koa",
"node-connect",
"perl",
"php",
"php-laravel",
"php-monolog",
"php-symfony2",
"python",
"python-django",
"python-flask",
"python-fastapi",
"python-starlette",
"python-sanic",
"python-celery",
"python-bottle",
"python-pylons",
"python-pyramid",
"python-tornado",
"python-rq",
"ruby",
"ruby-rails",
"ruby-rack",
"rust",
"kotlin",
]

SERVERLESS = [
"python-awslambda",
"python-azurefunctions",
"python-gcpfunctions",
"node-awslambda",
"node-azurefunctions",
"node-gcpfunctions",
"dotnet-awslambda",
"dotnet-gcpfunctions",
]

DESKTOP = [
"apple-macos",
"dotnet",
"dotnet-winforms",
"dotnet-wpf",
"dotnet-maui",
"java",
"electron",
"javascript-electron",
"native",
"native-crashpad",
"native-breakpad",
"native-minidump",
"native-qt",
"minidump",
"unity",
"flutter",
"kotlin",
"unreal",
]

CATEGORY_LIST = [
{id: "popular", "name": _("Popular"), "platforms": POPULAR_PLATFORM_CATEGORIES},
{id: "browser", "name": _("Browser"), "platforms": FRONTEND},
{id: "server", "name": _("Server"), "platforms": BACKEND},
{id: "mobile", "name": _("Mobile"), "platforms": MOBILE},
{id: "desktop", "name": _("Desktop"), "platforms": DESKTOP},
{id: "serverless", "name": _("Serverless"), "platforms": SERVERLESS},
]

SOURCE_MAPS = FRONTEND + [
"react-native",
"cordova",
"electron",
]

TRACING = [
"python-tracing",
"node-tracing",
"react-native-tracing",
]

PERFORMANCE = [
"javascript",
"javascript-ember",
"javascript-react",
"javascript-vue",
"php",
"php-laravel",
"python",
"python-django",
"python-flask",
"python-fastapi",
"python-starlette",
"python-sanic",
"python-celery",
"python-bottle",
"python-pylons",
"python-pyramid",
"python-tornado",
"python-rq",
"node",
"node-express",
"node-koa",
"node-connect",
]

# List of platforms that have performance onboarding checklist content
WITH_PERFORMANCE_ONBOARDING = [
"javascript",
"javascript-react",
]

# List of platforms that do not have performance support. We make use of this list in the product to not provide any Performance
# views such as Performance onboarding checklist.
WITHOUT_PERFORMANCE_SUPPORT = [
"elixir",
"minidump",
]

RELEASE_HEALTH = [
# frontend
"javascript",
"javascript-react",
"javascript-angular",
"javascript-angularjs",
"javascript-backbone",
"javascript-ember",
"javascript-gatsby",
"javascript-vue",
"javascript-nextjs",
"javascript-remix",
# mobile
"android",
"apple-ios",
"cordova",
"javascript-cordova",
"react-native",
"flutter",
"dart-flutter",
# backend
"native",
"node",
"node-express",
"node-koa",
"node-connect",
"python",
"python-django",
"python-flask",
"python-fastapi",
"python-starlette",
"python-sanic",
"python-celery",
"python-bottle",
"python-pylons",
"python-pyramid",
"python-tornado",
"python-rq",
"rust",
# serverless
# desktop
"apple-macos",
"native",
"native-crashpad",
"native-breakpad",
"native-qt",
]

# Additional aliases used for filtering in the platform picker
FILTER_ALIAS = {
"native": ["cpp", "c++"],
}
3 changes: 3 additions & 0 deletions static/app/data/platformCategories.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// Mirrors src/sentry/utils/platform_categories.py
// When changing this file, make sure to keep src/sentry/utils/platform_categories.py in sync.

import {t} from 'sentry/locale';

export const popularPlatformCategories = [
Expand Down