Skip to content
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

Hosting A Web Version #1236

Closed
BlackBoyZeus opened this issue Feb 27, 2024 · 3 comments
Closed

Hosting A Web Version #1236

BlackBoyZeus opened this issue Feb 27, 2024 · 3 comments
Assignees
Labels

Comments

@BlackBoyZeus
Copy link

How may one host a web app of their own ? It seems that i keep retaining errors such as protobuffer.js failed to load, and i get this for any number of the files held in the source folder when i attempt to take this to aws amplify

screenshot is attached below. Simply put we would like to see how to make this run seamlessly , but i can't identify where in the code the problem arises. Thanks for all you've done.

Screenshot 2024-02-26 at 7 04 14 PM
@BlackBoyZeus
Copy link
Author

in fact --- it seems 2024-02-27T02:49:30.850Z [INFO]: # Cloning repository: git@github.com:Ultrabrain/UltraNetworkPricing.git
2024-02-27T02:49:41.644Z [INFO]:
2024-02-27T02:49:41.741Z [INFO]: Cloning into 'UltraNetworkPricing'...
2024-02-27T02:49:41.741Z [INFO]: # Checking for Git submodules at: /codebuild/output/src1996811145/src/UltraNetworkPricing/.gitmodules
2024-02-27T02:49:41.756Z [INFO]: # Retrieving environment cache...
2024-02-27T02:49:41.804Z [WARNING]: ! Unable to write cache: {"code":"ERR_BAD_REQUEST","message":"Request failed with status code 404"})}
2024-02-27T02:49:41.805Z [INFO]: ---- Setting Up SSM Secrets ----
2024-02-27T02:49:41.805Z [INFO]: SSM params {"Path":"/amplify/d2cpdmfrzlrxw0/main/","WithDecryption":true}
2024-02-27T02:49:41.848Z [WARNING]: !Failed to set up process.env.secrets
2024-02-27T02:49:43.129Z [INFO]: No live updates for this build run
2024-02-27T02:49:43.133Z [INFO]: # Retrieving cache...
2024-02-27T02:49:43.159Z [INFO]: # Retrieved cache
2024-02-27T02:50:02.907Z [INFO]: ## Starting Backend Build
## Checking for associated backend environment...
2024-02-27T02:50:02.913Z [INFO]: ## No backend environment association found, continuing...
## Completed Backend Build
{"backendDuration": 0}
## Starting Frontend Build
# Starting phase: preBuild
# Executing command: npm install
2024-02-27T02:50:25.290Z [INFO]: # Completed phase: preBuild
# Starting phase: build
# Executing command: npm run build
2024-02-27T02:50:25.596Z [INFO]: build
2024-02-27T02:50:25.598Z [INFO]: build web
2024-02-27T02:50:25.598Z [INFO]: mkdir dist/web
2024-02-27T02:50:25.599Z [INFO]: cp source/dir dist/dir
2024-02-27T02:50:25.607Z [INFO]: rm dist/web/app.js
2024-02-27T02:50:25.633Z [INFO]: build electron
2024-02-27T02:50:26.839Z [INFO]: •
2024-02-27T02:50:26.840Z [INFO]: electron-builder version=24.12.0
2024-02-27T02:50:26.841Z [INFO]: •
2024-02-27T02:50:26.843Z [INFO]: loaded configuration file=package.json ("build" field)
2024-02-27T02:50:27.742Z [INFO]: •
2024-02-27T02:50:27.743Z [INFO]: electron-builder version=24.12.0 os=4.14.291-218.527.amzn2.x86_64
2024-02-27T02:50:27.748Z [INFO]: •
2024-02-27T02:50:27.748Z [INFO]: loaded configuration file=package.json ("build" field)
2024-02-27T02:50:28.017Z [INFO]: ⨯
2024-02-27T02:50:28.017Z [INFO]: Cannot find module 'dmg-license'
Require stack:
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/out/dmgLicense.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/out/dmg.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/out/dmgUtil.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/app-builder-lib/out/macPackager.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/app-builder-lib/out/packager.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/app-builder-lib/out/index.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/electron-builder/out/builder.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/electron-builder/out/cli/cli.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/electron-builder/cli.js failedTask=build stackTrace=Error: Cannot find module 'dmg-license'
Require stack:
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/out/dmgLicense.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/out/dmg.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/out/dmgUtil.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/app-builder-lib/out/macPackager.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/app-builder-lib/out/packager.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/app-builder-lib/out/index.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/electron-builder/out/builder.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/electron-builder/out/cli/cli.js
- /codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/electron-builder/cli.js
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:995:15)
at Function.Module._load (node:internal/modules/cjs/loader:841:27)
at Module.require (node:internal/modules/cjs/loader:1067:19)
at require (node:internal/modules/cjs/helpers:103:18)
at Object. (/codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/src/dmgLicense.ts:7:1)
at Module._compile (node:internal/modules/cjs/loader:1165:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1219:10)
at Module.load (node:internal/modules/cjs/loader:1043:32)
at Function.Module._load (node:internal/modules/cjs/loader:878:12)
at Module.require (node:internal/modules/cjs/loader:1067:19)
at require (node:internal/modules/cjs/helpers:103:18)
at Object. (/codebuild/output/src1996811145/src/UltraNetworkPricing/node_modules/dmg-builder/src/dmg.ts:13:1)
at Module._compile (node:internal/modules/cjs/loader:1165:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1219:10)
at Module.load (node:internal/modules/cjs/loader:1043:32)
at Function.Module._load (node:internal/modules/cjs/loader:878:12)
2024-02-27T02:50:28.030Z [INFO]: Command failed: npx electron-builder --mac --universal --publish never -c.mac.identity=null
2024-02-27T02:50:28.038Z [ERROR]: !!! Build failed
2024-02-27T02:50:28.038Z [ERROR]: !!! Error: Command failed with exit code 1
2024-02-27T02:50:28.039Z [INFO]: # Starting environment caching...
2024-02-27T02:50:28.039Z [INFO]: # Environment caching completed
Terminating logging...
---any suggestions on this, is it attmepting from the wrong entry point etc? it looks like this is trying to ingest the electron version , which files in totality need to be segregated ?

@lutzroeder
Copy link
Owner

lutzroeder commented Feb 27, 2024

@BlackBoyZeus the error is likely from one of the import * as text from './text.js'; statements in the code, probably because the file was not deployed to the right location on the server. In the log it is not clear why you are running build electron for a web deployment. Can you explain what you are trying to accomplish and why this requires a custom server deployment instead of using the Python server?

@lutzroeder lutzroeder closed this as not planned Won't fix, can't repro, duplicate, stale Feb 27, 2024
@BlackBoyZeus
Copy link
Author

I have resolved the issue, it was more so for testing purposes with AWS compatible hosting on such code. I was not expecting such speed in response haha , but i had to direct the entry point to source folder for future reference in case you encounter such complaint furthermore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants