R
Railwayβ€’2y ago
Reubz

Anyway to check the Package.json in a railway project?

I'm working on a Discord Bot project and I am facing a small issue with file uploads. I had it working properly like about 1 or 2 months ago, few days ago I realize it ain't working anymore. Now that I try to fix it I realize there is no errors when I run the Bot directly off my system. But there is a Error only when running the bot off railway. I have checked that the repository and branch being used for auto-deploy is correct. I have also tried deploying directly from my pc using railway up but still the error continues. As far as my understanding goes the error has something to do with the Packages. Some version mismatch or something like that. Is there something that can be done to check what's wrong with the Railway deployment??
21 Replies
Percy
Percyβ€’2y ago
Project ID: c3e20774-5cde-495e-be6a-52058cee044b
Reubz
ReubzOPβ€’2y ago
c3e20774-5cde-495e-be6a-52058cee044b
luna
lunaβ€’2y ago
Is this what you're hitting by chance?
TypeError channel.isTextBased/channel.isText is not a function
Reubz
ReubzOPβ€’2y ago
if not Package.json any other way to diagnose the issue
Reubz
ReubzOPβ€’2y ago
nope
luna
lunaβ€’2y ago
simply-xp had a commit somewhat recently, was this when it stopped working? πŸ€” https://github.com/Rahuletto/simply-xp/commits/main
Reubz
ReubzOPβ€’2y ago
I'm not able to figure out where the error lies because this error doesn't come when run on my pc, the error only comes on Railway Deployment. Which is very weird.
luna
lunaβ€’2y ago
You're using a lock file correct?
Reubz
ReubzOPβ€’2y ago
nope I am running a very old version of simply-xp one of the original versions that I forked
luna
lunaβ€’2y ago
πŸ€” Whats your package.json look like?
Reubz
ReubzOPβ€’2y ago
luna
lunaβ€’2y ago
unrelated but... why is fs installed as a package? same as why is node added as a package? your package.json says differently... im going to guess the range you have listed there allowed it to update to the new beta i mentioned before.
Reubz
ReubzOPβ€’2y ago
I have this same question to myself. This is a very old project that I started back when I was complete newbie. I probably might have seen some tutorial and installed it. I can't be bothered fixing this or updating to new djs version or anything, as long as it works it works type of thing. I am just maintaining this with small fixes here and there thats it
luna
lunaβ€’2y ago
id say this is likely the issue
Reubz
ReubzOPβ€’2y ago
How do I restrict it to the version I want then?
luna
lunaβ€’2y ago
Remove the ^ at the start.
Reubz
ReubzOPβ€’2y ago
ok cool will try this
luna
lunaβ€’2y ago
youll need to do that and then run npm i to generate a new lock file. actually might need to delete node_modules and then do that.
Reubz
ReubzOPβ€’2y ago
cant I just npm uninstall simply-xp and re-download to fix?
luna
lunaβ€’2y ago
yeah that'll do the same thing basically
Reubz
ReubzOPβ€’2y ago
gotcha trying this ayo thanks man removing the ^ fixed it <3
Want results from more Discord servers?
Add your server