Using Node.js 8.14
it was working fine since I deployed a two days ago, but now suddenly error started to occur.
During deploy i get this error on remote console as :
The command is : gcloud app deploy --project_name
Error Log :
Step #1: E: Unable to fetch some archives, maybe run apt-get update or
try with --fix-missing?
Step #1: npm ERR! code ELIFECYCLE Step #1: npm ERR! errno 100
Step #1: npm ERR! scraper#1.0.0 preinstall: apt-get update && apt-get
-y install gconf-service libasound2 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4
libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0
libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1
libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6
libxrandr2 libxrender1 libxss1 libxtst6 ca-certificates
fonts-liberation libappindicator1 libnss3 lsb-release xdg-utils wget
Step #1: npm ERR! Exit status 100 Step #1: npm ERR! Step #1: npm ERR!
Failed at the scraper#1.0.0 preinstall script. Step #1: npm ERR! This
is probably not a problem with npm. There is likely additional logging
output above. Step #1: npm WARN Local package.json exists, but
node_modules missing, did you mean to install? Step #1: Step #1: npm
ERR! A complete log of this run can be found in: Step #1: npm ERR!
/root/.npm/_logs/2019-03-05T10_24_22_880Z-debug.log Step #1: error
building image: error building stage: waiting for process to exit:
exit status 1
more over, when I see the logs, it has lots of 404 error
Step #1: E: Failed to fetch
http://security.ubuntu.com/ubuntu/pool/main/s/systemd/libpam-systemd_229-4ubuntu21.15_amd64.deb
404 Not Found [IP: 91.189.88.161 80] Step #1: Step #1: E: Failed to
fetch
http://security.ubuntu.com/ubuntu/pool/main/libg/libgd2/libgd3_2.1.1-4ubuntu0.16.04.10_amd64.deb
404 Not Found [IP: 91.189.88.161 80] Step #1: Step #1: E: Failed to
fetch
http://security.ubuntu.com/ubuntu/pool/main/n/nss/libnss3-nssdb_3.28.4-0ubuntu0.16.04.4_all.deb
404 Not Found [IP: 91.189.88.161 80] Step #1: Step #1: E: Failed to
fetch
http://security.ubuntu.com/ubuntu/pool/main/n/nss/libnss3_3.28.4-0ubuntu0.16.04.4_amd64.deb
404 Not Found [IP: 91.189.88.161 80]
Thanks in advance.
Related
Whenever I am trying to deploy my react app on gh-pages this error is coming
Cloning into 'C:\Users\Yasin\Desktop\HTML Projects\igvio-main\node_modules.cache\gh-pages\https!github.com!yasin-ai!igvio.git'...
error: unable to create file src/Media/4VGWsLNGhpXExFXdvAMxJ8Y7WxN-NoHaa0Jf01NNjWEZvR9IbI56c2-VrjIsmgZ0Cugensf-3qJDt3tkSRV-Y2LYGHrcPDJJmLPf9zpqFq94ocq16seQT0queKpLauUjwFKD2e7NZbs2jSDeJz0sx_1wr__psiwBSqkrW9kTiTPoe: Filename too long
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry with 'git restore --source=HEAD :/'
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! instagram-tools#0.1.0 deploy: `gh-pages -d build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the instagram-tools#0.1.0 deploy script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Yasin\AppData\Roaming\npm-cache\_logs\2022-08-17T14_07_49_625Z-debug.log
PS C:\Users\Yasin\Desktop\HTML Projects\igvio-main> git config --system core.longpaths true
error: could not lock config file C:/Program Files/Git/etc/gitconfig: Permission denied
This was due to long file names and doing a simple config as below resolved it
git config --system core.longpaths true
or another solution is try using this
git reset
I have a react app which build and deploys fine on my development environment. Now I did some refactoring which was limited to moving a few files, commiting, testing and redeploying. After the latest change I deployed to productiong and found that on production I got a 404 when accessing the site. 404 not found. I'm completely stumped as to what may be the problem.
Reviewing the bitbucket pipeline I get the following output:
./src/pages/Home.jsx
Cannot find file '../components/narrative/Narrative' in './src/pages'.
Now if I have a look at './src/pages/Home.jsx' I can see I'm importing the below
import Narrative from "../components/narrative/Narrative"
And that file does indeed exist:
The full output of the pipeline is here:
root#ubuntu-web:~/eg-web# npm run build
> refgator-web#0.1.0 build /root/eg-web
> react-scripts build
Creating an optimized production build...
Browserslist: caniuse-lite is outdated. Please run:
npx browserslist#latest --update-db
Why you should do it regularly:
https://github.com/browserslist/browserslist#browsers-data-updating
Failed to compile.
./src/pages/Home.jsx
Cannot find file '../components/narrative/Narrative' in './src/pages'.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! refgator-web#0.1.0 build: `react-scripts build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the refgator-web#0.1.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2022-02-16T10_23_04_697Z-debug.log
And if I go to the production server this is the latest error log:
This was actually caused by the folder name as it is locally called narrative. On the repo it's Narrative
I changed this with help from this answer In a Git repository, how to properly rename a directory?
I've had my personal website made with React published on Github pages for about a year now and I would always update it using the following commands:
git add .
git commit -m "update"
npm run deploy
git push -u origin main
The last time I was able to run these commands without fail was last week. Since then, the only changes I've done to the repo are changing the repo name on Github but now I'm unable to run the same commands without receiving a 403 error. In the end I decided to start a new repo but now I get the following error:
fatal: A branch named 'gh-pages' already exists.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! username.github.io#0.1.0 deploy: `gh-pages -d build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the username.github.io#0.1.0 deploy script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/computer/.npm/_logs/2021-08-17T22_31_00_085Z-debug.log
I've also tried manually removing gh-pages from node_modules/.cache but instead I get this error:
remote: Support for password authentication was removed on August 13, 2021. Please use a personal access token instead.
remote: Please see https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/ for more information.
fatal: unable to access 'https://github.com/username/username.github.io.git/': The requested URL returned error: 403
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! username.github.io#0.1.0 deploy: `gh-pages -d build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the username.github.io#0.1.0 deploy script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/username/.npm/_logs/2021-08-17T22_41_14_919Z-debug.log
Is there anything else I can do besides give up?
*** note: I replaced my actual gh username for privacy
I am trying to install image picker, it gets installed. But then post running android this error is thrown. When I remove installed image picker line from package json, the issue gets resolved. How to I resolve this?
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:processDebugResources'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
> Unable to delete directory 'D:\React\OMW\project\omw_mobile2\onmyway_mobile\OnMyWay\android\app\build\generated\not_namespaced_r_class_sources\debug\r\androidx\appcompat' after 10 attempts
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 47s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup. Run CLI with --verbose flag for more details.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! OnMyWay#0.0.1 android: `react-native run-android`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the OnMyWay#0.0.1 android script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\admin\AppData\Roaming\npm-cache\_logs\2020-07-18T03_05_08_404Z-debug.log
you need to clean project
Build > Clean Project
and than build your project again
I've got a react application with Next.js that triggers a google cloud trigger to build a docker image and do some other things based on a cloudbuild.yaml file.
This application builds successfully locally, but when I'm building it on the Gcloud the logs show:
Step #1: > Using external babel configuration
Step #1: > Location: "/app/.babelrc"
Step #1: Failed to compile.
Step #1: > Build error occurred
Step #1: Error: > Build failed because of webpack errors
Step #1: at build (/app/node_modules/next/dist/build/index.js:7:847)
Step #1: at runMicrotasks (<anonymous>)
Step #1: at processTicksAndRejections (internal/process/task_queues.js:93:5)
Step #1: npm ERR! code ELIFECYCLE
Step #1: npm ERR! errno 1
Step #1: npm ERR! xxx#0.1.0 build: `next build`
Step #1: npm ERR! Exit status 1
Step #1: npm ERR!
Step #1: npm ERR! Failed at the xxx#0.1.0 build script.
Step #1: npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Step #1:
Step #1: npm ERR! A complete log of this run can be found in:
Step #1: npm ERR! /root/.npm/_logs/2019-09-13T11_23_36_719Z-debug.log
Step #1: The command '/bin/sh -c npm run build' returned a non-zero code: 1
Locally however it's a completely different story
Creating an optimized production build ...
> Using external babel configuration
> Location: "C:\Users\name\Documents\GitHub\xxx\.babelrc"
Compiled successfully.
Anyone know a good way to debug this issue?
Thanks.
It turns out the issue was that external .Scss stylesheets were not tolerated. I removed them and instead moved the styling to within the components using tag.