Re: pip and command line

2018-03-11 Thread Terry Reedy
On 3/11/2018 2:08 PM, GISDude wrote: On Saturday, March 10, 2018 at 10:28:00 AM UTC-8, Terry Reedy wrote: Why can't I use pip while in IDLE Would you expect to use pip in MS Excel? If you type 'python' at a command line, and get the '>>>' REPL prompt (goo

2.7 EOL = 2020 January 1

2018-03-13 Thread Terry Reedy
On March 10, on thread "Python 2.7 -- bugfix or security before EOL?", Guido van Russum wrote "The way I see the situation for 2.7 is that EOL is January 1st, 2020, and there will be no updates, not even source-only security patches, after that date. Support (from the core devs, the PSF, and p

Re: matplotlib icon

2018-03-14 Thread Terry Reedy
On 3/14/2018 2:30 PM, tedo.vrba...@gmail.com wrote: I am getting this logging.INFO notice: Could not load matplotlib icon: bad option "foobar": must be aspect, attributes, client, colormapwindows, command, deiconify, focusmodel, forget, frame, geometry, grid, group, iconbitmap, iconify, iconmas

Re: Treatment of NANs in the statistics module

2018-03-16 Thread Terry Reedy
On 3/16/2018 7:16 PM, Steven D'Aprano wrote: The bug tracker currently has a discussion of a bug in the median(), median_low() and median_high() functions that they wrongly compute the medians in the face of NANs in the data: https://bugs.python.org/issue33084 I would like to ask people how the

Re: Style Q: Instance variables defined outside of __init__

2018-03-19 Thread Terry Reedy
On 3/19/2018 1:04 PM, Irv Kalb wrote: However, there is one warning that I am seeing often, an > I'm not sure about how to handle it. The warning I see is: "Instance attribute defined outside of __init__ ..." Style checkers are notorious for sometimes giving bad advice and being overly opi

Re: I keep getting this error message when i try to run a program in Python

2018-03-22 Thread Terry Reedy
On 3/22/2018 2:37 PM, Damjan Stojanovski wrote: i am sorry but i can not find a way to attach an image here so you can see what i mean. Please someone tell me how to add an image here. You cannot and there is no need. List is text only, no attachments. Reduce code to the minimum needed to ge

Re: Accessing parent objects

2018-03-25 Thread Terry Reedy
On 3/25/2018 7:42 AM, Jugurtha Hadjar wrote: class C2(object):     def __init__(self, parent=None):     self.parent = parent Since parent is required, it should not be optional.     def foo(self):     print("I am {self.__class__.__name__} foo".format(self=self))     self.par

Re: Accessing parent objects

2018-03-25 Thread Terry Reedy
On 3/25/2018 11:01 AM, Jugurtha Hadjar wrote: On 03/25/2018 03:25 PM, Terry Reedy wrote: On 3/25/2018 7:42 AM, Jugurtha Hadjar wrote: class C2(object): def __init__(self, parent=None): self.parent = parent Since parent is required, it should not be optional. You can still

Re: (unknown)

2018-03-27 Thread Terry Reedy
On 3/27/2018 3:27 AM, kevon harris wrote: Unable to pull up IDLE after downloading Python 3.6.4 What did you download? How did you install after downloading? Can you run 3.6 after installing? How did you try to run IDLE? Can you use Command Prompt? -- Terry Jan Reedy -- https://mail.python.or

Re: Welcome to the "Python-list" mailing list

2018-03-27 Thread Terry Reedy
On 3/27/2018 11:06 AM, nadir musallam wrote: I have tried installing Python3.6.4 on my computer as I am eager to begin a What exactly did you do? new career in data analytics. However I am running in to some problems when attempting to set up the software. I have downloaded Dev C++ software a

Re: please test the new PyPI (now in beta)

2018-03-28 Thread Terry Reedy
On 3/28/2018 10:50 AM, sumana.hariharesw...@gmail.com wrote: People who literally don't see the list of ways to filter on the left-hand side of https://pypi.org/search/ : I ask you the usual list of troubleshooting questions. What OS and browser are you using, what plugins and particularly int

Re: Curious case of UnboundLocalError

2018-03-30 Thread Terry Reedy
On 3/30/2018 7:25 AM, Johannes Bauer wrote: On 30.03.2018 13:13, Ben Bacarisse wrote: import collections class Test(object): def __init__(self): z = { "y": collections.defaultdict(list), This mention of collections refers to ...

Python Developer Survey: Python 3 usage overtakes Python 2 usage

2018-03-30 Thread Terry Reedy
https://www.jetbrains.com/research/python-developers-survey-2017/ “Which version of Python do you use the most?” 2014 80% 2.x, 20% 3.x 2016 60% 2.x, 40% 3.x 2017 25% 2.x, 75% 3.x This is a bigger jump than I anticipated. -- Terry Jan Reedy -- https://mail.python.org/mailman/listinfo/python-lis

Re: Python Developer Survey: Python 3 usage overtakes Python 2 usage

2018-03-31 Thread Terry Reedy
On 3/31/2018 11:58 AM, Etienne Robillard wrote: Do you really think people in Somalia can afford theses things like in the US? No, many cannot afford $600 Caddilac-style phones to take 10 megapixel pictures and watch UTube videos. Instead they buy $100 VWBug-style phones that let them get c

Re: Why is the use of an undefined name not a syntax error?

2018-04-01 Thread Terry Reedy
On 4/1/2018 5:24 PM, David Foster wrote: My understanding is that the Python interpreter already has enough information when bytecode-compiling a .py file to determine which names correspond to local variables in functions. That suggests it has enough information to identify all valid names in

Re: Python aliases under Windows?

2018-04-03 Thread Terry Reedy
On 4/3/2018 11:43 AM, Ian Kelly wrote: On Tue, Apr 3, 2018 at 9:00 AM, Kirill Balunov wrote: In fact, I do not really understand why the _py launcher_ way is easier or better than `python3` or `python3.6` way even on Windows. There are already `pip.exe`, `pip3.exe`, `pip3.6.exe` which solve the

Re: Python aliases under Windows?

2018-04-03 Thread Terry Reedy
On 4/3/2018 4:16 PM, Kirill Balunov wrote: Thank you Ian, Terry, Eryk! Now I understand the purpose of py launcher in general. I don't have Windows near, will `py -3.6 ...` work if Python36 is not on the Path? Yes. -- Terry Jan Reedy -- https://mail.python.org/mailman/listinfo/python-list

Re: Asynchronous processing is more efficient -- surely not?

2018-04-04 Thread Terry Reedy
On 4/4/2018 3:27 AM, Steven D'Aprano wrote: So, I'm, still trying to wrap my brain around async processing, and I started reading this tutorial: http://stackabuse.com/python-async-await-tutorial/ and the very first paragraph broke my brain. "Asynchronous programming has been gaining a lot of t

Re: RegEx to match set of lines

2018-04-05 Thread Terry Reedy
On 4/5/2018 11:03 AM, Steven D'Aprano wrote: On Thu, 05 Apr 2018 14:09:23 +0530, Prahallad Achar wrote: I would like to match set of lines from the below data. this data comes from one of the network Good grief! You don't need to post your entire data set! We don't need or want to see hundred

Re: Python Idle not giving my prompt after If line

2018-04-09 Thread Terry Reedy
On 4/9/2018 3:07 AM, Peter Otten wrote: brg...@gmail.com wrote: I typed the If part of an If/Else statement, but did not get a prompt at the beginning of the next line when I hit return. Instead, the cursor lined up under the "p" of "print." Here is the line of text (it's part of a longer bit o

Re: Can I execute a python code written in Python 2.7 (using numpy and tensor flow executed in linux) in Winpython 3.6 on Windows?

2018-04-17 Thread Terry Reedy
On 4/17/2018 1:00 AM, Rishika Sen wrote: Here is the code that has been written in Python 2.7, numpy, tensorflow: https://drive.google.com/open?id=1JZe7wfRcdlEF6Z5C0ePBjtte_2L4Kk-7 One must 'sign in' to read this. Can you please let me know what changes I have to make to execute it on WinPyt

Re: Fwd: Python Import Impossibility

2018-04-17 Thread Terry Reedy
On 4/17/2018 5:06 PM, Dan Stromberg wrote: Given that the list does not allow pictures, would it make sense to have the software that strips the pictures also send an e-mail to the picture sender indicating that pictures are disallowed? I see a lot of people responding individually saying that i

Re: Cant uninstall, modify or repair python

2018-04-21 Thread Terry Reedy
On 4/21/2018 7:53 PM, Michael Torrie wrote: On 04/21/2018 11:43 AM, jed...@gmail.com wrote: I currently have python version 3.6.1 32 bit version on my laptop and when i try to repair, it gives an error saying "The installer has encountered an unexpected error installing this package. This may

Re: Issue with python365.chm on window 7

2018-04-23 Thread Terry Reedy
On 4/23/2018 5:38 PM, Brian Gibbemeyer wrote: From: Brian Gibbemeyer/Detroit/IBM Not sure which email this should go to. This is a good place to start. But I downloaded .chm version of the Python guide and found that it is not working in windows 7 How did you download it? How did you t

Re: Installation of tensorflow via pip -- messages?

2018-04-26 Thread Terry Reedy
On 4/26/2018 3:04 PM, Virgil Stokes wrote: However, each entry in this Windows 10 path has a trailing backslash. Some do, and some don't, which is the same on my Win10 If my memory is correct, this is the default for path directories. The Python entries do, as added by the Windows Installe

Re: Improving syntax error messages

2018-04-26 Thread Terry Reedy
On 4/26/2018 4:22 PM, Serhiy Storchaka wrote: What syntax errors did you see most often? Which of them looks the most weird? How would you like to improve their messages. One way to research this would be to search stackoverflow.com for "[python] SyntaxError". There are currently 8142 results

Re: The perils of multiple Pythons

2018-04-30 Thread Terry Reedy
On 4/30/2018 5:03 PM, Chris Angelico wrote: On Tue, May 1, 2018 at 6:59 AM, justin walters wrote: With Python 3.5+, venv is a built in module. If using a venv, default to using the binary in the venv. That's what I do anyways. Yep. Munroe (the author of XKCD) is clearly using a Mac, though,

Re: The perils of multiple Pythons

2018-04-30 Thread Terry Reedy
On 4/30/2018 5:03 PM, Chris Angelico wrote: Yep. Munroe (the author of XKCD) is clearly using a Mac, though, and Macs don't ship with Python 3.5+. So there's a bootstrapping problem: how do you install a newer Python? There are about half a dozen options. I think the situation is improved with

Re: Python 2.7.15 Windows MSI removes previous 2.7.x binaries?

2018-05-01 Thread Terry Reedy
On 5/1/2018 1:48 PM, Paul Moore wrote: It's intended behaviour (to my knowledge). Or at least, we don't intend for people to install two different patch versions in parallel (at least not with the official installers). I thought this behaviour was always the case. It may be related to the install

Re: ipython install

2018-05-05 Thread Terry Reedy
On 5/5/2018 6:09 AM, Sharan Basappa wrote: On Saturday, 5 May 2018 15:02:33 UTC+5:30, Steven D'Aprano wrote: On Sat, 05 May 2018 00:20:26 -0700, Sharan Basappa wrote: After this, when I type ipython on command prompt, I don't get anything on my windows. You don't get *anything*? Not even an

Tracebacks for exceptions in interactively entered code.

2018-05-07 Thread Terry Reedy
I intend to improve the IDLE doc section on IDLE-console differences. The following is from standard interactive mode (PSF CPython 3.7.0a4) on Windows (Win 10, Command Prompt) >>> def f(): ... return 1/0 ... >>> f() Traceback (most recent call last): File "", line 1, in File "", line

Re: Is this a bug or a feature in TkInter?

2018-05-10 Thread Terry Reedy
On 5/10/2018 2:12 PM, charmingold...@gmail.com wrote: I'm learning to use TkInter in Python and came across this example program from 'Thinking in TkInter' (http://thinkingtkinter.sourceforge.net) - see below. Two buttons 'button1' and 'button2' are defined. The bug is that event.widget return

Re: Is this a bug or a feature in TkInter?

2018-05-11 Thread Terry Reedy
On 5/11/2018 2:57 AM, Cuthbert Milligen wrote: Hi Terry, many thanks for your detailed explanation! (I can't see how to 'reply' under your post...) Followup to the list rather than reply to me, as you did, is the right thing to do. -- Terry Jan Reedy -- https://mail.python.org/mailman/li

Re: Passing File Descriptors To Subprocesses

2018-05-11 Thread Terry Reedy
On 5/11/2018 11:23 AM, pevo...@gmail.com wrote: I encountered the same issue with Python 3.4 on CentOS 7 when using only the close_fds argument. Since I am passing a lot of dynamically obtained file descriptors, using the pass_fds argument is impossible for my case. Setting close_fds to False

Re: f-string anomaly

2018-05-13 Thread Terry Reedy
On 5/13/2018 3:22 PM, Ken Kundert wrote: Please do not double post. I am seeing an unexpected difference between the behavior of the string format method and f-strings. Read https://docs.python.org/3/reference/lexical_analysis.html#formatted-string-literals carefully. Here is an example:

Re: pylint/pyreverse with Python3

2018-05-13 Thread Terry Reedy
On 5/13/2018 1:01 PM, Rich Shepard wrote:   Installed here is pylint-1.7.1 and python-3.6.5. When I try to run pyreverse (and pylint) on python3 source code it fails because it finds only the python-2.7 site-package and not the python-3.6 site-package.   If you have learned how to run pyli

Re: Fwd: sys module does not contain ps1

2018-05-18 Thread Terry Reedy
On 5/18/2018 7:40 AM, Alferdize wrote: -- Forwarded message -- From: Alferdize Date: Thu, May 17, 2018 at 10:13 PM Subject: sys module does not contain ps1 To: python-list@python.org It is giving error like I have given below import sys sys.ps1 Traceback (most recent call las

Re: TypeError: expected string or Unicode object, NoneType found

2018-05-19 Thread Terry Reedy
On 5/19/2018 12:47 PM, Peter Otten wrote: subhabangal...@gmail.com wrote: I wrote a small piece of following code import nltk from nltk.corpus.reader import TaggedCorpusReader from nltk.tag import CRFTagger To implement Peter's suggestion: def NE_TAGGER(): def tagger(stop): reader

Re: Tkinter and root vs. Wayland

2018-05-22 Thread Terry Reedy
On 5/22/2018 5:52 PM, Grant Edwards wrote: For a couple decades now, I've been distributing a couple smallish Tkinter applications that need to run as root for a variety of reasons (raw Ethernet access, starting/stopping daemons, loading and unloading kernel modules, reading and writing config fi

Re: how to get INDEX count, or last number of Index

2018-05-23 Thread Terry Reedy
On 5/23/2018 5:56 PM, Rob Gaddi wrote: On 05/23/2018 02:51 PM, asa32s...@gmail.com wrote: s = "kitti" 0,1,2,3,4 k,i,t,t,i how do i retrieve '4'. i know i can do a len(s)-1, Use -1, which is the same as len(s)-1 but faster. >>> s = 'kitty' >>> s[len(s)-1] 'y' >>> s[-1] 'y' -- Terry Jan Ree

Re: how to get INDEX count, or last number of Index

2018-05-23 Thread Terry Reedy
On 5/23/2018 6:07 PM, asa32s...@gmail.com wrote: On Wednesday, May 23, 2018 at 5:51:42 PM UTC-4, asa3...@gmail.com wrote: s = "kitti" 0,1,2,3,4 k,i,t,t,i how do i retrieve '4'. i know i can do a len(s)-1, but i assume there is a function that gives me last number of index thanks thanks, it

Re: how to get INDEX count, or last number of Index

2018-05-23 Thread Terry Reedy
On 5/23/2018 8:46 PM, bartc wrote: On 24/05/2018 00:44, Terry Reedy wrote: On 5/23/2018 5:56 PM, Rob Gaddi wrote: On 05/23/2018 02:51 PM, asa32s...@gmail.com wrote: s = "kitti" 0,1,2,3,4 k,i,t,t,i how do i retrieve '4'. i know i can do a len(s)-1, Use -1, which is the

Re: Scripts not downloading Version 3.6.5

2018-05-24 Thread Terry Reedy
On 5/24/2018 11:31 AM, Chester Davies via Python-list wrote: Hi! Yesterday I downloaded the latest version of Python, after some fiddling around with some command line, getting Python to open files etc, it wasn't able to find various pillows, so after a while, I decided to call it a night. I w

Re: Problem with OrderedDict

2018-05-30 Thread Terry Reedy
On 5/30/2018 4:48 AM, Frank Millman wrote: Hi all I want to work backwards to solve this problem, so I have to explain it forwards to put you in the picture. I have an Ordered Dictionary. Under certain circumstances I am getting this error -    RuntimeError: OrderedDict mutated during ite

Re: Why exception from os.path.exists()?

2018-05-31 Thread Terry Reedy
On 5/31/2018 8:03 AM, Marko Rauhamaa wrote: This surprising exception can even be a security issue: >>> os.path.exists("\0") Traceback (most recent call last): File "", line 1, in File "/usr/lib64/python3.6/genericpath.py", line 19, in exists os.stat(path) Value

Re: Indented multi-line strings

2018-05-31 Thread Terry Reedy
On 5/31/2018 10:39 AM, Dan Strohl via Python-list wrote: This is of course not a problem if the *trailing* quote determines the indentation: a_multi_line_string = i''' Py- thon ''' I get the point, but it feels like it would be a pain to use, and it "Feels"

Re: Override built in types... possible? or proposal.

2018-05-31 Thread Terry Reedy
On 5/31/2018 10:49 AM, Dan Strohl via Python-list wrote: Is it possible to override the assignment of built in types to the shorthand representations? By which I presume you mean literals and overt (non-comprehension) displays. So you wish that Python should be even more dynamic. (Some wis

Re: ... (ellipsis)

2018-05-31 Thread Terry Reedy
On 5/31/2018 10:26 PM, Mike McClain wrote: I'm having understanding the use if the ellipsis. I keep reading that it is used in slices By numpy for numpy multidimensional arrays, which have their own __getitem__, which recognizes and gives meaning to ... -- Terry Jan Reedy -- https://ma

Re: tkinter (ttk) combobox dropdown text is white on white

2018-06-05 Thread Terry Reedy
On 6/3/2018 3:54 PM, Jim Lee wrote: Given the following snippet (Python 3.6.5, Tk 8.6.8): What OS? Likely not Windows import tkinter as tk from tkinter import ttk root = tk.Tk() cb = ttk.Combobox(root) cb.grid(row=0, column=0, sticky='NSEW') cb['values'] = ['one', 'two', 'three', 'four'] roo

Re: Valid encodings for a Python source file

2018-06-07 Thread Terry Reedy
On 6/7/2018 4:40 PM, Daniel Glus wrote: I'm trying to figure out the entire list of possible encodings for a Python source file - that is, encodings that can go in a PEP 263 encoding specification, like # -*- encoding: foo -*-. For new code for python

Re: Inverting a conditional function

2018-06-09 Thread Terry Reedy
On 6/9/2018 5:54 AM, Steven D'Aprano wrote: I frequently have a function which tests some condition, returning True or False, and want a function which reverses the condition. If all I wanted was the result of calling the function, I could say not condition(x) and be done with it, but I w

Re: Obsolete method in the html module

2018-06-09 Thread Terry Reedy
On 6/9/2018 4:07 AM, Vincent Vande Vyvre wrote: In Python-3.7.0b5 we can find at the end of html/parser.py:     def unescape(self, s):     warnings.warn('The unescape method is deprecated and will be removed '   'in 3.5, use html.unescape() instead.',   

Re: How to make a button flashing?

2018-06-13 Thread Terry Reedy
On 6/13/2018 7:21 AM, Peter Otten wrote: huey.y.ji...@gmail.com wrote: I forgot the syntax of making a button flash, and failed to find an example in the web. I use Tkinter, to create a button. Then made it packed, and showed up. Now I am trying to make button b flashing, to make it get better

Re: PEP8 compliance

2018-06-13 Thread Terry Reedy
On 6/13/2018 12:35 PM, T Berger wrote: I did make the changes in IDLE, but I thought I must be in the wrong place. This is a good place for beginners. The line of code I got in terminal was: /Users/TamaraB/Desktop/mymodules/vsearch.py:1:25: E231 missing whitespace after ':' def search4vowel

Re: How to make a button flashing?

2018-06-13 Thread Terry Reedy
On 6/13/2018 8:57 PM, huey.y.ji...@gmail.com wrote: On Wednesday, June 13, 2018 at 5:23:17 PM UTC+8, huey.y...@gmail.com wrote: Hi All, I forgot the syntax of making a button flash, and failed to find an example in the web. I use Tkinter, to create a button. Then made it packed, and showed up.

Re: How to find an object existing?

2018-06-13 Thread Terry Reedy
On 6/14/2018 1:20 AM, Christian Gollwitzer wrote: Am 14.06.18 um 05:14 schrieb huey.y.ji...@gmail.com: root = Tkinter.Tk() button = Tkinter.Button(root, text="Find me") button.pack() I created a button, Python object. I recall I can check this object existing by using   winfo, such as  winfo.e

Re: Is it possible to call a class but without a new instance created?

2018-06-18 Thread Terry Reedy
On 6/18/2018 12:48 AM, Jach Fong wrote: After looking into the \tkiniter\font.py source file, triggered by Jim's hint on my previous subject "Why an object changes its "address" between adjacent calls?", I get more confused. Below was quoted from the font.py: def nametof

Re: Is it possible to call a class but without a new instance created?

2018-06-18 Thread Terry Reedy
or old object. For such immutables, it does not matter as long at the object has the correct value. As others said, this is all handled in a __new__ method. But none of this has much to do with tkinter instances. On 6/18/2018 5:09 AM, Terry Reedy wrote: On 6/18/2018 12:48 AM, Jach Fong

Re: Why an object changes its "address" between adjacent calls?

2018-06-19 Thread Terry Reedy
On 6/18/2018 8:38 PM, sa...@caprilion.com.tw wrote: Grant Edwards at 2018/6/18 PM 10:36 wrote: On 2018-06-17, Jach Fong wrote: C:\Python34\Doc>py Python 3.4.4 (v3.4.4:737efcadf5a6, Dec 20 2015, 19:28:18) [MSC v.1600 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for

Re: syntax difference

2018-06-24 Thread Terry Reedy
On 6/24/2018 11:39 AM, Bart wrote: Bart, I agree that people should not dogpile onto you. As with Rick, I read your posts or not, depending on whether I feel like being entertained at the moment, and usually move on without comment. I know I'm going to get flak for bringing this up this old

Re: Anyone here on Python-Dev mailing list?

2018-06-24 Thread Terry Reedy
On 6/24/2018 12:07 PM, Steven D'Aprano wrote: Anyone on the Python-Dev mailing list, are you getting private emails containing nothing but stream of consciousness word-salad from somebody (some bot?) calling himself "Chanel Marvin" with a gmail address? Typical example: "I refuse to create

Re: Anyone here on Python-Dev mailing list?

2018-06-26 Thread Terry Reedy
From: Terry Reedy On 6/24/2018 12:07 PM, Steven D'Aprano wrote: > Anyone on the Python-Dev mailing list, are you getting private emails > containing nothing but stream of consciousness word-salad from somebody > (some bot?) calling himself "Chanel Marvin" with a gm

Re: syntax difference

2018-06-26 Thread Terry Reedy
From: Terry Reedy On 6/24/2018 11:39 AM, Bart wrote: Bart, I agree that people should not dogpile onto you. As with Rick, I read your posts or not, depending on whether I feel like being entertained at the moment, and usually move on without comment. > I know I'm going to get

Re: sigmoid function and derivative

2018-06-26 Thread Terry Reedy
On 6/26/2018 11:26 PM, Sharan Basappa wrote: Folks, I know this is not a machine learning forum but I wanted to see if anyone can explain this to me. In artificial neural network, I can understand why sigmoid is used but I see that derivative of sigmoid output function is used. I am not able

Re: overlooked patch?

2018-06-28 Thread Terry Reedy
Yep. We do not have enough people reviewing patches. Perhaps you could do so with this one. On 6/28/2018 12:02 PM, Marco Prosperi wrote: hello, just to give evidence that there is a bug in python 3.6/3.7 for which there is a patch prepared a long time ago but probably it has never been applie

Re: I lost nearly all my modules installing 3.7

2018-06-28 Thread Terry Reedy
On 6/28/2018 1:08 PM, Elliott Roper wrote: I have done something stupid. Don't know what. It appears that you ran 3.7 expecting that modules installed for 3.6 would magically be available for 3.7. There is a pip command for making an editable file of installed packages. Run that in 3.6, pe

Re: I lost nearly all my modules installing 3.7

2018-06-28 Thread Terry Reedy
On 6/28/2018 6:45 PM, Elliott Roper wrote: On 28 Jun 2018, Terry Reedy wrote There is a pip command for making an editable file of installed packages. Run that in 3.6, perhaps after updating everything. There is another pip command for using that file to install everything listed. Run that

Re: [OT] Why are BBSes? [was Where's the junk coming from?]

2018-06-28 Thread Terry Reedy
On 6/28/2018 9:05 PM, Avon wrote: On 06/28/18, Grant Edwards pondered and said... GE> OK, I've got to ask... GE> Why are there still BBSes? GE> GE> Who even has a modem these days? [OK, I'll admit my 11 year old GE> Thinkpad T500 has a built-in POTS modem, but it's never been used.

Re: Python27.dll module error from Python 2.7.15/PCbuild/get_externals.bat

2018-06-29 Thread Terry Reedy
On 6/29/2018 3:42 AM, amit.singh2...@gmail.com wrote: I am trying to compile the freshly downloaded Python 2.7.15. When the PCBuild/build.bat goes to pull-in the external modules along with their dependencies it encounters this error for each of the external modules. F:\Dev\depot\tools\source\p

Re: Python 3.7 Windows Help Behaviour

2018-06-29 Thread Terry Reedy
On 6/29/2018 6:14 AM, BlindAnagram wrote: In Python 3.7.0 on Windows the help file (python370.chm) displays with a fixed line length and does not adjust its line length when the user expands the help window horizontally. This behaviour is different to that of the Python 3.6 help file (python360.

Re: naming methods in python (std lib)

2018-06-30 Thread Terry Reedy
On 6/30/2018 7:27 AM, Abdur-Rahmaan Janhangeer wrote: normally, naming methods in python is given by method_name but i see some cases where this is not followed in the std lib ex : dict.fromkeys should it not have been from_keys? No. _ is an option, not a requirement and usually not used

Re: is my interpreation correct

2018-06-30 Thread Terry Reedy
On 6/30/2018 8:57 AM, Sharan Basappa wrote: A code I am using as reference has the following line: from nltk.stem.lancaster import LancasterStemmer The CapitalName indicates a class. I am inferring the following based on above: 1) nltk is a package 2) nltk itself may have module because I see

Re: using trace module in enthought

2018-06-30 Thread Terry Reedy
On 6/30/2018 12:46 PM, Sharan Basappa wrote: I am using enthought for python. Trace module seems to be very useful for my work but somehow I am unable to make it work. When I use the following option, I get the following error: %run What is 'run' and what does it do? Does not exist on Window

Re: $s and %d in python

2018-06-30 Thread Terry Reedy
On 6/30/2018 7:04 PM, Cameron Simpson wrote: On 30Jun2018 05:01, Sharan Basappa wrote: Is there any difference in %d and %s below. I get the same result: my_name = 'Zed A. Shaw' my_age = 35 # not a lie my_height = 74 # inches print "Let's talk about %s." % my_name print "He's %d inches tall."

Re: error in os.chdir

2018-06-30 Thread Terry Reedy
On 6/30/2018 7:36 PM, eryk sun wrote: On Sat, Jun 30, 2018 at 11:21 AM, Chris Angelico wrote: On Sat, Jun 30, 2018 at 9:05 PM, Sharan Basappa wrote: 0 down vote favorite I need to change directory to my local working directory in windows and then open a file for processing. Its just a 3 li

Re: I lost nearly all my modules installing 3.7

2018-07-02 Thread Terry Reedy
On 7/2/2018 9:50 AM, Michael Torrie wrote: If you're wanting to use SciPy and matplotlib, I suggest you stick with Python 3.6. There's little reason to immediately go to Python 3.7. Anytime you upgrade to the very latest version of Python, it's going to take some time for binary wheels to be bu

Re: Python 3.7 Windows Help Behaviour

2018-07-02 Thread Terry Reedy
On 7/2/2018 8:57 PM, Steven D'Aprano wrote: On Fri, 29 Jun 2018 12:53:15 -0400, Terry Reedy wrote: On 6/29/2018 6:14 AM, BlindAnagram wrote: In Python 3.7.0 on Windows the help file (python370.chm) displays with a fixed line length and does not adjust its line length when the user expand

Re: about main()

2018-07-06 Thread Terry Reedy
On 7/5/2018 9:40 PM, Jim Lee wrote: On 07/05/18 18:25, Steven D'Aprano wrote: On Thu, 05 Jul 2018 11:27:09 -0700, Jim Lee wrote: Take a village of people.  They live mostly on wild berries. Because of course a community of people living on one food is so realistic. Even the Eskimos and Inuit

Re: Feasibility of console based (non-Gui) Tkinter app which can accept keypresses?

2018-07-11 Thread Terry Reedy
On 7/11/2018 10:09 AM, jkn wrote: Hi All This is more of a Tkinter question rather than a python one, I think, but anyway... I have a Python simulator program with a Model-View_Controller architecture. I have written the View part using Tkinter in the first instance; later I plan to use Qt.

Re: Python 3.6 can find cairo libs but not Python 2.7

2018-07-12 Thread Terry Reedy
On 7/12/2018 3:52 PM, D'Arcy Cain wrote: $ python2.7 -c "import ctypes.util; print(ctypes.util.find_library('cairo'))" libcairo.so.2 $ python3.6 -c "import ctypes.util; print(ctypes.util.find_library('cairo'))" None I have the 3.6 version of py-cairo installed. Any thoughts? NetBSD 7.1.2 wha

Re: Guido van Rossum resigns as Python leader

2018-07-13 Thread Terry Reedy
On 7/13/2018 9:54 AM, Nicholas Cole wrote: Is it irrational to wonder whether projects should be looking to migrate to new languages? At this point, I would say yes. The immediate effect is no more PEP approvals for maybe 3 months. This kind of announcement makes me worry for the future.

Re: Kindness

2018-07-14 Thread Terry Reedy
On 7/14/2018 3:35 AM, Steven D'Aprano wrote: On Sat, 14 Jul 2018 05:19:36 +0300, Mikhail V wrote: From Marko's check-list: [ ] The group has a polarized us-versus-them mentality Many Python programmers -- perhaps the majority -- know more than one programming language, enjoy some of them, an

Re: Cult-like behaviour [was Re: Kindness]

2018-07-14 Thread Terry Reedy
On 7/14/2018 2:44 PM, Marko Rauhamaa wrote: Having gone through a recent 2to3 effort that left my conscience stained, I can only lament for the lost paradise which was Python 2.7. I am curious, which release of 2.7 do you apply that to? The initial 2.7.0? Should we have stopped there? The

Re: Cult-like behaviour [was Re: Kindness]

2018-07-15 Thread Terry Reedy
On 7/15/2018 7:37 AM, Marko Rauhamaa wrote: One of the classic Unix and Internet tenets is that text is bytes is text. Tenets of a faith may be wrong ;-). An informatic paradigm from more than 45 years ago may be outdated and in need of revision. On byte storage and on the Internet, **ever

Re: IDLE Python won't run or open, neither will it state the error for behaving this way

2018-07-16 Thread Terry Reedy
On 7/16/2018 5:22 AM, Clarence Chanda wrote: HI, I downloaded python 3.7.0 from your python website Which installer for what OS? and it was installed successfully and I was able to run/open python How did you run it? but when I try to run/open IDLE python, How? it just wont open or ru

Re: Cult-like behaviour [was Re: Kindness]

2018-07-16 Thread Terry Reedy
On 7/15/2018 5:28 PM, Marko Rauhamaa wrote: if your new system used Python3's UTF-32 strings as a foundation, Since 3.3, Python's strings are not (always) UFT-32 strings. Nor are they always UCS-2 (or partly UTF-16) strings. Nor are the always Latin-1 or Ascii strings. Python's Flexible S

Re: Cult-like behaviour [was Re: Kindness]

2018-07-16 Thread Terry Reedy
On 7/15/2018 4:09 PM, Jim Lee wrote: On 07/15/18 12:37, MRAB wrote: To me, Unicode and UTF-8 aren't things to be reserved for I18N. I use them as a matter of course because I find it a lot easier to stick with just one encoding, one that will work with _any_ text I have. Which is exactly th

Re: [SUSPICIOUS MESSAGE] Re: Cult-like behaviour [was Re: Kindness]

2018-07-16 Thread Terry Reedy
On 7/16/2018 10:54 AM, Gene Heskett wrote: On Monday 16 July 2018 10:24:28 Marko Rauhamaa wrote: Plus the bytes syntax is really ugly. I wish Python3 had reserved '...' for byte strings and "..." for UTF-32 strings. Aside from the fact that Python3 strings are not UTF-32 strings, this would

Re: [SUSPICIOUS MESSAGE] Re: Cult-like behaviour [was Re: Kindness]

2018-07-16 Thread Terry Reedy
On 7/16/2018 11:50 AM, Dennis Lee Bieber wrote: For Python 4000 maybe Please don't give people the idea that there is any current intention to have a 'Python 4000' similar to 'Python 3000'. Call it 'a mythical Python 4000', if you must use such a term. -- Terry Jan Reedy -- https

Re: Glyphs and graphemes [was Re: Cult-like behaviour]

2018-07-16 Thread Terry Reedy
On 7/16/2018 1:11 PM, Richard Damon wrote: Many consider that UTF-32 is a variable-width encoding because of the combining characters. It can take multiple ‘codepoints’ to define what should be a single ‘character’ for display. I hope you realize that this is not the standard meaning of 'va

Re: Unicode [was Re: Cult-like behaviour]

2018-07-16 Thread Terry Reedy
On 7/16/2018 1:13 PM, Jim Lee wrote: I just think that a language should allow one to bypass Unicode handling easily *when it's not needed*. Both for patching IDLE and for my currently private work, I usually only use Ascii, and no unicode escapes. When I do, it does not matter whether edit

Re: Unicode [was Re: Cult-like behaviour]

2018-07-16 Thread Terry Reedy
On 7/16/2018 1:27 PM, Jim Lee wrote: 90% of the world *is* "beneath my notice" when it comes to programming for myself.   I really don't care if that's not PC enough for you. Had you actually read my words with *intent* rather than *reaction*, you would notice that I suggested the *option* of

Re: Cult-like behaviour [was Re: Kindness]

2018-07-16 Thread Terry Reedy
On 7/16/2018 2:01 PM, Chris Angelico wrote: 🌱【 Stardew Valley Fanart 】🌱*:・゚✧【 800 Subpoints = NEW EMOTE 】#devicat #anime #stardewvalley #fantasy Just to be clear, 🌱【 】🌱・゚✧【 】, \U0001f331, \u3010, \u3011, \uff65, \uff9f, \u2727 are the non-ascii chars in the above. for c in """🌱【 Stardew Val

Re: Users banned

2018-07-16 Thread Terry Reedy
On 7/16/2018 3:27 PM, Grant Edwards wrote: On 2018-07-16, Steve Simmons wrote: +1  Seems to me Bart is being banned for "being a dick" and "talking rubbish" (my words/interpretation) with irritating persistence. Wonder how many of the non-banned members have been guilty of the same thing in on

Re: Glyphs and graphemes [was Re: Cult-like behaviour]

2018-07-16 Thread Terry Reedy
On 7/16/2018 7:02 PM, Richard Damon wrote: On Jul 16, 2018, at 3:28 PM, Terry Reedy wrote: If one is using a broader definition than usual, it is clearer to say so. This is the core of what I wrote. Do you disagree? You are defining a variable/fixed width codepoint set. No, I did

Re: Glyphs and graphemes [was Re: Cult-like behaviour]

2018-07-17 Thread Terry Reedy
On 7/16/2018 10:25 PM, Tim Chase wrote: On 2018-07-17 01:08, Steven D'Aprano wrote: In English, I think most people would prefer to use a different term for whatever "sh" and "ch" represent than "character". The term you may be reaching for is "consonant cluster"? https://en.wikipedia.org/wik

Re: can't install/run pip (Latest version of Python)

2018-07-17 Thread Terry Reedy
On 7/16/2018 11:03 PM, S Lea wrote: Some additional info, which allows me to say the following: 1) Don't know what do you mean by the traceback. >>> 1/o Traceback (most recent call last): File "", line 1, in 1/o NameError: name 'o' is not defined The last four lines 2) In DOS, pip i

Re: test for absence of infinite loop

2018-07-17 Thread Terry Reedy
On 7/17/2018 7:39 AM, Robin Becker wrote: well I understand the problem about not halting. However as you point out in a fixed case I know that the test should take fractions of a second to complete. If nothing else, you can easily add def test_xyz_completes(self): xyz(args) # Forme

Re: copy and paste with a program called clipboard

2018-07-19 Thread Terry Reedy
On 7/19/2018 11:47 AM, no@none.invalid wrote: I just installed Python 3.7 What machine (OS)? How did you install Python? How are you running it? The instructions say to highlight some text and press enter to copy text. What instructions? This is not standard, at least not on Windows. You

Re: copy and paste with a program called clipboard

2018-07-20 Thread Terry Reedy
On 7/19/2018 9:29 PM, eryk sun wrote: On Thu, Jul 19, 2018 at 5:42 PM, Terry Reedy wrote: What happens when you right click depends on the program you are interacting with. When you select and right-click in the current Windows 10 console, used for Command Prompt, PowerShell, Python, and

<    11   12   13   14   15   16   17   18   19   20   >