Skip to content

Commit d50f007

Browse files
committed
Revert "Merge pull request Expensify#44432 from margelo/feat/release-profiler-on-web"
This reverts commit cec2514, reversing changes made to 485332d.
1 parent cd14a03 commit d50f007

26 files changed

+77
-693
lines changed

.github/workflows/platformDeploy.yml

-12
Original file line numberDiff line numberDiff line change
@@ -179,12 +179,6 @@ jobs:
179179
env:
180180
GITHUB_TOKEN: ${{ github.token }}
181181

182-
- name: Archive desktop sourcemaps
183-
uses: actions/upload-artifact@v3
184-
with:
185-
name: desktop-sourcemap-${{ github.ref_name }}
186-
path: desktop/dist/www/merged-source-map.js.map
187-
188182
iOS:
189183
name: Build and deploy iOS
190184
needs: validateActor
@@ -354,12 +348,6 @@ jobs:
354348
env:
355349
S3_URL: s3://${{ fromJSON(env.SHOULD_DEPLOY_PRODUCTION) && '' || 'staging-' }}expensify-cash
356350

357-
- name: Archive web sourcemaps
358-
uses: actions/upload-artifact@v3
359-
with:
360-
name: web-sourcemap-${{ github.ref_name }}
361-
path: dist/merged-source-map.js.map
362-
363351
- name: Purge Cloudflare cache
364352
run: /home/runner/.local/bin/cli4 --verbose --delete hosts=["${{ fromJSON(env.SHOULD_DEPLOY_PRODUCTION) && '' || 'staging.' }}new.expensify.com"] /zones/:9ee042e6cfc7fd45e74aa7d2f78d617b/purge_cache
365353
env:

README.md

+7-9
Original file line numberDiff line numberDiff line change
@@ -230,20 +230,19 @@ Within Xcode head to the build phase - `Bundle React Native code and images`.
230230
```jsx
231231
npm i && npm run pod-install
232232
```
233-
4. Depending on the platform you are targeting, run your Android/iOS app in production mode.
234-
5. Upon completion, the generated source map can be found at:
233+
7. Depending on the platform you are targeting, run your Android/iOS app in production mode.
234+
8. Upon completion, the generated source map can be found at:
235235
Android: `android/app/build/generated/sourcemaps/react/productionRelease/index.android.bundle.map`
236236
IOS: `main.jsbundle.map`
237-
web: `dist/merged-source-map.js.map`
238237

239238
### Recording a Trace:
240239
1. Ensure you have generated the source map as outlined above.
241240
2. Launch the app in production mode.
242-
3. Navigate to the feature you wish to profile.
243-
4. Initiate the profiling session by tapping with four fingers (on mobile) or `cmd+d` (on web) to open the menu and selecting **`Use Profiling`**.
244-
5. Close the menu and interact with the app.
245-
6. After completing your interactions, tap with four fingers or `cmd+d` again and select to stop profiling.
246-
7. You will be presented with a **`Share`** option to export the trace, which includes a trace file (`Profile<app version>.cpuprofile`) and build info (`AppInfo<app version>.json`).
241+
2. Navigate to the feature you wish to profile.
242+
3. Initiate the profiling session by tapping with four fingers to open the menu and selecting **`Use Profiling`**.
243+
4. Close the menu and interact with the app.
244+
5. After completing your interactions, tap with four fingers again and select to stop profiling.
245+
6. You will be presented with a **`Share`** option to export the trace, which includes a trace file (`Profile<app version>.cpuprofile`) and build info (`AppInfo<app version>.json`).
247246

248247
Build info:
249248
```jsx
@@ -266,7 +265,6 @@ Build info:
266265
4. Use the following commands to symbolicate the trace for Android and iOS, respectively:
267266
Android: `npm run symbolicate-release:android`
268267
IOS: `npm run symbolicate-release:ios`
269-
web: `npm run symbolicate-release:web`
270268
5. A new file named `Profile_trace_for_<app version>-converted.json` will appear in your project's root folder.
271269
6. Open this file in your tool of choice:
272270
- SpeedScope ([https://www.speedscope.app](https://www.speedscope.app/))

config/webpack/webpack.dev.ts

-4
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,6 @@ const getConfiguration = (environment: Environment): Promise<Configuration> =>
5353
cert: path.join(__dirname, 'certificate.pem'),
5454
},
5555
},
56-
headers: {
57-
// eslint-disable-next-line @typescript-eslint/naming-convention
58-
'Document-Policy': 'js-profiling',
59-
},
6056
},
6157
plugins: [
6258
new DefinePlugin({

desktop/electron-serve.ts

-106
This file was deleted.

desktop/main.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import type {BrowserView, MenuItem, MenuItemConstructorOptions, WebContents, Web
33
import contextMenu from 'electron-context-menu';
44
import log from 'electron-log';
55
import type {ElectronLog} from 'electron-log';
6+
import serve from 'electron-serve';
67
import {autoUpdater} from 'electron-updater';
78
import {machineId} from 'node-machine-id';
89
import checkForUpdates from '@libs/checkForUpdates';
@@ -13,7 +14,6 @@ import type {TranslationPaths} from '@src/languages/types';
1314
import type PlatformSpecificUpdater from '@src/setup/platformSetup/types';
1415
import type {Locale} from '@src/types/onyx';
1516
import type {CreateDownloadQueueModule, DownloadItem} from './createDownloadQueue';
16-
import serve from './electron-serve';
1717
import ELECTRON_EVENTS from './ELECTRON_EVENTS';
1818

1919
const createDownloadQueue = require<CreateDownloadQueueModule>('./createDownloadQueue').default;

desktop/package-lock.json

+17
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

desktop/package.json

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
"dependencies": {
77
"electron-context-menu": "^2.3.0",
88
"electron-log": "^4.4.8",
9+
"electron-serve": "^1.3.0",
910
"electron-updater": "^6.2.1",
1011
"node-machine-id": "^1.1.12"
1112
},

0 commit comments

Comments
 (0)