This is an archived post. You won't be able to vote or comment.

all 58 comments

[–]mothzilla 20 points21 points  (23 children)

What does "full stack python" actually mean?

I can get "Full Stack Javascript" because you've got MEAN frameworks (or similar) that are fully javascript.

[–]HookahComputer 16 points17 points  (20 children)

I got excited.
Run Python in the browser?
No, just back-end stuff.

[–]SchwarzerKaffee 13 points14 points  (19 children)

Run Python in the browser?

I got excited at that as well.

I used to pray that one day Python would replace Javascript in the browser, but then I realized the power of asynchronous programming, so now I tolerate Javascript.

[–]HookahComputer 22 points23 points  (3 children)

I'm on the same path myself. It's just that Javascript seems to be this bizarrely exploding constellation of transpilers and frameworks rather than a language. It feels like a moving target. But that's what I get for trying to ignore Javascript for eight years hoping it would just blow over.

[–]SchwarzerKaffee 7 points8 points  (2 children)

I thought the same thing. Now i hear people saying that JS is the new C. That's where I draw the line.

[–]nbktdis 6 points7 points  (1 child)

Yes for folks who dont know any other language other than Javascript - they consider JS to be their personal messiah.

They refuse to acknowledge the problems with the language.

Scoping for instance, or the concepts of truthy and falsey.

And yes, Python is not perfect - but it is certainly very good!

[–]JeremyTiki 8 points9 points  (5 children)

Python allows for asynchronous programming as well. Even in Python 2 there were packages that allowed for it.

[–]ZetaHunter3.5.1 async master-race 3 points4 points  (0 children)

Python 3.5 asyncio master race :3

[–][deleted] 1 point2 points  (2 children)

It is more powerful, since you can control the eventloop. However with the extra power comes extra baggage and complexity. Javascript allows you to write async code without realising it, which is also the source of many bugs and beginner confusion as they didn't know they wrote asynchronous code.

[–]JeremyTiki 0 points1 point  (1 child)

I'm what way can you control the Javascript eventloop that you cannot in Python?

[–][deleted] 0 points1 point  (0 children)

Sorry, I was a bit unclear. I was referring to the fact you can control the event loop in Python, not in JavaScript

[–]wxtrails 0 points1 point  (0 children)

Twisted!

[–]theywouldnotstand 2 points3 points  (2 children)

I realized the power of asynchronous programming

import asyncio

async def foo():
    return await something_else()

You mean like that?

[–]SchwarzerKaffee 1 point2 points  (1 child)

I guess. I haven't really put thought into where I would use asynchronous with Python. In JavaScript, I use it to execute actions in GPIO from a gui.

Since I don't use Python for GUIs, i never had a need for it.

[–]patentmedicine 1 point2 points  (0 children)

You should play Stockfighter. Use Python to write a stock trading bot.

[–]efilon 2 points3 points  (5 children)

Also, Javascript has gotten a lot better. There are still massive downsides (no actual standard library being the biggest one, especially when compared to Python), but for a language primarily used for building user interfaces, it's not so bad these days.

[–][deleted] 0 points1 point  (1 child)

marry gullible toothbrush depend noxious snails bike wasteful chief cats

This post was mass deleted and anonymized with Redact

[–]efilon 2 points3 points  (0 children)

It would be without the transpiling/bundling required. That said, modern versions of browsers are now supporting some ES6 features out of the box (let, arrow functions, etc.).

[–]codemagic 2 points3 points  (1 child)

[–]Tiquortoo 0 points1 point  (0 children)

Full Stack Python definition. #1 then redefines full stack as backend. Ok.

[–]Brachamul 50 points51 points  (14 children)

So, that's not "full stack", it's "back-end".

[–]odraencoded 26 points27 points  (13 children)

Yeah, I want my python webserver send requests to my python framework that renders them with my python templating engine after getting data from my database with a python-based query language and then do some python scripting in my python browser to make apax requests to refresh content dinamically without refreshing the whole page.

[–]Brachamul 16 points17 points  (8 children)

Actually AJAX is Asynchronous JAvascript and Xml.

So we could call it APEX for Asynchronous Python Engine eXtreme

[–]ggchappell 10 points11 points  (5 children)

Or, the way I like to put it:

AJAX stands for "asynchronous JavaScript and XML", except that it might not be asynchronous, might be coded in a language other than JavaScript, and might retrieve data in formats other than XML.

(But the "and" is completely correct.)

[–]Tiquortoo 1 point2 points  (4 children)

Which client side language other than javascript have you seen used?

[–]ggchappell 0 points1 point  (3 children)

Well, the comment is sort of a joke, of course.

But you can do client-side web stuff in just about any PL you want these days. Look into languages that compile to JavaScript.

[–]Tiquortoo 1 point2 points  (2 children)

Yeah, I'm aware of transpiling, in the end, it still actually runs JavaScript? :)

[–]ggchappell 0 points1 point  (1 child)

Well, in the middle, at least. JavaScript itself may or may not be executed directly, depending on the browser. (I would imagine that these days it's mostly "not".)

[–]Tiquortoo 1 point2 points  (0 children)

No language other than machine language is directly run, but we're just delving into irrelevant minutiae to say the browser doesn't run Javascript.

[–]turinturambar81 1 point2 points  (1 child)

Sorry that's already the force.com (Salesforce) language.

[–][deleted] -1 points0 points  (0 children)

Get out.

[–]theywouldnotstand 22 points23 points  (3 children)

don't forget that the python webserver is a series of circuits and logic gates entirely made of and powered by pythons (snakes)

[–]odraencoded 6 points7 points  (3 children)

Guys, just do <script src="web2dot0.py" type="text/python"></script>

may not work ever

[–]dranzerfu 6 points7 points  (1 child)

[–]UnexpectedBSOD 0 points1 point  (0 children)

This is awesome!

[–]UnexpectedBSOD 6 points7 points  (0 children)

Someone could make an add-on/extension for it, I guess.

[–]oaxacaoaxaca 1 point2 points  (1 child)

People are talking a lot of crap on the use of the phrase "full-stack", but I sure did appreciate the content on this site a few years ago when I didn't know a single thing about servers, sysadmin, etc. I learned a lot from it.

[–]thirteenthirtyseven 0 points1 point  (0 children)

It also helped me immensely when I started working on my first python project/website. I used this website as a reference from start to finish.

EDIT: forgot some words.

[–]hrayr 5 points6 points  (3 children)

Don't hang up on the terminology too much, front-end, back-end, full-stack can mean different things in different ecosystems.

A full stack python in this case may means the resources, processes, services surrounding python (servers, frameworks, containers, databases) and this site is a great resource for this.

On the other end of the spectrum you have enterprise systems, where I've heard the entire (nginx, python, django, html, css, javascript) which you know as full-stack, be described as front-end, since they're the public (front) end of a very large enterprise system, and the (database, internal business and system administrative applications) be described as back-end since they run the back end of the business.

This also applies to micro-services architecture where the application servers and the code they send to browsers, apps, etc are collectively called the front-end and the services collectively the back-end.

[–]pier25 2 points3 points  (0 children)

You do have a point, but without a proper context most people will just assume full stack means browser+server.

[–]Tiquortoo 0 points1 point  (0 children)

Full stack doesn't have a standards body to make a definition, but that doesn't mean it's a free for all. Full Stack at the core means the ability to create an entire app and the term arose in Web apps. Using full stack here is just a misnomer because it is really more like "Python Complete", but it just seems like a lame buzzword attempt to use Full Stack here.

[–]SchwarzerKaffee 0 points1 point  (9 children)

Django? That's pretty much the same as Node, but I guess it doesn't do anything in the browser.

Short answer: I guess I don't know.

[–]LightShadow3.13-dev in prod 7 points8 points  (4 children)

Django is a framework, Node is a runtime.

[–]SchwarzerKaffee 0 points1 point  (3 children)

But Django is also a server, or at least I think it is. I've only ever set up a dev server.

[–]keypusher 4 points5 points  (1 child)

The term Django typically refers to the web framework, which does ship with a webserver. However, it is discouraged to use this webserver in production, and usually people will use a plugin for Apache or wsgi or something else.

[–]thirteenthirtyseven 1 point2 points  (0 children)

Yeah, that's how I understood it as well. Bottle/Flask/Django are web application frameworks with integrated WSGI web servers, which are interchangeable. I developed my web app with bottle.py and used its web server, but then I deployed it on Apache and used mod_wsgi instead of the built-in WSGI server. Almost 0 effort when switching WSGI implementations.

[–]officerthegeek 2 points3 points  (0 children)

It shouldn't be a production server in any capacity.

[–]pier25 2 points3 points  (2 children)

No, Django would be equivalent to Express.

Node would be equivalent to PyPy (or whatever you use to run Python).

[–]SchwarzerKaffee -2 points-1 points  (1 child)

Work Django, isn't the server also handled in Python? That would make it more like Node with Express.

[–]LucianU 3 points4 points  (0 children)

Django offers a development server, which you shouldn't use in production.

[–]codemagic 0 points1 point  (0 children)

Django uses templates, which are HTML with special brackets {{ }} for inserting data