support, or at least tolerate, Python.
WebRefs:
https://en.wikipedia.org/wiki/Pastebin
https://pastebin.com/
https://codepen.io/
https://jsfiddle.net/
https://gist.github.com/discover
or, to keep things in-house (and possibly better indexed/reusable):
https://gogs.io/
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
"last_name" ]
>>> fname, lname
('Frances', 'Allen')
That said, I've often wished to be allowed to write:
d.first_name
for a dict (cf a class/object).
Hmm, I feel a 'utility' coming-on - but first I'll look to see where/how
such might be used in 'live' code (and be any better than the current
mechanisms)...
Simple collections are one thing. How would you handle the structure if
one or more elements contains a second dimension? eg a list within a
list/a 2D matrix (or if you must, an 'array')?
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
interrogate/modify the OS environment used
https://docs.python.org/3/library/os.html#os.system
However, these days most prefer
https://docs.python.org/3/library/subprocess.html
Please read the pros-and-cons carefully!
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
rectly:
for name, value in C.__members__.items():
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
sier on the eyes! Similarly, the
mainframe legacy of punched-card input is alive-and-well in Python
'standards', which talk of a 79- or 80-character line-width. Please
don't take me by the ear and wash-out my mouth with soap and water!
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
On 25/03/20 10:30 AM, Chris Angelico wrote:
On Wed, Mar 25, 2020 at 8:04 AM DL Neil via Python-list
wrote:
On 23/03/20 8:00 AM, Chris Angelico wrote:
When using textwrap.fill() or friends, setting break_long_words=False
without also setting break_on_hyphens=False has the very strange
On 25/03/20 11:57 AM, Chris Angelico wrote:
On Wed, Mar 25, 2020 at 9:37 AM DL Neil via Python-list
wrote:
As you observe, the problem with terminal emulators is the extent of
their emulation and the degree of adoption of their 'extended features'!
My concern grows because of t
n-answer helps, by leaving you with reading topics which
will realise advice for the concerns you had/hadn't noted to-date.
Now, it's time to get back to the (salt-)mines, if we expect to put
(dino-)steaks on the table tonight...
[https://www.youtube.com/watch?v=2s13X66BFd8]
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
tkinter. I've much to
learn. ;-)
Know that feeling! I try to keep a note-/lab-/log-book of
learning-experiences. Of course, remembering if/where I've noted topics
is quite another matter...
The Python-list has gone a bit quiet. I imagine many are busy trying to
encourage/support co
libraries.
Please describe how you start Python.
Please copy-paste all relevant code, plus the error messages received.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
erminology. Such is
a perennial question, answered many times on the Tutor discussion list
and therefore accessible through those archives!
Web.Refs:
https://docs.python.org/3/tutorial/venv.html
https://www.anaconda.com/distribution/
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
. However, there are some
translations at https://wiki.python.org/moin/SpanishLanguage
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
#x27;m not clear whether the "short-cut" is to access Python at the
command-line, or if it is to start an application under Python.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
le of the
screen, ie half of each axis is for negative values. If the vector and
figure lie in positive space (for example), why include either/both
negative domains?
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ation:
plt.close( 1 )
^
|
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
an FAQ because Python works differently to the way many
MS-Windows users expect. Try:
https://docs.python.org/3/using/windows.html and let us know if you have
further questions.
The Python documentation is well worth investigation...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
mpromising" philosophy
seems non-pythonic (IMHO) - and I won't recommend anything that thinks
it should make decisions because I'm too stupid (see also Apple, MSFT,
Google, ...).
- the latter assessment may be correct, but not IMHO.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
't specify a metaclass.
I find it peculiar that you can give a function as metaclass.
Yes, it just calls whatever object you give it, which allows
for various fun things. You'd be risking a lynching if you took
advantage of it for anything important, though.:-)
--
Greg
--
https://mail.python.org/mailman/listinfo/python-list
only_the_good_stuff( self ):
yield #according to filter
...
my_list = MyList( etc )
...
for a in my_list.only_the_good_stuff():
# calmly carry-on
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
mmunity work,
meaning of open source, gives me a satisfaction.
Thank you for reading till here,
J Arun Mani
:)
--
https://mail.python.org/mailman/listinfo/python-list
On 15/04/20 2:05 PM, mike via Python-list wrote:
I need somehelpwith Python 36-32 and 38-32
I have been using sublime text 3 asmy ide for about 1 year now and everything
was fine -I tried to change to Pycharm 2020 - I was going to use sublime 3 as
my IDE for python36-32 and the Pycharm2020
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ampaign=sig-email&utm_content=webmail>
> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
--
https://mail.python.org/mailman/listinfo/python-list
th asking the meta-level question: why am I
wanting to (try to) do this, this way? Aka: is there a better way?
Web-Refs:
PEP 483 -- The Theory of Type Hints:
https://www.python.org/dev/peps/pep-0483/
PEP 484 -- Type Hints: https://www.python.org/dev/peps/pep-0484/
New in Python 3.5: https://docs.python.org/3/whatsnew/3.5.html
Typing: https://docs.python.org/3/library/typing.html?highlight=pep%20typing
Using "with":
https://docs.python.org/3/reference/compound_stmts.html?highlight=context%20manager#the-with-statement
Typing context managers:
https://docs.python.org/3/library/typing.html?highlight=context%20manager#typing.ContextManager
Using context managers:
https://jeffknupp.com/blog/2016/03/07/python-with-context-managers/
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ncouraging fashion. (see also the
Python Foundation's several diversity, inclusion, and other principles)
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
here', but the other attempts to be 'secure' (in several definitions of
the word).
Web.Refs:
http://mypy-lang.org/
https://www.python.org/dev/peps/pep-0401/
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
/mailman/listinfo/python-list
?good, old days, a Computer Science course would almost
certainly involve some "Numerical Analysis", when such issues would be
discussed. Not sure that many institutions offer such, these days...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ussed. Not sure that many institutions offer such, these days...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
://mail.python.org/mailman/listinfo/tutor
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
id' content, cf 'Dummies
Guide' casual:
https://www.reddit.com/r/Python/comments/g2yfml/springer_released_free_ebooks_epub_and_pdf/
--
Regards,
=dn
--
https://mail.python.org/mailman/listinfo/python-list
, b = 1, 2
Which is why a single element/expression tuple must be expressed with a
comma. Yet, things become slightly confusing when an empty pair of
parentheses defines an empty tuple.
You will find these definitions (and so much more) in the Python
Reference Manual amongst the Python docs.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
d it seems that this is
far better than fiddling with the for loop syntax.
--
https://mail.python.org/mailman/listinfo/python-list
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
I’ve just begun a serious study of using Python as an aspiring programmer/data
scientist.
Can someone please walk me through how to download Python, SO THAT I will be
able to import numpy?
Thanks,
Derek
Sent from Mail for Windows 10
--
https://mail.python.org/mailman/listinfo/python-list
Have tracked-down and communicated with the site owner/operator. He
advised a loop-back problem which has now been blocked.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
brary/functions.html#isinstance
(If this is the wrong group for this question, what group should I use.)
We're happy to help. There is a Python-Tutor group which is a good
'home' for beginners or new-converts to Python...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
or:
... print( "Officer, it wasn't me - honest!" )
...
Officer, it wasn't me - honest!
>>>
or just-for-fun:
>>> try:
... n / d
... except ( ZeroDivisionError, TypeError ):
... print( "I'm sorry, Dave. I'm afraid I can't do that." )
...
I'm sorry, Dave. I'm afraid I can't do that.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
... Is there a way to see all of the groups?
Yes! Follow the link at the bottom of this email msg. Then follow the
link at the bottom of this list's web-page ...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ble, by changing one line, to
re-direct the log to wherever you would like - including the above!
Python library: https://docs.python.org/3/library/logging.html
Logging (testing): https://docs.pytest.org/en/latest/logging.html
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
d easily be
re-directed. On the other hand: YAGNI!)
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
From the above, I'm wondering if a custom exception might be applicable.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
le, change!")
The policy file is a JSON file and could have different categories.
Each category defines a policy for a certain directory tree. Comand
line args could overwrite directory names, as well as user and group.
Or if for example a directory is not specified in the JSON file I am
required to specify it via command line. Otherwise no check can take
place.
default":
{
"match_perms": "644",
"match_permsd": "755",
"match_permsx": "755",
"owner": "manfred",
"group": "manfred"
}
Won't a directory-path be required, to tie 'policy' to 'tree'?
Is that enough feedback to help you take a few more steps?
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
4. That’s an error.
The requested URL was not found on this server. That’s all we know.
>>>
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ctrons became
considerably excited!)
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
mple I have changed the check() method in the Policy class to
get called like this:
def check(self, fpath, user, group, mode):
This means I can test the checks and its result without requiring any
external test data.
Thanks a lot to all for your help.
Given your replies, 'now' might be a good time to take a look at Pytest,
and see how you could use it to help build better code - by building
tested units/functions which are assembled into ever-larger tested-units...
(there is a range of choice/other testing aids if Pytest doesn't take
your fancy)
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
presente messaggio.
--
https://mail.python.org/mailman/listinfo/python-list
def foo(i):
foo.bar += i
foo.bar = 5
--Jach
And as you have shown - foo.bar is effectively a global variable - just
one with a qualified name :-)
--
Tony Flury
--
https://mail.python.org/mailman/listinfo/python-list
error, you could use a 4xx code.
However, I would prefer to use the standard codes, and add a custom header with
more information on the issue.
-- Ed Leafe
--
https://mail.python.org/mailman/listinfo/python-list
ve your
overall programming skills. Once your expertise, in both Python and the
testing tool, matures; you will be better placed to survey the
opportunities and to choose the best alternative for you and your
applications...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
icity
and power justifying the reasons they were given to us, they would
become second-nature to code AND to read!
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
On 2/05/20 11:30 AM, Chris Angelico wrote:
On Sat, May 2, 2020 at 9:14 AM DL Neil via Python-list
wrote:
On 28/04/20 7:36 PM, Chris Angelico wrote:
"Best"? Not sure about that. Functions are first-class objects in
Python, so a function *is* a callable object. You don't h
ple) training, generator functions (and
async-gen-func-s) already offer this (without the static-statement)
def gen( args ):
counter = 0
while counter < max_depth:
yield counter
counter will retain its value ("maintain state") between iterations.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
/listinfo/python-list
keeping-up
with new developments in the language, and providing documentation for
different purposes.
Possibilities for wider community involvement?
https://pyfound.blogspot.com/2020/04/cpython-documentation-next-5-years.html
--
Regards,
=dn
--
https://mail.python.org/mailman/listinfo/python-list
On 3/05/20 9:07 AM, Chris Angelico wrote:
On Sun, May 3, 2020 at 6:33 AM DL Neil via Python-list
wrote:
Is this the way to write Python Enhancement Proposals (PEPs)?
eg https://www.python.org/dev/peps/pep-0008/#indentation
TabError: inconsistent use of tabs and spaces in indentation
https
-c "import sys; print(sys.argv)"
[]
Or it leaves them both in:
$ python -c "import sys; print(sys.argv)"
['-c', 'import sys; print(sys.argv)']
What do you think?
Warm regards,
~Simon
--
https://mail.python.org/mailman/listinfo/python-list
it/s]
print('abcdef', end='\r'); print('ghi', end='')
--
https://mail.python.org/mailman/listinfo/python-list
o solve different possible problems,
to which I can add
- Are you using an import statement?
- Does the error occur after the import?
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
/info.cern.ch/hypertext/WWW/TheProject.html ;-)
--
https://mail.python.org/mailman/listinfo/python-list
On 15/05/20 12:58 AM, Jon Ribbens via Python-list wrote:
On 2020-05-14, MRAB wrote:
Look at the date of the original post. It says "8 May 2009". That's over
11 years ago!
Since then, Google Code has ceased to exist.
Disgraceful, all URLs should continue to work for at least
:
https://docs.python.org/3/using/windows.html
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
the world unite!
--
Regards,
=dn
--
https://mail.python.org/mailman/listinfo/python-list
e for Python-learners to ask questions.
You do not state the Operating System in-use. So, presuming MS-Windows,
please advise if the following reference is accurate, and works for you:
https://docs.python.org/3/using/windows.html
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
vel - and we should use that to update/improve
the docs...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
to contain dicts) as a 2D
data-structure. A list has no constraint, and no expectation that each
'row' has the same number of columns.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
anaged to make it as far as C in my alphabet skills, but yes,
maybe SQL influences)
@Chris: are you on the night-shift?
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
() case?
Is anyone other than me still even using Python curses? :-)
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos
--
https://mail.python.org/mailman/listinfo/python-list
y readable. notEveyoneThinksReadingCamelCaseIsEasy.
Me: "What does casels mean?"
Chris
Angelico
Shortens
Every
Long-name
Savagely
?
Significantly
?
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
om/photos/alangauldphotos
--
https://mail.python.org/mailman/listinfo/python-list
I
can create an attr_get(win)->int function in Python...
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos
--
https://mail.python.org/mailman/listinfo/python-list
On 19/05/2020 20:53, Alan Gauld via Python-list wrote:
> One of the functions discussed that does not appear to have
> a Python equivalent is attr_get() which gets the current
> attributes.
OK, Using inch() I've written the following function:
def attr_get(win):
""
running.
Thank you in advance. Regards.
Please advise if the following reference is accurate, and works for you:
https://docs.python.org/3/using/windows.html
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ng reference is accurate, and works for you:
https://docs.python.org/3/using/windows.html
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
exit
n += 1
print("\n", n, "terms are required.")
--
https://mail.python.org/mailman/listinfo/python-list
ythonista.
Wishing it goes well...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
You still have to call it. ;)
Which definition (may) make it 'worse' (when compared with "break"):
doesn't exit() also close the application-window under some OpSys (if
not all) - which would 'disappear' the output before it could be read?
--
Regards =dn
--
h
/python-list
odule, makes it easy to
locate a 'class' of code dealing with particular data and/or
carrying-out particular functions - much as you might for classes and/or
libraries.
Oh, and a further benefit: (further to "inherited", above) it becomes
easier to avoid the massive tangles caused by trying to mix the
conventions for indenting multi-line SQL code, with those for Python!
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ns don't 'exist'.
(which makes me wonder why code reviews have never queried the point, or
registered that I might seem to be behaving inconsistently...)
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
t to read and debug.
(see also: earlier post mentioning separation of languages/code)
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
On 24/05/20 5:43 PM, Frank Millman wrote:
On 2020-05-23 9:45 PM, DL Neil via Python-list wrote:
My habit with SQL queries is to separate them from other code, cf the
usual illustration of having them 'buried' within the code,
immediately before, or even part of, the query call.
On 24/05/20 8:41 PM, Frank Millman wrote:
On 2020-05-24 9:58 AM, DL Neil via Python-list wrote:
On 24/05/20 5:43 PM, Frank Millman wrote:
On 2020-05-23 9:45 PM, DL Neil via Python-list wrote:
My habit with SQL queries is to separate them from other code, cf
the usual illustration of having
system interfaces
https://docs.python.org/3/library/os.html
stderr is the default destination for logging
Logging HOWTO https://docs.python.org/3/howto/logging.html
https://docs.python.org/3/library/logging.html
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
…
If you’re interested feel free to take a look.
Thanks.
Am on-the-road at present, but will take a look...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
aries offer 'helper functions' or seek to be "accepting"/forgiving
in accepting argument-data. However, this does not (necessarily) imply a
"rule". Another "implementation detail"?
(this time in your favor/to your liking)
If indeed you're seeking a path that is terminated by the separator
character, you need to do what you did in the first example - join an
empty string at the end (this is documented). The terminating separator
_usually_ isn't needed. Sadly, sometimes it appears to be...
Another 'implementation detail' which copes with 'edge cases'. This one
has caught me too!
[so, not that 'intelligent' after all? (joke)]
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
e, and given
that it satisfies your stated spec, you could "define...however you
want" and make the decision without reference to 'the rest of us'.
Once you have coded your solution, which you could then use as 'sample
code', please feel free to suggest a bug-fix which describes:-
- the problem-set,
- the scenario(s) in which it is a problem,
- the problems of your solution (as coded), and
- your idea for a more elegant, Pythonic, solution.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ks( Link )
NB in this scenario it is only necessary to register once - all of the
links at-once, cf registering each link as it is itself instantiated.
Also, that each Link() object is not aware that it is/will be 'registered'!
Later, when it is necessary to carry-out the same action on each of the
objects, we can use the register's iterator/generator (as above).
Critique/other ideas welcome...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
on Standard Library modules for Internet Handling offer
suitable facilities, eg base64 or mimetypes?
https://docs.python.org/3/library/netdata.html
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
(current) project: main
menu > Tools > BuildSystem > Python3 (assumption!). Once done
(configured), always remembered!
Thereafter, when you select Build (ctrl+b), ST will know that it is
working on a Python 'build'...
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
se-and-repeat.
Something like: Make unique file name
https://code.activestate.com/recipes/577200-make-unique-file-name/
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
ous levels of optimization. I have experienced slowdowns from source
built python of the same version as the distribution python even when
using some optimization flags with the configure script. This appears to
be normal behavior and is not cause for concern about the performance of
python 3.9.0b1
--
Joseph Jenne
--
https://mail.python.org/mailman/listinfo/python-list
--
https://mail.python.org/mailman/listinfo/python-list
On 4/06/20 4:59 PM, Meet Agrawal wrote:
I want to unsubscribe from python list and would like to stop recieving
mails from the same.
At the bottom of your request (as reflected), this, and all over
messages to the list is an administration link. At the foot of that
web-page you will find a
to the current project?
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
tps://docs.python.org/3/reference/import.html
* if you believe that, I have a bridge from Brooklyn available at an
absolute bargain price...
(https://nycwalks.com/blog/the-brooklyn-bridge-if-you-believe-that-i-have-a-bridge-in-brooklyn-to-sell-to-you/)
--
Regards,
=dn
--
https://mail.python.org/mailman/listinfo/python-list
ter on the same problem. I really need to get this sorted so my kid can
spend his summer break mastering the coding.
Brgs,
--
https://mail.python.org/mailman/listinfo/python-list
ly fails to convey its full
meaning, eg a student might be enrolled_since, or "zljubisic" has been
paid an higher salary rate_from. As such, 'expanding' its name would
likely improve readability, comprehension, and thus code-quality!
(I'm with the "ick" when it comes to 'artificial' name-mangling)
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
o show you
the exact value of the list index. Thus, giving you a pointer/where to
back-track, to find the source of the problem...
The longer answer: learning to use a debugger or a 'visual' IDE/web-tool.
--
Regards =dn
--
https://mail.python.org/mailman/listinfo/python-list
3701 - 3800 of 5713 matches
Mail list logo