Pegascape alternative?

DrahosR

Well-Known Member
Newcomer
Joined
Jun 20, 2021
Messages
46
Trophies
0
Age
34
XP
69
Country
Afghanistan
edit startpega_webapplet.bat add @Echo in the first line.
I did it, but with the same effect. After double click Or rmb/open, same effect
Now I ran it from CMD and I can see this

c:\PegaScape>startpega.bat

c:\PegaScape>node start.js --ip 192.168.0.11 --host 192.168.0.11
node:internal/modules/cjs/loader:1145
throw err;
^

Error: Cannot find module 'browserify'
Require stack:
- c:\PegaScape\start.js
at Module._resolveFilename (node:internal/modules/cjs/loader:1142:15)
at Module._load (node:internal/modules/cjs/loader:983:27)
at Module.require (node:internal/modules/cjs/loader:1230:19)
at require (node:internal/modules/helpers:179:18)
at Object.<anonymous> (c:\PegaScape\start.js:6:20)
at Module._compile (node:internal/modules/cjs/loader:1368:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1426:10)
at Module.load (node:internal/modules/cjs/loader:1205:32)
at Module._load (node:internal/modules/cjs/loader:1021:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:142:12) {
code: 'MODULE_NOT_FOUND',
requireStack: [ 'c:\\PegaScape\\start.js' ]
}

Node.js v21.7.1

I don't know why is there wrong ip? I definitely changed it to one I have on the network, which doesn't even start with 192.

EDIT: I ran the startpega_webapplet.bat now and that one has correct ips. Do I need to modify both of the bats or only the webapplet?
I still get the error though
 
Last edited by DrahosR,

Teo_Nightcrow

Member
Newcomer
Joined
Mar 24, 2024
Messages
10
Trophies
0
Age
39
XP
17
Country
Philippines
I did it, but with the same effect. After double click Or rmb/open, same effect
Now I ran it from CMD and I can see this

c:\PegaScape>startpega.bat

c:\PegaScape>node start.js --ip 192.168.0.11 --host 192.168.0.11
node:internal/modules/cjs/loader:1145
throw err;
^

Error: Cannot find module 'browserify'
Require stack:
- c:\PegaScape\start.js
at Module._resolveFilename (node:internal/modules/cjs/loader:1142:15)
at Module._load (node:internal/modules/cjs/loader:983:27)
at Module.require (node:internal/modules/cjs/loader:1230:19)
at require (node:internal/modules/helpers:179:18)
at Object.<anonymous> (c:\PegaScape\start.js:6:20)
at Module._compile (node:internal/modules/cjs/loader:1368:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1426:10)
at Module.load (node:internal/modules/cjs/loader:1205:32)
at Module._load (node:internal/modules/cjs/loader:1021:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:142:12) {
code: 'MODULE_NOT_FOUND',
requireStack: [ 'c:\\PegaScape\\start.js' ]
}

Node.js v21.7.1
your node module installation did not finish. go to pegascape folder then node_modules, delete the all the files. Run powershell as administrator go to pegascape directory then repeat npm install. Or try this delete the node_modules folder, extract this file and save to your pegascape directory. its the node_modules
 

Attachments

  • node_modules link.txt
    28 bytes · Views: 7
  • Like
Reactions: DrahosR

DrahosR

Well-Known Member
Newcomer
Joined
Jun 20, 2021
Messages
46
Trophies
0
Age
34
XP
69
Country
Afghanistan
c:\PegaScape>startpega_webapplet.bat

c:\PegaScape>node start.js --webapplet --ip 10.0.1.245 --host 10.0.1.245
(node:4140) [DEP0128] DeprecationWarning: Invalid 'main' field in 'c:\PegaScape\node_modules\mold-source-map\package.json' of 'mold-source-map.js'. Please either fix that or report it to the module author
(Use `node --trace-deprecation ...` to show where the warning was created)
Responding with address 10.0.1.245
Switch DNS IP: 10.0.1.245

c:\PegaScape\node_modules\repl.history\index.js:19
repl.rli.addListener('line', function(code) {
^

TypeError: Cannot read properties of undefined (reading 'addListener')
at module.exports (c:\PegaScape\node_modules\repl.history\index.js:19:12)
at Object.<anonymous> (c:\PegaScape\repl.js:161:1)
at Module._compile (node:internal/modules/cjs/loader:1368:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1426:10)
at Module.load (node:internal/modules/cjs/loader:1205:32)
at Module._load (node:internal/modules/cjs/loader:1021:12)
at Module.require (node:internal/modules/cjs/loader:1230:19)
at require (node:internal/modules/helpers:179:18)
at c:\PegaScape\start.js:392:2
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Node.js v21.7.1

c:\PegaScape>

Now, is this the correct message or still wrong?
 

Teo_Nightcrow

Member
Newcomer
Joined
Mar 24, 2024
Messages
10
Trophies
0
Age
39
XP
17
Country
Philippines
c:\PegaScape>startpega_webapplet.bat

c:\PegaScape>node start.js --webapplet --ip 10.0.1.245 --host 10.0.1.245
(node:4140) [DEP0128] DeprecationWarning: Invalid 'main' field in 'c:\PegaScape\node_modules\mold-source-map\package.json' of 'mold-source-map.js'. Please either fix that or report it to the module author
(Use `node --trace-deprecation ...` to show where the warning was created)
Responding with address 10.0.1.245
Switch DNS IP: 10.0.1.245

c:\PegaScape\node_modules\repl.history\index.js:19
repl.rli.addListener('line', function(code) {
^

TypeError: Cannot read properties of undefined (reading 'addListener')
at module.exports (c:\PegaScape\node_modules\repl.history\index.js:19:12)
at Object.<anonymous> (c:\PegaScape\repl.js:161:1)
at Module._compile (node:internal/modules/cjs/loader:1368:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1426:10)
at Module.load (node:internal/modules/cjs/loader:1205:32)
at Module._load (node:internal/modules/cjs/loader:1021:12)
at Module.require (node:internal/modules/cjs/loader:1230:19)
at require (node:internal/modules/helpers:179:18)
at c:\PegaScape\start.js:392:2
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Node.js v21.7.1

c:\PegaScape>

Now, is this the correct message or still wrong?
don't close the window where the message
Responding with address 10.0.1.245
Switch DNS IP: 10.0.1.245 is displayed. change your switch primary DNS to 10.0.1.245 the run fake news. You will not be seeing a webpage on your computer. the explot page will load on your switch
 

DrahosR

Well-Known Member
Newcomer
Joined
Jun 20, 2021
Messages
46
Trophies
0
Age
34
XP
69
Country
Afghanistan
don't close the window where the message
Responding with address 10.0.1.245
Switch DNS IP: 10.0.1.245 is displayed. change your switch primary DNS to 10.0.1.245 the run fake news. You will not be seeing a webpage on your computer. the explot page will load on your switch
I tried already and switch just errors with
Unable to connect to the internet.
Could not perform DNS name resolution
 

Teo_Nightcrow

Member
Newcomer
Joined
Mar 24, 2024
Messages
10
Trophies
0
Age
39
XP
17
Country
Philippines
Did you put your local IP Address or your public IP Address?
Post automatically merged:

10x for the tip!
but now i have another problem:
I'm on Windows 10. It seems that 'npm install' ran ok but when i start 'startpega_webapplet.bat' I get
node start.js --webapplet --ip 192.168.0.11 --host 192.168.0.11 PegaScape\node_modules\marked-terminal\index.cjs:333 && Number(osRelease[2]) >= 10_586 ^^ SyntaxError: Invalid or unexpected token at new Script (vm.js:51:7) at createScript (vm.js:136:10) at Object.runInThisContext (vm.js:197:10) at Module._compile (internal/modules/cjs/loader.js:618:28) at Object.Module._extensions..js (internal/modules/cjs/loader.js:665:10) at Module.load (internal/modules/cjs/loader.js:566:32) at tryModuleLoad (internal/modules/cjs/loader.js:506:12) at Function.Module._load (internal/modules/cjs/loader.js:498:3) at Module.require (internal/modules/cjs/loader.js:598:17) at require (internal/modules/cjs/helpers.js:11:18)

Tried bumping versions. messed up...
Someone managed to run this on Windows?
you did not change the ip address on startpega_webapplet.bat. it should be your local computer ip.
 
Last edited by Teo_Nightcrow,

xradeon

Member
Newcomer
Joined
May 27, 2020
Messages
7
Trophies
0
Age
37
XP
55
Country
Mexico
Guys i have a question,
Thanks to @impeeza I got the pegascape running
and i managed to get it running on the switch with the dns

however when i enter there and get to the part where it says
"Tap the text field below, wait three seconds, then tap the power button",
i do this and then nothing happens

I even tried to wait a full minute before I "Tap the text field"
and then another full minute before I "tap the power button"
when in the past i did his it worked perfectly

I even tried to turn on the logger in the pegascape, and there were no logs after the step when i pressed the scenario

Is there something i am missing?
Did you fin a solution? Check my post @michkele I think it's the same issue.
(Can't paste the URL but I will tag you there)...
 

impeeza

¡Kabito!
Member
Joined
Apr 5, 2011
Messages
6,361
Trophies
3
Age
46
Location
At my chair.
XP
18,717
Country
Colombia
you are completely right!

A modchip is an good alternative
Post automatically merged:


Damn I was unable to follow my own advises: RTFM
Post automatically merged:

Hello there boys, in order to try to get my foot out of my mouth I did test to build and run PegaScape self hosted.

Tried on Windows Using MSYS but no avail because NPM INSTALL for PegaScape Repo is not supported on Win32:
View attachment 425079

works on ANY OS but win32 !!


Then used my Ubuntu Virtual Machine, open a Terminal window and run the commands:

you need Python 2 on the system, so installed python2 and created an alias to python

Bash:
sudo apt install python
alias python=/usr/bin/python2

Using the recommendation of @xradeon , installed the node and npm, 9.11.2 & 5.6.0 versions respectively (https://gbatemp.net/threads/pegascape-alternative.650182/post-10372685)

For that, I did use the instructions on https://stackoverflow.com/questions...l-a-specific-version-of-node-on-ubuntu-debian (Answer 56)
Bash:
cd ~
curl https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash
source ~/.nvm/nvm.sh
nvm install 9.11.2
node --version
npm --version


As instructed by the README.MD on the original repo: https://github.com/noahc3/PegaScape#self-hosting
after install NodeJS & NPM, executed the next commands:

Bash:
cd ~
git clone https://www.github.com/noahc3/PegaScape
cd ~/PegaScape/
npm install

on my system systemd-resolved was running so I had to stop it to be able to run integrated DNS
Bash:
sudo systemctl stop systemd-resolved

Also for some strange reason sudo node give me the "command not found" error

View attachment 425080
so I did execute it with full path:
Bash:
sudo /home/impeeza/.nvm/versions/node/v9.11.2/bin/node start.js --webapplet

Now the PegaScape server is running self hosted

View attachment 425081

My 4.1.0 console is in other house just now (it's a unpatched one but the SysNAND is 4.1.0 and I had a EmuMMC updated) so can not test just now but should work fine.
Guys I just tweaked the existing tutorial and create a new one for running Pegascape on Windows Using MSYS2:

Linux, also can be used to build on RaspBerry PI (even Zero W) and have your own Pegascape Gadget
https://gbatemp.net/threads/building-pagascape-from-source-to-running-self-hosted-mode.650712/

Windows using MSYS and portable
https://gbatemp.net/threads/buildin...-self-hosted-mode-on-windows-and-msys.652314/
 

cewong2

Member
Newcomer
Joined
Jul 14, 2008
Messages
11
Trophies
1
XP
84
Country
United States
your node module installation did not finish. go to pegascape folder then node_modules, delete the all the files. Run powershell as administrator go to pegascape directory then repeat npm install. Or try this delete the node_modules folder, extract this file and save to your pegascape directory. its the node_modules
I tried to see if I could use this on the Mac since I was having a similar issue if the nodes not installing but I get this error:

Since I can’t use the bat I just run the command directly with sudo

I get the following error:

Code:
(node:59987) [DEP0128] DeprecationWarning: Invalid 'main' field in '/Users/cewong2/PegaScape/node_modules/mold-source-map/package.json' of 'mold-source-map.js'. Please either fix that or report it to the module author
(Use `node --trace-deprecation ...` to show where the warning was created)
Responding with address 192.168.1.227
Switch DNS IP: 192.168.1.227

/Users/cewong2/PegaScape/node_modules/repl.history/index.js:19
  repl.rli.addListener('line', function(code) {
           ^

TypeError: Cannot read properties of undefined (reading 'addListener')
    at module.exports (/Users/cewong2/PegaScape/node_modules/repl.history/index.js:19:12)
    at Object.<anonymous> (/Users/cewong2/PegaScape/repl.js:161:1)
    at Module._compile (node:internal/modules/cjs/loader:1256:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Module._load (node:internal/modules/cjs/loader:960:12)
    at Module.require (node:internal/modules/cjs/loader:1143:19)
    at require (node:internal/modules/cjs/helpers:119:18)
    at /Users/cewong2/PegaScape/start.js:392:2
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Node.js v18.18.0

I’m not sure I can downgrade because this machine also hosts Homebridge which always asks to update node.js
 

SrJeff

New Member
Newbie
Joined
Mar 22, 2024
Messages
2
Trophies
0
Age
22
XP
44
Country
Bolivia
Hey guys, since my router is apparently so old that I can't even host PegaScape with it, I tried hosting it on a server. I have almost 0 experience hosting a page with a server, but tried it anyway since it was my only option left. I used a 1gb RAM VM with ubuntu from Alibaba Cloud. It installed with no problems. I opened ports 80 and 53. At first it didn't start due to systemd-resolved using port 53, but instead of disabling it, I just followed a guide to move it from that port, since i know the service is used to resolve hostnames and dns, and it will probably be needed to host PegaScape from an external server, and it started normally.

1711768971370.png

I tried to connect using the VM's public IP, but I wasn't able to open the website from an external computer, and when trying to join from my switch, it takes a long time to connect and finally shows an error saying the connection timed out, so it actually tries to connect to the page but can't get to it.
1711769096144.jpeg
1711769109886.jpeg

I don't know what the problem is really, maybe it has something to do with the VM being located literally in Singapore. Any ideas of what i'm missing?
 
Last edited by SrJeff,

cewong2

Member
Newcomer
Joined
Jul 14, 2008
Messages
11
Trophies
1
XP
84
Country
United States
I tried to see if I could use this on the Mac since I was having a similar issue if the nodes not installing but I get this error:

Since I can’t use the bat I just run the command directly with sudo

I get the following error:

Code:
(node:59987) [DEP0128] DeprecationWarning: Invalid 'main' field in '/Users/cewong2/PegaScape/node_modules/mold-source-map/package.json' of 'mold-source-map.js'. Please either fix that or report it to the module author
(Use `node --trace-deprecation ...` to show where the warning was created)
Responding with address 192.168.1.227
Switch DNS IP: 192.168.1.227

/Users/cewong2/PegaScape/node_modules/repl.history/index.js:19
  repl.rli.addListener('line', function(code) {
           ^

TypeError: Cannot read properties of undefined (reading 'addListener')
    at module.exports (/Users/cewong2/PegaScape/node_modules/repl.history/index.js:19:12)
    at Object.<anonymous> (/Users/cewong2/PegaScape/repl.js:161:1)
    at Module._compile (node:internal/modules/cjs/loader:1256:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Module._load (node:internal/modules/cjs/loader:960:12)
    at Module.require (node:internal/modules/cjs/loader:1143:19)
    at require (node:internal/modules/cjs/helpers:119:18)
    at /Users/cewong2/PegaScape/start.js:392:2
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Node.js v18.18.0

I’m not sure I can downgrade because this machine also hosts Homebridge which always asks to update node.js
So I’m just going to update here I was able to get it to work it seems that this will only work with an older version of Node. I used NVM to install Node 9.11.2 (automatically comes with NPM 5.6.0). It switched to it automatically so I ran NPM Install and it worked perfectly. I couldn’t use the batch command specifying the up address so I just ran “node start.js” and it used my Mac’s internal Ip address and it worked fine. I assume “node start.js - - webapplet” would work as well but I was using caffeine since fake news never worked for me at all.

After I got the switch up and running I exited the server (.exit) and just instructed NVM to use system version again (which was what was running before).
 
  • Like
Reactions: impeeza

veesonic

Member
Newcomer
Joined
Aug 18, 2019
Messages
20
Trophies
0
Age
44
XP
468
Country
United States
I'm somewhat tech savvy but I get pretty lost when doing anything command prompt, terminal, or linux related. I was able to follow this tutorial and get Pegascape Self Hosting working on Windows 10. I made some adjustments on what I needed to get it working, you can follow the original post and refer to my reply to see my adjustments. B-)

https://gbatemp.net/threads/pegascape-self-hosting-in-windows-10.652216/post-10392861
 

andyapple

New Member
Newbie
Joined
Apr 9, 2024
Messages
1
Trophies
0
Age
22
XP
2
Country
Italy
Hi, is there another solution other than self host? thanks
or an alternative to pegascape (can't use jig)

Thanks,
andyapple
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Psionic Roshambo @ Psionic Roshambo: grilled lol