Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #100119

Re: Understanding Python from a PHP coder's perspective

Path csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail
From Cameron Simpson <cs@zip.com.au>
Newsgroups comp.lang.python
Subject Re: Understanding Python from a PHP coder's perspective
Date Tue, 8 Dec 2015 10:07:19 +1100
Lines 19
Message-ID <mailman.40.1449531408.12405.python-list@python.org> (permalink)
References <3e30fc58-4460-40a6-a639-22cd4d406f0b@googlegroups.com>
Reply-To python-list@python.org
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii; format=flowed
X-Trace news.uni-berlin.de U8GZzh+3e3xJ1KMcPuhlaADLBSWBU3UR+SLhjUPtwRmA==
Return-Path <cameron@cskk.homeip.net>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.008
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'subject:Python': 0.05; 'plenty': 0.07; 'cc:addr:python-list': 0.09; 'normally,': 0.09; 'php,': 0.09; '>in': 0.16; 'from:addr:cs': 0.16; 'from:addr:zip.com.au': 0.16; 'from:name:cameron simpson': 0.16; 'message-id:@cskk.homeip.net': 0.16; 'query.': 0.16; 'received:211.29': 0.16; 'received:211.29.132': 0.16; 'received:cskk.homeip.net': 0.16; 'received:homeip.net': 0.16; 'received:io': 0.16; 'received:optusnet.com.au': 0.16; 'received:psf.io': 0.16; 'received:syd.optusnet.com.au': 0.16; 'sessions,': 0.16; 'simpson': 0.16; 'subject:perspective': 0.16; 'wrote:': 0.16; 'app': 0.16; 'memory': 0.17; 'frameworks': 0.18; 'implementing': 0.18; 'cc:2**0': 0.20; 'cc:addr:python.org': 0.20; 'cheers,': 0.22; 'pass': 0.22; 'cc:no real name:2**0': 0.22; 'header:In-Reply-To:1': 0.24; 'header:User-Agent:1': 0.26; '(which': 0.26; 'cookie': 0.29; 'preserve': 0.29; 'storage,': 0.29; 'reset': 0.29; 'typically': 0.29; 'allows': 0.30; 'another': 0.32; 'received:com.au': 0.33; 'structure': 0.34; 'handle': 0.34; 'server': 0.34; 'skip:> 10': 0.35; 'subject:: ': 0.37; 'expect': 0.37; 'charset:us-ascii': 0.37; 'things': 0.38; 'data': 0.39; 'does': 0.39; 'subject:from': 0.39; 'some': 0.40; 'your': 0.60; 'address': 0.61; 'provide': 0.61; 'email addr:gmail.com': 0.62; 'back': 0.62; 'between': 0.65; 'cameron': 0.66; 'header:Reply- To:1': 0.67; 'reply-to:no real name:2**0': 0.71; 'feeling': 0.72; 'state.': 0.72; '"it': 0.84; '>state': 0.84; '>with': 0.84; 'openly': 0.84; 'reply-to:addr:python.org': 0.84; 'different.': 0.91; 'relate': 0.91
Content-Disposition inline
In-Reply-To <3e30fc58-4460-40a6-a639-22cd4d406f0b@googlegroups.com>
User-Agent Mutt/1.5.23 (2014-03-12)
X-Optus-CM-Score 0
X-Optus-CM-Analysis v=2.1 cv=R4L+YolX c=1 sm=1 tr=0 a=kPLexIa+XrsL4mdc8kxeNA==:117 a=kPLexIa+XrsL4mdc8kxeNA==:17 a=ZtCCktOnAAAA:8 a=PO7r1zJSAAAA:8 a=vrnE16BAAAAA:8 a=8AHkEIZyAAAA:8 a=kj9zAlcOel0A:10 a=wUQvQvOEmiQA:10 a=pGLkceISAAAA:8 a=qLfBfzCueIJFVyRyg7IA:9 a=CjuIK1q_8ugA:10
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.20+
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Xref csiph.com comp.lang.python:100119

Show key headers only | View raw


On 07Dec2015 14:27, villascape@gmail.com <villascape@gmail.com> wrote:
>In regards to Chris's statement: "It openly and honestly does NOT reset its 
>state between page requests"
>With PHP, I have sessions to preserve state.  I have a feeling that this is 
>significantly different.  Yes?  How?  Does this somehow relate to how 
>websockets are implemented?

Plenty of things use sessions, and I suspect most frameworks provide handy 
mechanisms to make using them easier. I expect that normally, as with PHP, 
you'd pass a cookie back to the user to track them and store the session state 
either in an in memory data structure (loses state over an app or web server 
restart) or in some persistent storage, typically a database of some kind 
(which also allows another process implementing your app/site to handle the 
state even if it did not issue the original session).

Cannot address your websockets query.

Cheers,
Cameron Simpson <cs@zip.com.au>

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Understanding Python from a PHP coder's perspective villascape@gmail.com - 2015-12-07 13:07 -0800
  Re: Understanding Python from a PHP coder's perspective villascape@gmail.com - 2015-12-07 13:21 -0800
    Re: Understanding Python from a PHP coder's perspective Chris Angelico <rosuav@gmail.com> - 2015-12-08 09:00 +1100
      Re: Understanding Python from a PHP coder's perspective villascape@gmail.com - 2015-12-07 14:27 -0800
        Re: Understanding Python from a PHP coder's perspective Chris Angelico <rosuav@gmail.com> - 2015-12-08 10:09 +1100
          Re: Understanding Python from a PHP coder's perspective villascape@gmail.com - 2015-12-07 17:00 -0800
            Re: Understanding Python from a PHP coder's perspective Chris Angelico <rosuav@gmail.com> - 2015-12-08 14:26 +1100
        Re: Understanding Python from a PHP coder's perspective Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-07 16:10 -0700
        Re: Understanding Python from a PHP coder's perspective Cameron Simpson <cs@zip.com.au> - 2015-12-08 10:07 +1100
        Re: Understanding Python from a PHP coder's perspective Tim Chase <python.list@tim.thechases.com> - 2015-12-07 21:11 -0600
        Re: Understanding Python from a PHP coder's perspective Chris Angelico <rosuav@gmail.com> - 2015-12-08 14:47 +1100
  Re: Understanding Python from a PHP coder's perspective Cameron Simpson <cs@zip.com.au> - 2015-12-08 08:33 +1100
  Re: Understanding Python from a PHP coder's perspective Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-07 14:37 -0700
  Re: Understanding Python from a PHP coder's perspective Chris Angelico <rosuav@gmail.com> - 2015-12-08 08:40 +1100
  Re: Understanding Python from a PHP coder's perspective Terry Reedy <tjreedy@udel.edu> - 2015-12-07 16:53 -0500
  Re: Understanding Python from a PHP coder's perspective Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-07 14:59 -0700
  Re: Understanding Python from a PHP coder's perspective Chris Angelico <rosuav@gmail.com> - 2015-12-08 09:03 +1100
  Re: Understanding Python from a PHP coder's perspective Tim Chase <python.list@tim.thechases.com> - 2015-12-07 16:28 -0600
  Re: Understanding Python from a PHP coder's perspective villascape@gmail.com - 2015-12-07 20:11 -0800
  Re: Understanding Python from a PHP coder's perspective Peter Otten <__peter__@web.de> - 2015-12-08 10:24 +0100
  Re: Understanding Python from a PHP coder's perspective Chris Angelico <rosuav@gmail.com> - 2015-12-08 20:40 +1100

csiph-web