Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Terry Reedy
On 3/25/2017 11:40 AM, Kyle Lahnakoski wrote: Pavel, I like PythonQL. I perform a lot of data transformation, and often find Python's list comprehensions too limiting; leaving me wishing for LINQ-like language features. As an alternative to extending Python with PythonQL, Terry Reedy

Re: [Python-ideas] Adding an 'errors' argument to print

2017-03-25 Thread Michel Desmoulin
Le 24/03/2017 à 17:37, Victor Stinner a écrit : > *If* we change something, I would prefer to modify sys.stdout. The > following issue proposes to add > sys.stdout.set_encoding(errors='replace'): > http://bugs.python.org/issue15216 > > You can already set the PYTHONIOENCODING environment

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Michel Desmoulin
Hello, I've been following PythonQL with interest. I like the clever hack using Python encoding. It's definitely not something I would recommend to do for an inclusion in Python as it hijack the Python encoding method, which prevent your from... well choosing an encoding. And requires to have a

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread David Mertz
I think it's extraordinarily unlikely that a big change in Python syntax to support query syntax will ever happen. Moreover, I would oppose such a change myself. But just a change also really is not necessary. Pandas already abstracts all the things mentioned using only Python methods. It is

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Mark E. Haase
Hi Pavel, This is a really impressive body of work. I had looked at this project in the past but it is great to get back up to speed and see all the progress made. I use Python + databases almost every day, and the major unanswered question is what benefit does dedicated language syntax have

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Nick Coghlan
First off, I think PythonQL (and PonyORM before it) is a very interesting piece of technology. However, I think some of the answers so far suggest we may need to discuss a couple of meta-issues around target audiences and available technical options before continuing on. I'm quoting Gerald's post

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Kyle Lahnakoski
Pavel, I like PythonQL. I perform a lot of data transformation, and often find Python's list comprehensions too limiting; leaving me wishing for LINQ-like language features. As an alternative to extending Python with PythonQL, Terry Reedy suggested interpreting a DSL string, and Pavel Velikhov

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Gerald Britton
> > On 25 March 2017 at 11:24, Pavel Velikhov > wrote: > > No, the current solution is temporary because we just don’t have the > > manpower to > > implement the full thing: a real system that will rewrite parts of > PythonQL > > queries and > > ship them to underlying databases. We need a real

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Pavel Velikhov
Hi Paul! > On 25 March 2017 at 11:24, Pavel Velikhov wrote: >> No, the current solution is temporary because we just don’t have the >> manpower to >> implement the full thing: a real system that will rewrite parts of PythonQL >> queries and >> ship them to underlying

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Pavel Velikhov
> On 25 Mar 2017, at 10:58, Brice PARENT wrote: > > Hello! > > Hello! > If I had to provide a unified way of dealing with data, whatever its source > is, I would probably go with creating an standardized ORM, probably based on > Django's or PonyORM, because: > > - it

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Paul Moore
On 25 March 2017 at 11:24, Pavel Velikhov wrote: > No, the current solution is temporary because we just don’t have the > manpower to > implement the full thing: a real system that will rewrite parts of PythonQL > queries and > ship them to underlying databases. We need

Re: [Python-ideas] Proposal: Query language extension to Python (PythonQL)

2017-03-25 Thread Pavel Velikhov
> On 25 Mar 2017, at 02:19, Greg Ewing wrote: > > Terry Reedy wrote: >> PQL expressions should be quoted and passed to the dsl processor, as done >> with SQL and other DSLs. > > But embedding one language as quoted strings inside another > is a horrible way to