Running Python Code in a stack?

Super new to Coding, but trying to run a bit of python code in a stack or a smart window…
its a small application or action that send a request and retrieves a file from an outside server.

Any advice on how best to tackle this? I know this is a big ask So I humble thank you in advance.

Never tried, but you could try adding a text-stack, paste the script in it and select all text. Choose “Ignore formatting” from the menu. Cross your fingers, publish your project to a web server that has Python active (as it will not do anything in preview) and observe…

any code that can respond to http requests can run on a server and be part of a web application. python is no exception. this forum Discourse, if i’m not mistaken, is a python web app.

but rapidweaver isn’t really a tool for building Python or Node apps. it build web pages. those pages can be dynamic with front end scripts: but those scripts must be in JS. that’s all browsers know. and rapidweaver can build some back end stuff using php. but that’s just because most web servers like Apache and Nginx generally run php inline.

You could use RW purely for upload: add you python as a Resource. Let RW upload it to your server, but there are some major issues:

  1. You probably shouldn’t run the web application from a directory that’s visible from your web server (which is where RW would put it of course)

  2. You’d still have to set up the rest of the web app server details by hand.

In other words, I suspect that for all intents and purposes RW isn’t going to help you much in running a python web app.

If you want to use RW stick to JS and PHP.

If you want to to make a back end web app (in any language) you should probably deploy that in more traditional ways.

Isaiah

2 Likes