R
Railwayā€¢10mo ago
Iceman

Railway run not working

Hi, I'm trying to run a local command in visual studio code: railway run python manage.py createsuperuser Every time I run it, I get "Looking good? Run railway up to deploy your changes!" which is clearly not what I'm looking for. Could you please let me know how to fix this?
140 Replies
Percy
Percyā€¢10mo ago
Project ID: 417ca85f-12e5-4478-94a0-e5e37273290f
Iceman
Icemanā€¢10mo ago
417ca85f-12e5-4478-94a0-e5e37273290f
Brody
Brodyā€¢10mo ago
can you show a screenshot please
Iceman
Icemanā€¢10mo ago
Brody
Brodyā€¢10mo ago
upon success, what should the output of the create superuser command be?
Iceman
Icemanā€¢10mo ago
Iceman
Icemanā€¢10mo ago
should be like that
Brody
Brodyā€¢10mo ago
run the command in railway shell instead also, what terminal is this
Iceman
Icemanā€¢10mo ago
mac
Iceman
Icemanā€¢10mo ago
Iceman
Icemanā€¢10mo ago
i had it working before but it's stopped working now
Brody
Brodyā€¢10mo ago
just simply type railway shell press enter, than run the python command doesnt really answer the question lol
Iceman
Icemanā€¢10mo ago
No service linked, not entering shell.
Brody
Brodyā€¢10mo ago
link a service railway service i can recommend you take a look at railway -help
Iceman
Icemanā€¢10mo ago
I got into the shell but nothing is happenign
Brody
Brodyā€¢10mo ago
screenshot please
Iceman
Icemanā€¢10mo ago
Iceman
Icemanā€¢10mo ago
bash i think
Brody
Brodyā€¢10mo ago
zsh is the answer
Iceman
Icemanā€¢10mo ago
zsh yeah not a terminal expert lol
Brody
Brodyā€¢10mo ago
python manage.py createsuperuser --verbosity 3 see if that prints anything usefull
Iceman
Icemanā€¢10mo ago
it didn't from within the shell?
Brody
Brodyā€¢10mo ago
yes from within railway shell
Iceman
Icemanā€¢10mo ago
didn't work
Iceman
Icemanā€¢10mo ago
Brody
Brodyā€¢10mo ago
it doesnt look like you ran the command in the railway shell
Iceman
Icemanā€¢10mo ago
4th line i did
Iceman
Icemanā€¢10mo ago
Brody
Brodyā€¢10mo ago
well im out of ideas lol
Iceman
Icemanā€¢10mo ago
yeah, same here so what am I supposed to do? do you work for railway?
Brody
Brodyā€¢10mo ago
google, or wait for someone with more experience with django to come along, since im not even a python dev negative
Iceman
Icemanā€¢10mo ago
jesus I thought you worked for them lol
Brody
Brodyā€¢10mo ago
common mistake, dont worry
Iceman
Icemanā€¢10mo ago
I think I'm gonna pull the whole project down and start again
Brody
Brodyā€¢10mo ago
thats a little drastic
Iceman
Icemanā€¢10mo ago
this worked 3 weeks ago and today it's not working at all
Brody
Brodyā€¢10mo ago
im sure its something simple have you updated the cli in the last 3 weeks?
Iceman
Icemanā€¢10mo ago
I'm moving it all onto aws next week anyway so it's not a big deal
Brody
Brodyā€¢10mo ago
i dont want to hear that lol
Iceman
Icemanā€¢10mo ago
just wanted to do some quick tests before i start to splurge
Brody
Brodyā€¢10mo ago
why aws over railway?
Iceman
Icemanā€¢10mo ago
This app is nice for hobby projects I rate(d) it until this happened I need a korean server these guys only have us ones
Brody
Brodyā€¢10mo ago
ah okay thats fair
Iceman
Icemanā€¢10mo ago
targeting the chinese market
Brody
Brodyā€¢10mo ago
yeah that makes sense
Iceman
Icemanā€¢10mo ago
so it's pretty useless for me and I need to deploy my static files better probably in a cdn
Brody
Brodyā€¢10mo ago
thats a good idea
Iceman
Icemanā€¢10mo ago
like i said, heroku and railway are great for fun projects and testing just not practical for when you're trying to make a living and spending a shitload in ad spend what do use this app for?
Brody
Brodyā€¢10mo ago
im not a developer by profession so just side projects
Iceman
Icemanā€¢10mo ago
what languages do you use?
Brody
Brodyā€¢10mo ago
mainly Go
Iceman
Icemanā€¢10mo ago
you seem like a developer just Go? Never used that one kinda niche isn't it?
Brody
Brodyā€¢10mo ago
yeah pretty much just Go more niche than python, yeah
Iceman
Icemanā€¢10mo ago
unusual starter language the problem with the smaller languages is that you have to do more work with the bigger ones, someone has already thought of it so you can just piggyback them
Brody
Brodyā€¢10mo ago
i dont follow, starter language?
Iceman
Icemanā€¢10mo ago
a first programming language
Brody
Brodyā€¢10mo ago
its not my first, not at all
Iceman
Icemanā€¢10mo ago
or you just prefer it
Brody
Brodyā€¢10mo ago
yes just prefer it now a days
Iceman
Icemanā€¢10mo ago
ah ok, got the wrong end of the stick you tried Rust? supposed to be the best one now in terms of speed
Brody
Brodyā€¢10mo ago
nah i have no intrest in rust, if you need the extra speed rust can provide over go, you are either a multi million/billion dollar company or doing something very wrong
Iceman
Icemanā€¢10mo ago
Got a feeling there's a bug somewhere Just pulled it all down and started again but still getting the same error
Brody
Brodyā€¢10mo ago
i really dont know what would cause that, sorry
Iceman
Icemanā€¢10mo ago
i can only think that they changed something on their end as this was working up until today with pretty much the same code
Brody
Brodyā€¢10mo ago
?
Iceman
Icemanā€¢10mo ago
No What difference would that make?
Brody
Brodyā€¢10mo ago
maybe there was a breaking change introduced in the cli this command is ran locally though, it doesn't really have much to do with "their end"
Iceman
Icemanā€¢10mo ago
this mac is kinda old, i'm trying to avoid updating it as Apple keep charging for new stuff every time you do an update
Brody
Brodyā€¢10mo ago
lol
Iceman
Icemanā€¢10mo ago
basically stuff just stops working every time you update especially pirated stuff if you buy a new laptop then it kinda makes sense to start again but not with an old one lol
Brody
Brodyā€¢10mo ago
can you show me a screenshot of your service variables
Iceman
Icemanā€¢10mo ago
Brody
Brodyā€¢10mo ago
delete DATABASE_URL and then add all the variable references for your database like the popup wants you to and show me another screenshot after that please
Iceman
Icemanā€¢10mo ago
Good thinking batman I didn't even spot that reminder it takes like ten minutes to redeploy though
Brody
Brodyā€¢10mo ago
damn why
Iceman
Icemanā€¢10mo ago
dunno maybe coz i"m using a VPN the server is in the US
Brody
Brodyā€¢10mo ago
do you deploy from github?
Iceman
Icemanā€¢10mo ago
a bit of both this one is going through github
Brody
Brodyā€¢10mo ago
then once it's in the build phase it has nothing to do with your connection
Iceman
Icemanā€¢10mo ago
how long should it take?
Brody
Brodyā€¢10mo ago
not 10 minutes, you are probably using like 24 dependencies
Iceman
Icemanā€¢10mo ago
this website has a shitload of dependencies like 69
Brody
Brodyā€¢10mo ago
yeah then you did that to yourself lol
Iceman
Icemanā€¢10mo ago
I didn't intend to the dependencies downloaded their own dependencies
Brody
Brodyā€¢10mo ago
more things to download and install = longer build times you'll have that so screenshot of the service variables please?
Iceman
Icemanā€¢10mo ago
plus I have to offer the functionality
Iceman
Icemanā€¢10mo ago
Iceman
Icemanā€¢10mo ago
that warning has gone
Brody
Brodyā€¢10mo ago
yeah but you didn't do what I said
Iceman
Icemanā€¢10mo ago
That's what it asked me to do
Brody
Brodyā€¢10mo ago
only part of it ^
Iceman
Icemanā€¢10mo ago
Iceman
Icemanā€¢10mo ago
add the lot?
Brody
Brodyā€¢10mo ago
yes it can't hurt
Iceman
Icemanā€¢10mo ago
jesus, this is so vague
Brody
Brodyā€¢10mo ago
what is
Iceman
Icemanā€¢10mo ago
Iceman
Icemanā€¢10mo ago
how about this?
Brody
Brodyā€¢10mo ago
good
Iceman
Icemanā€¢10mo ago
ok, it's redeploying just everything
Brody
Brodyā€¢10mo ago
run railway variables to make sure all variables are available to the cli
Iceman
Icemanā€¢10mo ago
the lack of error messages etcs
Brody
Brodyā€¢10mo ago
from createsuperuser?
Iceman
Icemanā€¢10mo ago
yeah, that it fails silently
Brody
Brodyā€¢10mo ago
i mean not railway's fault
Iceman
Icemanā€¢10mo ago
just annoying
Brody
Brodyā€¢10mo ago
i agree there
Iceman
Icemanā€¢10mo ago
just rather it told me straight up what the problem was although most error messages are crap anyway
Brody
Brodyā€¢10mo ago
that would be ideal
Iceman
Icemanā€¢10mo ago
you sure this is right?
Brody
Brodyā€¢10mo ago
no im not just checked, that is the correct command that i want you to run
Iceman
Icemanā€¢10mo ago
yeah, they're there but can't send you a screenshot on here coz they're all exposed
Brody
Brodyā€¢10mo ago
thats all that matters wanna go back into the railway shell and run that python command again?
Iceman
Icemanā€¢10mo ago
Iceman
Icemanā€¢10mo ago
shit it's not having it i'm beat
Iceman
Icemanā€¢10mo ago
Django Tutorial Part 11: Deploying Django to production - Learn web...
That's the end of this tutorial on setting up Django apps in production, and also the series of tutorials on working with Django. We hope you've found them useful. You can check out a fully worked-through version of the source code on GitHub here.
Iceman
Icemanā€¢10mo ago
it's pretty clear that that's the command Pretty sure this something on their end now unless it's failing silently which is still an error on their end guess this is what you get for 5 bucksšŸ˜‹
Brody
Brodyā€¢10mo ago
again, this command is ran locally, its on your end
Adam
Adamā€¢10mo ago
has nothing to do with Railway Railway just allows you to host your programs. So far, all you two have been working on here is local you havenā€™t touched Railway yet
Iceman
Icemanā€¢10mo ago
eh?
Brody
Brodyā€¢10mo ago
this is a local terminal and a local shell
Adam
Adamā€¢10mo ago
all this Railway shell stuff isnā€™t run on Railway. Itā€™s porting the env variables to your terminal and using them for whatever command youā€™re running Personally, Iā€™m not a fan of the CLI. The Github integration is more than enough for me If youā€™re having issues, try using Github
Iceman
Icemanā€¢10mo ago
so what happens when you start with "railway" ? thats not local
Adam
Adamā€¢10mo ago
Railway imports your serviceā€™s env variables to your pc, then the command is run with those env variables in place itā€™s local
Iceman
Icemanā€¢10mo ago
This is the mozilla django guide
Iceman
Icemanā€¢10mo ago
doesn't work did do now doesn't
Adam
Adamā€¢10mo ago
back to square one I see
Brody
Brodyā€¢10mo ago
you have changed something
Adam
Adamā€¢10mo ago
going to need more info the guide looks straightforward to me. Chances are youā€™ve changed something
Iceman
Icemanā€¢10mo ago
dunno what Looking good? Run railway up to deploy your changes! that;s all i get back it's like just the run method doesn't work
Brody
Brodyā€¢10mo ago
echo $SHELL run that
Iceman
Icemanā€¢10mo ago
/bin/zsh to be fair, I've changed a lot since the last site I uploaded but I wasn't expecting to get stuck on something as basic as this just trying to create a superuser i don't even know a workaround
Iceman
Icemanā€¢10mo ago
wrong folder mildpanic
Brody
Brodyā€¢10mo ago
bruh šŸ¤¦ā€ā™‚ļø and you where blaming it on railway, lets not jump to conclusions next time
Iceman
Icemanā€¢10mo ago
oh come on what sort of error message is that? I was in the upload folder
Brody
Brodyā€¢10mo ago
it seems like you still think the missing error message is railway's fault
Iceman
Icemanā€¢10mo ago
I had to come out cd .. out of it i do
Brody
Brodyā€¢10mo ago
its not
Iceman
Icemanā€¢10mo ago
I'm a stickler for error messages it doesnt make any sense I had to come out of the actual folder to get it to work
Brody
Brodyā€¢10mo ago
closing now