Skip to content

armgit / plane

Public Imported from GitHub
0

πŸ”₯πŸ”₯πŸ”₯ Open-source Jira, Linear, Monday, and ClickUp alternative. Plane is a modern project management platform to manage tasks, sprints, docs, and triage.

fix: remove localdb tracing

sriram veeraghanta4652ad0fc3a5
diff --git a/web/core/local-db/storage.sqlite.ts b/web/core/local-db/storage.sqlite.ts
index 12f918293c..155926ba7e 100644
--- a/web/core/local-db/storage.sqlite.ts
+++ b/web/core/local-db/storage.sqlite.ts
@@ -1,4 +1,3 @@
-import { getActiveSpan, startSpan } from "@sentry/nextjs";
import * as Comlink from "comlink";
import set from "lodash/set";
// plane
@@ -77,7 +76,7 @@ export class Storage {
}
try {
- await startSpan({ name: "INIT_DB" }, async () => await this._initialize(workspaceSlug));
+ await this._initialize(workspaceSlug);
return true;
} catch (err) {
logError(err);
@@ -139,11 +138,9 @@ export class Storage {
return;
}
try {
- await startSpan({ name: "LOAD_WS", attributes: { slug: this.workspaceSlug } }, async () => {
- this.setOption("sync_workspace", new Date().toUTCString());
- await loadWorkSpaceData(this.workspaceSlug);
- this.deleteOption("sync_workspace");
- });
+ this.setOption("sync_workspace", new Date().toUTCString());
+ await loadWorkSpaceData(this.workspaceSlug);
+ this.deleteOption("sync_workspace");
} catch (e) {
logError(e);
this.deleteOption("sync_workspace");
@@ -177,7 +174,7 @@ export class Storage {
return false;
}
try {
- const sync = startSpan({ name: `SYNC_ISSUES` }, () => this._syncIssues(projectId));
+ const sync = this._syncIssues(projectId);
this.setSync(projectId, sync);
await sync;
} catch (e) {
@@ -187,8 +184,6 @@ export class Storage {
};
_syncIssues = async (projectId: string) => {
- const activeSpan = getActiveSpan();
-
log("### Sync started");
let status = this.getStatus(projectId);
if (status === "loading" || status === "syncing") {
@@ -248,11 +243,6 @@ export class Storage {
this.setOption(projectId, "ready");
this.setStatus(projectId, "ready");
this.setSync(projectId, undefined);
-
- activeSpan?.setAttributes({
- projectId: projectId,
- count: response?.total_results,
- });
};
getIssueCount = async (projectId: string) => {
@@ -313,10 +303,7 @@ export class Storage {
let issuesRaw: any[] = [];
let count: any[];
try {
- [issuesRaw, count] = await startSpan(
- { name: "GET_ISSUES" },
- async () => await Promise.all([runQuery(query), runQuery(countQuery)])
- );
+ [issuesRaw, count] = await Promise.all([runQuery(query), runQuery(countQuery)]);
} catch (e) {
logError(e);
const issueService = new IssueService();
@@ -372,18 +359,6 @@ export class Storage {
next_page_results,
total_pages,
};
-
- const activeSpan = getActiveSpan();
- activeSpan?.setAttributes({
- projectId,
- count: total_count,
- groupBy: group_by,
- subGroupBy: sub_group_by,
- queries: queries,
- local: true,
- groupCount,
- // subGroupCount,
- });
return out;
};
diff --git a/web/core/local-db/utils/utils.ts b/web/core/local-db/utils/utils.ts
index 4f5f0befb8..2a89a7fb6f 100644
--- a/web/core/local-db/utils/utils.ts
+++ b/web/core/local-db/utils/utils.ts
@@ -1,4 +1,3 @@
-import { captureException } from "@sentry/nextjs";
import pick from "lodash/pick";
import { TIssue } from "@plane/types";
import { rootStore } from "@/lib/store-context";
@@ -15,7 +14,6 @@ export const logError = (e: any) => {
e = parseSQLite3Error(e);
}
console.error(e);
- captureException(e);
};
export const logInfo = console.info;
diff --git a/web/next.config.js b/web/next.config.js
index 5f54b4b8cd..1124bc63e4 100644
--- a/web/next.config.js
+++ b/web/next.config.js
@@ -14,15 +14,7 @@ const nextConfig = {
return [
{
source: "/(.*)?",
- headers: [
- { key: "X-Frame-Options", value: "SAMEORIGIN" },
- // {
- // key: "Referrer-Policy",
- // value: "origin-when-cross-origin",
- // },
- // { key: "Cross-Origin-Opener-Policy", value: "same-origin" },
- // { key: "Cross-Origin-Embedder-Policy", value: "credentialless" },
- ],
+ headers: [{ key: "X-Frame-Options", value: "SAMEORIGIN" }],
},
];
},
@@ -30,13 +22,6 @@ const nextConfig = {
unoptimized: true,
},
transpilePackages: ["@plane/i18n"],
- // webpack: (config, { isServer }) => {
- // if (!isServer) {
- // // Ensure that all imports of 'yjs' resolve to the same instance
- // config.resolve.alias["yjs"] = path.resolve(__dirname, "node_modules/yjs");
- // }
- // return config;
- // },
async redirects() {
return [
{
@@ -68,7 +53,6 @@ const nextConfig = {
},
async rewrites() {
const posthogHost = process.env.NEXT_PUBLIC_POSTHOG_HOST || "https://app.posthog.com";
- const uploadsBaseURL = process.env.NEXT_PUBLIC_API_BASE_URL || "";
const rewrites = [
{
source: "/ingest/static/:path*",