Skip to main content
ArcBlock Community

Blocklet/CLI 1.16.20 App crash, "n.info is null"

wgring
Support
closedreliabilityresolvedrewarded

Screenshot from 2023-12-24 19-47-14.png Ubuntu 22.04.03 LTS, kernel: Linux 5.15.0-1044-raspi, architecture: arm64 NodeJS versions 16,18,20 installed/tested, nvm installed n/npm installed (10) nginx (1.18.0, tested with and without being installed)

I received this error (picture) after installing blocklet/cli (-g option), blocklet server init, blocklet server start, finished installation, viewed dashboard, then went to install a blocklet. When installing blocklet/cli, there were depreciated warnings (will have to run setup again to copy over the output to here).

Output (with NodeJS 18,20):

javascript
npm WARN deprecated @npmcli/move-file@1.1.2: This functionality has been moved to @npmcli/fs
npm WARN deprecated stable@0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility
npm WARN deprecated interface-ipld-format@1.0.1: This module has been superseded by the multiformats module
npm WARN deprecated cids@1.1.9: This module has been superseded by the multiformats module
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated multibase@4.0.6: This module has been superseded by the multiformats module
npm WARN deprecated multicodec@3.2.1: This module has been superseded by the multiformats module
npm WARN deprecated ipld-dag-pb@0.22.3: This module has been superseded by @ipld/dag-pb and multiformats

When specifying 1.16.19 while 1.16.20 was installed, and NodeJS 16 running, it would give depreciated warnings still but also mention needing version 18. Switched to 18 via "node use" with same results. defaulting to 20 also same results. I've created a new node roughly 3 times (1.16.20), of which each had a separate test of installing a blocklet, Blockchain Explorer, AI Kit, DID Spaces Personal. Without installing a blocklet, and even after a device restart - blocklet server will still work and display in the browser window (as long as "blocklet server start" is run in the correct folder after a restart).

I will be reimaging the ubuntu box, and specifying 1.16.19 this time, repeating in reverse release order (1.16.18, 1.16.17, etc.) noting changes, as the previous version I used a few months ago (was one of them between 1.16.09-1.16.16) had been doing ok. Was avoiding the 'beta" listed packages for the time being.

20 replies

shijun2 years ago

By the way, green status for automated testing of app launch/configure workflow is required for each release of blocklet server, including beta releases.

  • Each beta release are at least tested for 1 week within the dev team.
  • Each production release are tested at least for 1 week on arcblock production servers.
wgring2 years ago

An added error: Image

  1. Install Ubuntu Jammy LTS, sudo apt update && sudo apt upgrade (and/or software updater after restart). Restart. (Sudo may be required for the rest).
  2. Install/verify npm install, sudo apt install npm
  3. Install/verify n: sudo npm i -g n, Sudo n stable or sudo n v16.20.2/18.19.0
  4. Restart/reopen terminal for changes to take effect.
  5. Install blocklet cli with sudo npm i -g @blocklet/cli
  6. mkdir -p ~/[your blocklet server name] && cd ~/[your blocklet server name]
  7. Blocklet server init
  8. Blocklet server start
  9. Finish setup of server with DID Wallet
  10. Navigate to site, take note of addresses (will send you address in chat)
  11. Install blocklet to recreate problem
  12. Check if problem still exists (Blockchain explorer component checked)
  13. Problem still exists. Server does not load gui/browser. GraphQL error is new, only showed once, then back to n info null or unable to connect entirely
shijun2 years ago

It's highly likely that the issue is caused by node version manager, we will verify that too

wgring2 years ago

n was easier to deal with and install node compared to nvm.

With the OCAP post i had made before, i had been using blocklet 1.16.16/1.16.17. Had not done iterations between x.x.16/17 and x.x.20. The current x.x.20 install does not have nginx installed yet, but i will be doing that shortly to see if theres a change. Right now the blocklet server doesnt load anymore/cant start back up.

If nginx install corrupts again or just doesnt fix it, im going to specify back to 1.16.16 as a fresh install and try installing a blocklet again. If things are fine, ill see if updating to new blocklet server version on dashboard works/doesnt break like it did for fatych

wgring2 years ago

will toggle for beta release and update. thanks again!

wgring2 years ago

everything still requires either sudo or direct root privileges in order to function. ubuntu doesnt give users root by default (ubuntu desktop jammy, not ubuntu server in use). restarting blocklet server from GUI gets it stuck on verifying blocklet server. only commands that i havent needed sudo for are ones displaying version numbers of apps

wgring2 years ago

using external ip link shows "ensure everything is ok"

using internal ip link shows "upgrading"

ImageImage

wgring2 years ago

ya i was following that, but the server version im running now is 1.16.21-beta-bd0e2503.

clicked update within the blocklet server GUI, then chaos ensued. clicking restart does the same. only way ive gotten around it is blocklet server stop from terminal, and then dont use the gui for update or restart 😅

fatych2 years ago

You can follow my method or wait for the official solution

wgring2 years ago

ok good lol glad im not alone

shijun2 years ago

image.png

wgring2 years ago

will definitely check this out once its later in the AM (3 at the moment 😅).

wgring2 years ago

it stayed stuck.

going to use that blocklet cli installation method again, but not use fnm and instead use the nodesource method to install and set ubuntu to use nodejs version 18. that method seems to persist through restarts of the machine or terminal, fnm would show the node version of 18 as would the about page, but the ubuntu system itself was still reporting 12.

wgring2 years ago

npm commands required sudo in front.

using the nodesource curl method to install nodejs v18 for ubuntu jammy.

Used sudo in front of blocklet server commands, init and start. Arcblock Splash text appeared and generated config. After using start, it displayed one secure link (internal ip string).

Server started, went into GUI. Clicked restart from the settings/about page. If this one stays stuck again, ill try to reference it as default routed (non-nginx), and im going to install nginx and initialize another blocklet server to use with nginx.

The default routing seems to still gets stuck, but is separate from the nginx method.

Going to go back to the nginx method, but still without the fnm portion in favor of nodesource curl method. Attempting nginx install after shutting down the blocklet server first. then restarting it/creating a new one if the current shows default or doesnt start, before going through uninstalling blocklet/cli or otherwise the os.

wgring2 years ago(edited)

says nginx now (didnt have to reinstall blocklet cli).

attempting another restart

so far, this restart is also stuck 30 minutes later

shijun2 years ago

I am wondering if you can record your operation sequence with this so that I can reproduce issues you spotted: https://docs.asciinema.org/getting-started/

wgring2 years ago(edited)

the nodesource method i used, ubuntu jammy, nodejs 18:

https://github.com/nodesource/distributions#ubuntu-versions

("curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash - && sudo apt install nodejs")

Nginx ubuntu:

https://nginx.org/en/linux_packages.html#Ubuntu

  1. sudo apt install curl gnupg2 ca-certificates lsb-release ubuntu-keyring
  2. setup app repo, echo "deb [signed-by=/usr/share/keyrings/nginx-archive-keyring.gpg] \ http://nginx.org/packages/debian lsb_release -cs nginx" \ | sudo tee /etc/apt/sources.list.d/nginx.list
  3. gpg --dry-run --quiet --no-keyring --import --import-options import-show /usr/share/keyrings/nginx-archive-keyring.gpg
  4. " The output should contain the full fingerprint 573BFD6B3D8FBC641079A6ABABF5BD827BD9BF62 as follows: pub rsa2048 2011-08-19 [SC] [expires: 2024-06-14] 573BFD6B3D8FBC641079A6ABABF5BD827BD9BF62 uid nginx signing key <signing-key@nginx.com> "
  5. echo "deb [signed-by=/usr/share/keyrings/nginx-archive-keyring.gpg] \ http://nginx.org/packages/ubuntu lsb_release -cs nginx" \ | sudo tee /etc/apt/sources.list.d/nginx.list
  6. Set up repository pinning to prefer our packages over distribution-provided ones: echo -e "Package: *\nPin: origin nginx.org\nPin: release o=nginx\nPin-Priority: 900\n" \ | sudo tee /etc/apt/preferences.d/99nginx
  7. sudo apt update sudo apt install nginx
wgring2 years ago

after stopping the new server with -f, and starting it again (without updating db to the maintenance), trying to restart from GUI again gets it stuck at 'verifying' instead of 'ensure' asciinema clip of tail output on log: https://asciinema.org/a/wIT5nXNJ1aHv9T7f3LfbffAy4

shijun2 years ago

The confirmed bug is stuck at this step, according to your above info there maybe another bug related to global blocklet binary locating.

Screenshot 2024-01-06 at 22.06.58.png

wgring2 years ago
Reply