Re: The hardest problem in computer science...

2017-01-06 Thread Steve D'Aprano
On Sat, 7 Jan 2017 12:03 am, Steve D'Aprano wrote: > The second hardest problem in computer science is cache invalidation. > > The *hardest* problem is naming things. Thanks everyone who answered, but I think some of you misunderstood my question. I know that the individual characters themselves

Re: Search a sequence for its minimum and stop as soon as the lowest possible value is found

2017-01-06 Thread Rustom Mody
On Saturday, January 7, 2017 at 12:26:04 PM UTC+5:30, Jussi Piitulainen wrote: > Paul Rubin writes: > > > Peter Otten writes: > >> How would you implement stopmin()? > > > > Use itertools.takewhile > > How? It consumes the crucial stop element: > >it = iter('what?') >list(takewhile(str.i

Re: Search a sequence for its minimum and stop as soon as the lowest possible value is found

2017-01-06 Thread Jussi Piitulainen
Paul Rubin writes: > Peter Otten writes: >> How would you implement stopmin()? > > Use itertools.takewhile How? It consumes the crucial stop element: it = iter('what?') list(takewhile(str.isalpha, it)) # ==> ['w', 'h', 'a', 't'] next(it, 42) # ==> 42 -- https://mail.python.org/mailman/

RE: Namedtuples: TypeError: 'str' object is not callable

2017-01-06 Thread Deborah Swanson
Chris Angelico wrote, on January 06, 2017 9:14 PM > > On Sat, Jan 7, 2017 at 4:07 PM, Deborah Swanson > wrote: > > > > I really don't know how long it would've taken me to think of that, so > > thank you! > > I have a well-trained crystal ball :) > > ChrisA More like a very experienced eye.

Re: Namedtuples: TypeError: 'str' object is not callable

2017-01-06 Thread Chris Angelico
On Sat, Jan 7, 2017 at 4:07 PM, Deborah Swanson wrote: > And you would be precisely correct. I have a variable named 'map', and I > intended to delete it and the code that used it, but totally forgot > about it. It's still in there somewhere, but a simple search will find > it. > > I really don't

RE: Namedtuples: TypeError: 'str' object is not callable

2017-01-06 Thread Deborah Swanson
Chris Angelico wrote, on January 06, 2017 8:05 PM > To: python-list@python.org > Subject: Re: Namedtuples: TypeError: 'str' object is not callable > > > On Sat, Jan 7, 2017 at 2:46 PM, Deborah Swanson > wrote: > > And here's the Traceback in PyCharm: > > File "E:/Coding projects/Pycharm/Movin

Re: Namedtuples: TypeError: 'str' object is not callable

2017-01-06 Thread Chris Angelico
On Sat, Jan 7, 2017 at 2:46 PM, Deborah Swanson wrote: > And here's the Traceback in PyCharm: > File "E:/Coding projects/Pycharm/Moving/moving_numberedtuples.py", > line 139, in moving() > for lst in map(listings._make, csv.reader(open('E:\\Coding > projects\\Pycharm\\Moving\\Moving 2017 in.

Namedtuples: TypeError: 'str' object is not callable

2017-01-06 Thread Deborah Swanson
I'm not sure what Python is complaining about here, or why. Here's the example from the Python docs: https://docs.python.org/3/library/collections.html#collections.namedtupl e EmployeeRecord = namedtuple('EmployeeRecord', 'name, age, title, department, paygrade') import csv for emp in map(Empl

Re: The hardest problem in computer science...

2017-01-06 Thread Larry Hudson via Python-list
On 01/06/2017 05:03 AM, Steve D'Aprano wrote: The second hardest problem in computer science is cache invalidation. The *hardest* problem is naming things. In a hierarchical tree view widget that displays items like this: Fiction ├─ Fantasy │ ├─ Terry Pratchett │ │ ├─ Discw

Re: Using sudo with pip3?

2017-01-06 Thread Cameron Simpson
On 06Jan2017 23:03, Clint Moyer wrote: Packages supplied by your distribution can be trusted more than packages from PyPi. Just my two cents. Most distros offer nearly all the useful Python modules directly from the repo. I would agree with this on the whole. And also that it is generally bett

Re: The hardest problem in computer science...

2017-01-06 Thread Mario R. Osorio
On Friday, January 6, 2017 at 8:45:41 PM UTC-5, Mario R. Osorio wrote: > On Friday, January 6, 2017 at 10:37:40 AM UTC-5, Ethan Furman wrote: > > On 01/06/2017 05:03 AM, Steve D'Aprano wrote: > > > > > what do we call the vertical and horizontal line elements? I want to make > > > them configurabl

Re: The hardest problem in computer science...

2017-01-06 Thread Mario R. Osorio
On Friday, January 6, 2017 at 10:37:40 AM UTC-5, Ethan Furman wrote: > On 01/06/2017 05:03 AM, Steve D'Aprano wrote: > > > what do we call the vertical and horizontal line elements? I want to make > > them configurable, which means the user has to be able to pass an argument > > that specifies the

Re: Search a sequence for its minimum and stop as soon as the lowest possible value is found

2017-01-06 Thread Paul Rubin
Peter Otten <__pete...@web.de> writes: > How would you implement stopmin()? Use itertools.takewhile -- https://mail.python.org/mailman/listinfo/python-list

Re: Using sudo with pip3?

2017-01-06 Thread Clint Moyer
>From Ubuntu, why not try: sudo apt-get install python-matplotlib -Clint On Fri, Jan 6, 2017 at 3:09 PM jim wrote: > Setting up a new computer to run Ubuntu 16.04. Started using pip3 to > > install all the python stuff I had on the old machine and got this message: > > > > jfb@jims-1604:~$ sud

crosstab output

2017-01-06 Thread Val Krem via Python-list
Hi all, How do I access the rows and columns of a data frame crosstab output? Here is code using a sample data and output. a= pd.read_csv("cross.dat", skipinitialspace=True) xc=pd.crosstab(a['nam'],a['x1'],margins=True) print(xc) x10 1 nam A13 2 A21 4 I want to create a va

Re: Pexpect

2017-01-06 Thread Cameron Simpson
On 06Jan2017 11:37, Joaquin Alzola wrote: Iranna Mathapati asked: How to match latter(caps and small) ,numbers and # symbol in python pexpect. With a .* Ugh. Please not. Expect() accepts a nongreedy regular expression. ".*" is the lazy "match absolutely anything" pattern. Generally overus

Re: Using sudo with pip3?

2017-01-06 Thread Clint Moyer
Packages supplied by your distribution can be trusted more than packages from PyPi. Just my two cents. Most distros offer nearly all the useful Python modules directly from the repo. Virtual environments are great, but if you want to add libraries to your system interpreter I'd recommend a simple

RE: Receiving a lot of double messages.

2017-01-06 Thread Deborah Swanson
Grant Edwards wrote, on January 06, 2017 1:56 PM > > On 2017-01-05, Antoon Pardon wrote: > > > Is there something going on with the mailinglist? Because I have > > receive a lot > > of double messages. One copy is fairly normal and is part > of the discussion > > thread, the other is complete

Re: Using sudo with pip3?

2017-01-06 Thread cs
On 06Jan2017 15:44, jim wrote: Setting up a new computer to run Ubuntu 16.04. Started using pip3 to install all the python stuff I had on the old machine and got this message: jfb@jims-1604:~$ sudo pip3 install matplotlib [sudo] password for jfb: The directory '/home/jfb/.cache/pip/http' or i

Using sudo with pip3?

2017-01-06 Thread jim
Setting up a new computer to run Ubuntu 16.04. Started using pip3 to install all the python stuff I had on the old machine and got this message: jfb@jims-1604:~$ sudo pip3 install matplotlib [sudo] password for jfb: The directory '/home/jfb/.cache/pip/http' or its parent directory is not owned

Re: Receiving a lot of double messages.

2017-01-06 Thread Grant Edwards
On 2017-01-05, Antoon Pardon wrote: > Is there something going on with the mailinglist? Because I have receive a > lot > of double messages. One copy is fairly normal and is part of the discussion > thread, the other is completely seperated. -- Antoon Pardon. Yep, there are a _lot_ of duplica

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do

2017-01-06 Thread Paul Rudin
Tim Johnson writes: > * Antonio Caminero Garcia [170102 20:56]: >> Guys really thank you for your answers. Basically now I am more >> emphasizing in learning in depth a tool and get stick to it so I >> can get a fast workflow. Eventually I will learn Vim and its >> python developing setup, I kno

RE: Receiving a lot of double messages.

2017-01-06 Thread Deborah Swanson
Antoon Pardon wrote, on January 06, 2017 2:11 AM > > Is there something going on with the mailinglist? Because I > have receive a lot of double messages. One copy is fairly > normal and is part of the discussion thread, the other is > completely seperated. -- Antoon Pardon. Looks to me like the ma

Re: Forcing prompt to be on newline when embedding Python with

2017-01-06 Thread H Krishnan
Thanks for your help. > > > > > I am working on embedding Python in my application. > > You forgot to tell us the version of Python that you're embedding. > > I am using Python2.7. > > I have redirected sys.stdin and sys.stdout to call methods from a Qt > TextEdit > > widget. Everything works fi

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do

2017-01-06 Thread Steven D'Aprano
On Wednesday 04 January 2017 12:10, Cameron Simpson wrote: > On 03Jan2017 12:57, Steve D'Aprano wrote: >>I dislike the Unix-style Vim/Emacs text editors, I prefer a traditional >>GUI-based editor. So my "IDE" is: >>- Firefox, for doing searches and looking up documentation; >>- an GUI programmer'

Re: Python for WEB-page !?

2017-01-06 Thread Michael Torrie
On 01/05/2017 04:53 PM, Victor Porton wrote: > Ionut Predoiu wrote: > >> I am a beginner in programming language. >> I want to know what version of Python I must to learn to use, beside of >> basic language, because I want to integrate in my site 1 page in which >> users to can made calculus based

Re: Forcing prompt to be on newline when embedding Python with

2017-01-06 Thread eryk sun
On Fri, Jan 6, 2017 at 1:06 AM, H Krishnan wrote: > I tried replacing sys.displayhook with a function that does not print > newline but the newline still got inserted. So, I am not sure where the > newline is coming from. In any case, I could override sys.displayhook to add > a newline at the end

Re: Python for WEB-page !?

2017-01-06 Thread Michael Torrie
On 01/05/2017 05:57 AM, Ionut Predoiu wrote: > Good afternoon, > > I am a beginner in programming language. I want to know what version > of Python I must to learn to use, beside of basic language, because I > want to integrate in my site 1 page in which users to can made > calculus based on my for

Re: Forcing prompt to be on newline when embedding Python with

2017-01-06 Thread H Krishnan
Hello Mr.Eryk, Thanks for the detailed explanation. After I added attribute support to my extension class for stdio, the problem was resolved. Regards, Krishnan On Fri, Jan 6, 2017 at 9:24 AM, eryk sun wrote: > On Fri, Jan 6, 2017 at 1:06 AM, H Krishnan wrote: > > I tried replacing sys.disp

RE: Python for WEB-page !?

2017-01-06 Thread Deborah Swanson
Ionut Predoiu wrote, on January 05, 2017 11:07 PM > > Good morning, > > Thanks to all for feedback and advice. > Because I am a beginner I will read more about versions of > Python recommended by you. > > On the other side I am interested to know if exist some sites > which have develop platform wh

Re: Choosing a Python IDE. what is your Pythonish recommendation? I

2017-01-06 Thread Antonio Caminero Garcia
On Wednesday, January 4, 2017 at 1:10:04 PM UTC-8, Dietmar Schwertberger wrote: > On 04.01.2017 07:54, Antonio Caminero Garcia wrote: > > Unfortunately most of the time I am still using print and input functions. I know that sucks, I did not use the pdb module, I guess that IDE debuggers leverage

Receiving a lot of double messages.

2017-01-06 Thread Antoon Pardon
Is there something going on with the mailinglist? Because I have receive a lot of double messages. One copy is fairly normal and is part of the discussion thread, the other is completely seperated. -- Antoon Pardon. -- https://mail.python.org/mailman/listinfo/python-list

Re: Forcing prompt to be on newline when embedding Python with

2017-01-06 Thread eryk sun
On Thu, Jan 5, 2017 at 7:09 AM, H Krishnan wrote: > > I am working on embedding Python in my application. You forgot to tell us the version of Python that you're embedding. > I have redirected sys.stdin and sys.stdout to call methods from a Qt TextEdit > widget. Everything works fine except that

Re: MySQL schema sync or diff

2017-01-06 Thread Chris Angelico
On Thu, Jan 5, 2017 at 11:02 AM, Charles Heizer wrote: > I have a MySQL database that is not managed (yet) and I would like to get an output or diff against my new model file. I'm using flask-sqlalchemy. > > Are there any modules that would help me discover the differences so that I can script a m

Re: Choosing a Python IDE. what is your Pythonish recommendation? I

2017-01-06 Thread Antonio Caminero Garcia
On Thursday, January 5, 2017 at 12:32:19 PM UTC-8, fpp wrote: > > On Thu, Jan 5, 2017 at 12:12 PM, Chris Clark > > wrote: > >> I want an IDE that I can use at work and home, linux and dare I say > >> windows. > >> Sublime, had to remove it from my work PC as it is not licensed. > >> Atom, loved it

Re: Python for WEB-page !?

2017-01-06 Thread Victor Porton
Ionut Predoiu wrote: > I am a beginner in programming language. > I want to know what version of Python I must to learn to use, beside of > basic language, because I want to integrate in my site 1 page in which > users to can made calculus based on my formulas already write behind (the > users wil

Re: Work between multiple processes

2017-01-06 Thread Irmen de Jong
On 4-1-2017 23:14, zxpat...@gmail.com wrote: > Hi everyone, > > I ran into a case that I need to create a work process of an application (Jython so has to call using java.exe) which will collect the data based on what main process indicates. > > (1) I tried multiprocessing package, no luck. Java.e

Pexpect

2017-01-06 Thread Iranna Mathapati
Hi Team, How to match latter(caps and small) ,numbers and # symbol in python pexpect. Thanks, Iranna M -- https://mail.python.org/mailman/listinfo/python-list

RE: Clickable hyperlinks

2017-01-06 Thread Deborah Swanson
Rhodri James wrote, on January 05, 2017 3:53 AM > > On 05/01/17 04:52, Deborah Swanson wrote: > > My original question was in fact whether there was a way to make > > clickable hyperlinks in a console. I was persuaded after about 10 > > replies that the answer was no, > > Then you were persuaded wr

Re: Choosing a Python IDE. what is your Pythonish recommendation? I

2017-01-06 Thread Antonio Caminero Garcia
On Thursday, January 5, 2017 at 9:51:17 AM UTC-8, ArnoB wrote: > On 02-01-17 12:38, Antonio Caminero Garcia wrote: > > Hello, I am having a hard time deciding what IDE or IDE-like code editor should I use. This can be overwhelming. > > > > So far, I have used Vim, Sublime, Atom, Eclipse with PyDev,

RE: Clickable hyperlinks

2017-01-06 Thread Deborah Swanson
Terry Reedy wrote, on January 04, 2017 10:18 PM > > On 1/5/2017 12:11 AM, Deborah Swanson wrote: > > Terry Reedy wrote, on January 04, 2017 3:58 PM > > >> To have a string interpreted as a clickable link, you send the string to > >> software capable of creating a clickable link, plus the informatio

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do

2017-01-06 Thread fpp
> On Thu, Jan 5, 2017 at 12:12 PM, Chris Clark > wrote: >> I want an IDE that I can use at work and home, linux and dare I say >> windows. >> Sublime, had to remove it from my work PC as it is not licensed. >> Atom, loved it until it slowed down. >> VIM, ok the best if you know vi inside out. >> A

Re: Python for WEB-page !?

2017-01-06 Thread Ionut Predoiu
Good morning, Thanks to all for feedback and advice. Because I am a beginner I will read more about versions of Python recommended by you. On the other side I am interested to know if exist some sites which have develop platform where can be use for free Python from browsers, without have it i

Re: Search a sequence for its minimum and stop as soon as the lowest possible value is found

2017-01-06 Thread Wolfgang Maier
On 1/6/2017 15:04, Peter Otten wrote: Example: you are looking for the minimum absolute value in a series of integers. As soon as you encounter the first 0 it's unnecessary extra work to check the remaining values, but the builtin min() will continue. The solution is a minimum function that allo

Re: Search a sequence for its minimum and stop as soon as the lowest possible value is found

2017-01-06 Thread Jussi Piitulainen
Peter Otten writes: > Example: you are looking for the minimum absolute value in a series of > integers. As soon as you encounter the first 0 it's unnecessary extra work > to check the remaining values, but the builtin min() will continue. > > The solution is a minimum function that allows the u

Re: Work between multiple processes

2017-01-06 Thread Patrick Zhou
On Thursday, January 5, 2017 at 5:49:46 PM UTC-5, Irmen de Jong wrote: > On 4-1-2017 23:14, zxpat...@gmail.com wrote: > > Hi everyone, > > > > I ran into a case that I need to create a work process of an application > > (Jython so has to call using java.exe) which will collect the data based on

RE: Pexpect

2017-01-06 Thread Joaquin Alzola
> How to match latter(caps and small) ,numbers and # symbol in python pexpect. With a .* child = pexpect.spawnu("ssh cbpapp@%s"% CBP[cust_cbp_server]) child.setecho(False) child.logfile = open("/opt/webapi/logs/delete_accountID.log", "w") child.expect(".*assword:")

ANN: Python Events Calendar - Please submit your 2017 events

2017-01-06 Thread M.-A. Lemburg
[Please help spread the word by forwarding to other relevant mailing lists, user groups, etc. world-wide; thanks :-)] ANNOUNCING Python Events Calendars - Please submit your 2017 events maintained by th

Re: The hardest problem in computer science...

2017-01-06 Thread Ethan Furman
On 01/06/2017 05:03 AM, Steve D'Aprano wrote: what do we call the vertical and horizontal line elements? I want to make them configurable, which means the user has to be able to pass an argument that specifies them. I have names for the individual components: XXX = namedtuple("XXX", "vline tee

How Best to Coerce Python Objects to Integers?

2017-01-06 Thread breamoreboy
Hi all, I'd suggest that this http://blog.pyspoken.com/2017/01/02/how-best-to-c oerce-python-objects-to-integers/ is not one of the greatest articles ever written about Python exception handling. Other opinions are welcome. Kindest regards. Mark Lawrence. -- https://mail.python.org/mailman/l

Re: pip install -r requirements.txt fails with Python 3.6 on Windows 10

2017-01-06 Thread breamoreboy
On Tuesday, January 3, 2017 at 8:08:37 PM UTC, Uri Even-Chen wrote: > Thank you, I'll consider to update our requirements to latest versions of > all packages. Last time I checked in 22th December 2016 and all our > requirements were the latest versions. In the meantime we can keep using > Python 3

Re: The hardest problem in computer science...

2017-01-06 Thread Skip Montanaro
"VT52 special graphics characters", anyone? Credit where credit is due. Who hasn't borked their output and wound up with their VT(52|100) in graphics mode? :-) https://en.wikipedia.org/wiki/VT52 Skip -- https://mail.python.org/mailman/listinfo/python-list

Re: The hardest problem in computer science...

2017-01-06 Thread Alain Ketterlin
Steve D'Aprano writes: [...] > Fiction > ├─ Fantasy > │ ├─ Terry Pratchett > │ │ ├─ Discworld > │ │ │ ├─ Wyrd Sisters > │ │ │ └─ Carpe Jugulum > │ │ └─ Dodger > │ └─ JK Rowling [...] > what do we call the vertical and horizontal line elements? Box-draw

Search a sequence for its minimum and stop as soon as the lowest possible value is found

2017-01-06 Thread Peter Otten
Example: you are looking for the minimum absolute value in a series of integers. As soon as you encounter the first 0 it's unnecessary extra work to check the remaining values, but the builtin min() will continue. The solution is a minimum function that allows the user to specify a stop value:

Re: The hardest problem in computer science...

2017-01-06 Thread Tim Chase
On 2017-01-06 13:44, Dan Sommers wrote: > On Sat, 07 Jan 2017 00:03:37 +1100, Steve D'Aprano wrote: > > what do we call the vertical and horizontal line elements? I want > > to make them configurable, which means the user has to be able to > > pass an argument that specifies them ... > > pstree(1)

Re: The hardest problem in computer science...

2017-01-06 Thread Dan Sommers
On Sat, 07 Jan 2017 00:03:37 +1100, Steve D'Aprano wrote: > The *hardest* problem is naming things. > > Fiction > ├─ Fantasy > │ ├─ Terry Pratchett > │ │ ├─ Discworld > │ │ │ ├─ Wyrd Sisters > │ │ │ └─ Carpe Jugulum [...] > what do we call the vertical and hori

Re: "paperpk" "paper pk" "paperpk.com" "express newspaper" "newspaper classified ads" "dawn jobs ads" "jang newspaper" "dawn jobs" "jang jobs ads" "nawaiwaqt" "classified ads" on www.npjobs.blogspot

2017-01-06 Thread muhammadasad254
this a all of facek you are veiw the latest post today newspaperp on view paperpkads. -- https://mail.python.org/mailman/listinfo/python-list

The hardest problem in computer science...

2017-01-06 Thread Steve D'Aprano
The second hardest problem in computer science is cache invalidation. The *hardest* problem is naming things. In a hierarchical tree view widget that displays items like this: Fiction ├─ Fantasy │ ├─ Terry Pratchett │ │ ├─ Discworld │ │ │ ├─ Wyrd Sisters │ │ │ └

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do not know what to choose.

2017-01-06 Thread Dietmar Schwertberger
On 06.01.2017 09:40, Antonio Caminero Garcia wrote: So why not use the debugger interactively to develop applications. As long as one sets the breakpoints in a meaningful way so you can trace your code in a very productive way. Is that what you mean by interactive environment? Well, not exactly

Re: Python for WEB-page !?

2017-01-06 Thread Ionut Predoiu
Good afternoon, Thank you for advice and promptitude in answer. Keep in touch for further questions. Kind regards. On Thursday, January 5, 2017 at 2:57:23 PM UTC+2, Ionut Predoiu wrote: > Good afternoon, > > I am a beginner in programming language. > I want to know what version of Python I mus

RE: Receiving a lot of double messages.

2017-01-06 Thread Deborah Swanson
Antoon Pardon wrote, on January 06, 2017 2:11 AM > > Is there something going on with the mailinglist? Because I > have receive a lot of double messages. One copy is fairly > normal and is part of the discussion thread, the other is > completely seperated. -- Antoon Pardon. Looks to me like th

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do not know what to choose.

2017-01-06 Thread Antonio Caminero Garcia
On Wednesday, January 4, 2017 at 1:10:04 PM UTC-8, Dietmar Schwertberger wrote: > On 04.01.2017 07:54, Antonio Caminero Garcia wrote: > > Unfortunately most of the time I am still using print and input functions. > > I know that sucks, I did not use the pdb module, I guess that IDE debuggers > >

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do not know what to choose.

2017-01-06 Thread Antonio Caminero Garcia
On Thursday, January 5, 2017 at 9:51:17 AM UTC-8, ArnoB wrote: > On 02-01-17 12:38, Antonio Caminero Garcia wrote: > > Hello, I am having a hard time deciding what IDE or IDE-like code editor > > should I use. This can be overwhelming. > > > > So far, I have used Vim, Sublime, Atom, Eclipse with P

Re: Receiving a lot of double messages.

2017-01-06 Thread Chris Angelico
On Fri, Jan 6, 2017 at 9:11 PM, Antoon Pardon wrote: > Is there something going on with the mailinglist? Because I have receive > a lot of double messages. One copy is fairly normal and is part of the > discussion thread, the other is completely seperated. -- Antoon Pardon. Yeah, I'm seeing the s

Pexpect

2017-01-06 Thread Iranna Mathapati
Hi Team, How to match latter(caps and small) ,numbers and # symbol in python pexpect. Thanks, Iranna M -- https://mail.python.org/mailman/listinfo/python-list

RE: Python for WEB-page !?

2017-01-06 Thread Deborah Swanson
Ionut Predoiu wrote, on January 05, 2017 11:07 PM > > Good morning, > > Thanks to all for feedback and advice. > Because I am a beginner I will read more about versions of > Python recommended by you. > > On the other side I am interested to know if exist some sites > which have develop platfo

Re: Clickable hyperlinks

2017-01-06 Thread Chris Angelico
On Thu, Jan 5, 2017 at 3:19 PM, Deborah Swanson wrote: > I downloaded the code from the Package Index, but there really wasn't > much in it. This is the entire .py file: Ehh, wrong file. Try the one in the standard library: https://github.com/python/cpython/blob/master/Lib/antigravity.py https:/

Re: Clickable hyperlinks

2017-01-06 Thread Chris Angelico
On Thu, Jan 5, 2017 at 2:24 PM, D'Arcy Cain wrote: > Think of it this way. You drop a ring down a drain. You can ask two > questions, "How do I remove a drain trap?" or "How do I recover a ring that > I dropped down the drain?" If you ask the first question you will get lots > of advice on tool

Receiving a lot of double messages.

2017-01-06 Thread Antoon Pardon
Is there something going on with the mailinglist? Because I have receive a lot of double messages. One copy is fairly normal and is part of the discussion thread, the other is completely seperated. -- Antoon Pardon. -- https://mail.python.org/mailman/listinfo/python-list

Is there a good process or library for validating changes to XML format

2017-01-06 Thread Sayth Renshaw
Afternoon Is there a good library or way I could use to check that the author of the XML doc I am using doesn't make small changes to structure over releases? Not fully over this with XML but thought that XSD may be what I need, if I search "python XSD" I get a main result for PyXB and generate

Re: Clickable hyperlinks

2017-01-06 Thread D'Arcy Cain
On 2017-01-04 07:07 PM, Deborah Swanson wrote: > D'Arcy Cain wrote, on Wednesday, January 04, 2017 5:03 AM >> In all the messages in this thread I still don't understand what this >> "teensy advantage" is supposed to be. Do you want to be able >> to do this: >> >>make_web_link(http://...) >> >

Re: Forcing prompt to be on newline when embedding Python with stdin/out redirection

2017-01-06 Thread H Krishnan
Hello Mr.Eryk, Thanks for the detailed explanation. After I added attribute support to my extension class for stdio, the problem was resolved. Regards, Krishnan On Fri, Jan 6, 2017 at 9:24 AM, eryk sun wrote: > On Fri, Jan 6, 2017 at 1:06 AM, H Krishnan wrote: > > I tried replacing sys.displ

Re: Clickable hyperlinks

2017-01-06 Thread D'Arcy Cain
On 2017-01-04 05:58 PM, Deborah Swanson wrote: >> the user to go and authenticate, you can simply >> webbrowser.open("http://.../";) and it'll DTRT. > > Thank you, thank you! Finally, at least one person on this list knows > about something (anything) in the python world that is internet aware.

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do not know what to choose.

2017-01-06 Thread Antonio Caminero Garcia
On Thursday, January 5, 2017 at 12:32:19 PM UTC-8, fpp wrote: > > On Thu, Jan 5, 2017 at 12:12 PM, Chris Clark > > wrote: > >> I want an IDE that I can use at work and home, linux and dare I say > >> windows. > >> Sublime, had to remove it from my work PC as it is not licensed. > >> Atom, loved i

Re: Clickable hyperlinks

2017-01-06 Thread Dennis Lee Bieber
On Wed, 4 Jan 2017 14:58:42 -0800, "Deborah Swanson" declaimed the following: >Thank you, thank you! Finally, at least one person on this list knows >about something (anything) in the python world that is internet aware. >It's also occurred to me that Beautifulsoup downloads data from a url, >so

MySQL schema sync or diff

2017-01-06 Thread Charles Heizer
Hello, I have a MySQL database that is not managed (yet) and I would like to get an output or diff against my new model file. I'm using flask-sqlalchemy. Are there any modules that would help me discover the differences so that I can script a migration to begin using flask-migrate? Thanks! --

Re: Python for WEB-page !?

2017-01-06 Thread Ionut Predoiu
Good morning, Thanks to all for feedback and advice. Because I am a beginner I will read more about versions of Python recommended by you. On the other side I am interested to know if exist some sites which have develop platform where can be use for free Python from browsers, without have it i

Re: Hey, I'm new to python so don't judge.

2017-01-06 Thread Steven D'Aprano
On Thursday 05 January 2017 10:21, Terry Reedy wrote: > On 1/3/2017 10:15 PM, Dennis Lee Bieber wrote: > >> And that statement tells us you are trying to run from within some >> IDE/editor which is trapping Python exceptions and producing a dialog >> box for them. > > IDLE does this when one runs

Re: Clickable hyperlinks

2017-01-06 Thread Michael Torrie
On 01/04/2017 03:58 PM, Deborah Swanson wrote: > Thank you, thank you! Finally, at least one person on this list knows > about something (anything) in the python world that is internet aware. > It's also occurred to me that Beautifulsoup downloads data from a url, > so that code must have access to

Re: Choosing a Python IDE. what is your Pythonish recommendation? I

2017-01-06 Thread Dietmar Schwertberger
On 04.01.2017 07:54, Antonio Caminero Garcia wrote: > Unfortunately most of the time I am still using print and input functions. I know that sucks, I did not use the pdb module, I guess that IDE debuggers leverage such module. pdb is actually quite useful. On my Windows PCs I can invoke python on

RE: Clickable hyperlinks

2017-01-06 Thread Deborah Swanson
Chris Angelico wrote, on January 04, 2017 4:16 AM > > Yeah, there's no simple answer; however, you'll find that > Python on many platforms is entirely capable of popping a URL > up in the user's default browser. Check this out: > > >>> import antigravity I downloaded the code from the Package Inde

Re: Choosing a Python IDE. what is your Pythonish recommendation? I do

2017-01-06 Thread William Ray Wing
> On Jan 4, 2017, at 3:44 PM, Dietmar Schwertberger wrote: > > On 04.01.2017 15:41, William Ray Wing wrote: >> I use Wing, and I think you will like it. It *is* pythonic, and for what it is worth, offers remote debugging as one of its more recently added features. > Obviously, you had no other c

Re: Clickable hyperlinks

2017-01-06 Thread Rustom Mody
This thread does lead to the question: Is the Url type in python less first-class than it could be? In scheme I could point to something like this https://docs.racket-lang.org/net/url.html Is there something equivalent in python? -- https://mail.python.org/mailman/listinfo/python-list

Re: Choosing a Python IDE. what is your Pythonish recommendation? I

2017-01-06 Thread Dietmar Schwertberger
On 04.01.2017 15:41, William Ray Wing wrote: > I use Wing, and I think you will like it. It *is* pythonic, and for what it is worth, offers remote debugging as one of its more recently added features. Obviously, you had no other choice than using Wing ;-) The remote debugging has been around for

Re: Choosing a Python IDE. what is your Pythonish recommendation? I

2017-01-06 Thread Hans-Peter Jansen
On Montag, 2. Januar 2017 03:38:53 Antonio Caminero Garcia wrote: > Hello, I am having a hard time deciding what IDE or IDE-like code editor > should I use. This can be overwhelming. > > So far, I have used Vim, Sublime, Atom, Eclipse with PyDev, Pycharm, > IntelliJ with Python plugin. Well, since

Re: Clickable hyperlinks

2017-01-06 Thread Chris Angelico
On Thu, Jan 5, 2017 at 9:58 AM, Deborah Swanson wrote: > Chris Angelico wrote, on January 04, 2017 4:16 AM >> This uses the 'webbrowser' module, which knows about a number >> of different ways to open a browser, and will attempt them >> all. So if you can figure out the UI part of things, actually

Work between multiple processes

2017-01-06 Thread zxpatric
Hi everyone, I ran into a case that I need to create a work process of an application (Jython so has to call using java.exe) which will collect the data based on what main process indicates. (1) I tried multiprocessing package, no luck. Java.exe can't be called from Process class? (2) I tried

Re: Clickable hyperlinks

2017-01-06 Thread Terry Reedy
On 1/4/2017 4:32 AM, Deborah Swanson wrote: > My original question was whether python had anything to provide this > functionality, and the answer appears to be a resounding NO!!! I would say 'Yes, but with user effort'. To have a string interpreted as a clickable link, you send the string to s

Re: Clickable hyperlinks

2017-01-06 Thread Grant Edwards
On 2017-01-04, Michael Torrie wrote: > On my Linux machine, the terminal emulators I've used all make a regular > url printed out into a clickable link (or at least a right-clickable > link). This is just something they try to do with all things that look > like urls. Sometimes it's helpful, of

Re: Clickable hyperlinks

2017-01-06 Thread Grant Edwards
On 2017-01-03, Deborah Swanson wrote: > Grant Edwards wrote, on January 03, 2017 3:13 PM >> >> On 2017-01-03, Deborah Swanson wrote: >> >> > I'm sorry, I should have said a GUI console because I >> wouldn't expect >> > a text-based console to produce clickable links. >> >> What's a "GUI console"?

RE: Clickable hyperlinks

2017-01-06 Thread Deborah Swanson
Chris Angelico wrote, on January 04, 2017 4:16 AM > > On Wed, Jan 4, 2017 at 10:43 PM, Deborah Swanson > wrote: > > I'm quite well aware by now that there is no one-sentence > answer to my > > original question, if there's any coherent answer at all. > Them's the > > breaks. Live with it or live w

Re: Clickable hyperlinks

2017-01-06 Thread D'Arcy Cain
Deborah - please trim your quoted text. On 2017-01-04 04:32 AM, Deborah Swanson wrote: > Thanks, Steven. Yes, of course if you want to print strings you must > enclose them in quotes. I think you learn that in Week 1 of any > introductory course on Python. Closer to minute one. When I investigat

Re: Hey, I'm new to python so don't judge.

2017-01-06 Thread Terry Reedy
On 1/3/2017 10:15 PM, Dennis Lee Bieber wrote: > And that statement tells us you are trying to run from within some > IDE/editor which is trapping Python exceptions and producing a dialog > box for them. IDLE does this when one runs code from the editor, because it cannot/should not inject error

Re: Clickable hyperlinks

2017-01-06 Thread Chris Angelico
On Wed, Jan 4, 2017 at 10:43 PM, Deborah Swanson wrote: > I'm quite well aware by now that there is no one-sentence answer to my > original question, if there's any coherent answer at all. Them's the > breaks. Live with it or live without it, it doesn't care. Yeah, there's no simple answer; howev

RE: Clickable hyperlinks

2017-01-06 Thread Deborah Swanson
D'Arcy Cain wrote, on Wednesday, January 04, 2017 5:03 AM > > Deborah - please trim your quoted text. Yes, I will. Some lists want to have it all to review in one message, some want it trimmed to just the lines you are responding to. I was just waiting to see what this list wants. > On 2017-01-

RE: Clickable hyperlinks

2017-01-06 Thread Deborah Swanson
Steve D'Aprano wrote, on January 04, 2017 2:39 AM > > On Wed, 4 Jan 2017 08:32 pm, Deborah Swanson wrote: > > > Thanks, Steven. Yes, of course if you want to print strings > you must > > enclose them in quotes. I think you learn that in Week 1 of any > > introductory course on Python. > > > > But w

Re: Screwing Up looping in Generator

2017-01-06 Thread Sayth Renshaw
For completeness I was close this is the working code. def get_list_of_names(generator_arg): name_set = set() for name in generator_arg: base = os.path.basename(name.name) filename = os.path.splitext(base)[0] name_set.add(filename) return name_set def data_att

Re: Clickable hyperlinks

2017-01-06 Thread Gilmeh Serda
On Tue, 03 Jan 2017 11:46:16 -0800, Deborah Swanson wrote: > Does python have an equivalent function? Probably the most common use > for it would be output to the console, similar to a print statement, but > clickable. Write it as HTML code save to temp file and call the browser which loads the

RE: Clickable hyperlinks

2017-01-06 Thread Deborah Swanson
Steve D'Aprano wrote, on January 04, 2017 2:20 AM > > On Wed, 4 Jan 2017 03:46 pm, Deborah Swanson wrote: > > > As I've mentioned in other posts on this thread, I'm now > thinking that > > I need to write a class to do this, and find out how > Firefox and url > > aware terminals in Linux do it. The

RE: Clickable hyperlinks

2017-01-06 Thread Steve D'Aprano
On Wed, 4 Jan 2017 03:46 pm, Deborah Swanson wrote: > As I've mentioned in other posts on this thread, I'm now thinking that I > need to write a class to do this, and find out how Firefox and url aware > terminals in Linux do it. There must be a way. A GUI application can interpret text any way

  1   2   >