Change by Ant Man :
--
nosy: +alwaysasetup
___
Python tracker
<https://bugs.python.org/issue45723>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Ant Man :
--
components: +2to3 (2.x to 3.x conversion tool), Argument Clinic, C API,
Cross-Build, Demos and Tools, Distutils, Documentation, Extension Modules,
FreeBSD, IDLE, IO, Installation, Interpreter Core, Library (Lib), Parser,
Regular Expressions, SSL
Change by Ant Man :
--
type: enhancement -> security
___
Python tracker
<https://bugs.python.org/issue45723>
___
___
Python-bugs-list mailing list
Unsubscrib
Change by Ant Man :
--
components: +2to3 (2.x to 3.x conversion tool), Argument Clinic, Build, C API,
Cross-Build, Demos and Tools, Distutils, Documentation, Extension Modules,
FreeBSD, IDLE, IO, Installation, Library (Lib), Parser, Regular Expressions,
SSL, Subinterpreters, Tests
sytems (perhaps Macs fit into this anways)
2. Macs
3. Windows
luckily i do have other examples of python 3 programs which
seem to be multiple platform oriented that i can look at and
see what they've done. so i won't be forever lost in the
wilderness...
thanks for help, :)
ant
sntshkm...@gmail.com wrote:
>> $ pip install readme_renderer[md]
>
> Thanks a lot for this, I wasn't able to figure it out earlier.
does it work ok now? got the upload to go to pypitest?
ant
--
https://mail.python.org/mailman/listinfo/python-list
gt;> i just used it earlier today... worked fine for me.
>> is your account there and verified?
>
> Yes, I have an account on TestPyPI and is verified.
try the above...
ant
--
https://mail.python.org/mailman/listinfo/python-list
rsions of
setuptools, wheel and twine
$ pip install --upgrade setuptools
$ pip install --upgrade wheel
$ pip install --upgrade twine
i just used it earlier today... worked fine for me.
is your account there and verified?
ant
--
https://mail.python.org/mailman/listinfo/python-list
ant wrote:
...
> .pypirc
>=
> [distutils]
> index-servers=
> testpypi
>
> [testpypi]
> repository: https://test.pypi.org/legacy/
> username: UserName
> password: Password
>=
>
>
> and my upload command is:
>
>
>=
> #!/bin
P_SRC_HOME
twine upload --repository testpypi dist/*
=
note: it may take a while for what you uploaded to be made
available for download again even if it reflected in your
project page. sometimes it has been as long as a half hour
or more before it comes down. other times it has only been
a few minutes.
hope this helps...
ant
--
https://mail.python.org/mailman/listinfo/python-list
dieter wrote:
...
thank you for your help. :) i finally worked through
the changes needed at last.
my current package in testing PyPI is at:
https://test.pypi.org/project/ngfp/
which uses my code from:
https://salsa.debian.org/ant-guest/gfpoken-in-python
i ended up needing
dieter wrote:
> ant writes:
>> ...
>> in order to get this far below i had to edit each
>> file and put a try: except: around each import
>> statment checking if the module could be found
>> like (as an example):
>>
>> try:
>> import config
er you like:
https://salsa.debian.org/ant-guest/gfpoken-in-python
ant
--
https://mail.python.org/mailman/listinfo/python-list
dieter wrote:
> ant writes:
>> ant wrote:
>> ...
>>> (env) me@ant(26)~/src/test$ ngfp
>>> Traceback (most recent call last):
>>> File "/home/me/src/env/bin/ngfp", line 7, in
>>> from ngfp import main
>>> ImportError:
ant wrote:
> ant wrote:
>
> ...
>
> script was there, but the package was not actually
> installed.
>
> after installing again i get:
>
>=
>
> (env) me@ant(26)~/src/test$ ngfp
> Traceback (most recent call last):
> File "/home/me/src/env/bin
ant wrote:
...
script was there, but the package was not actually
installed.
after installing again i get:
=
(env) me@ant(26)~/src/test$ ngfp
Traceback (most recent call last):
File "/home/me/src/env/bin/ngfp", line 7, in
from ngfp import main
ImportError: cannot i
dieter wrote:
> ant writes:
>> ...
>> yet not quite all the way yet. i run the
>> commands to make the sdist and wheels and upload
>> it using twine to my test account, but when
>> i install it and try to run it the ngfp.py is
>> not found (i've a
://pypi.org/simple ngfp==0.1.5.post3
thank you and cheers,
ant
--
https://mail.python.org/mailman/listinfo/python-list
Hi all,
I've just seen this: http://sheddingbikes.com/posts/1285063820.html
Whatever you think of Zed Shaw (author of the Mongrel Ruby server and
relatively recent Python convert), he has a very good point in this. I
run Fedora 12 on my home computers, and find it far too much hassle to
try to
On Sep 21, 2:04 pm, Philip Semanchuk phi...@semanchuk.com wrote:
On Sep 21, 2010, at 8:29 AM, Ant wrote:
Don't know about Python 3 on Fedora (I use a Mac), but distrowatch.org
reports that Fedora has been using Python = 2.6 since Fedora 11 which was
released in June of 2009.
Yes you
I don't know whether this thread is going backwards, forwards or
sideways. But a lot of useful information is creeping out of the
woodwork.
I like the points about backwards compatibility. Presumably that
reason alone is enough to keep Tkinter in the standard library for a
long while.
But the
Since I started this thread, I feel a sense of responsibility for it,
in some bizarre way.
Not to prolong its existence, which is clearly a troubling one for
some, but to try to steer it towards some kind of consensus that will
irritate the least number of people. Or better, that will gain some
I rather feel like I'm flogging a dead horse here, but time for
another mile...
First off, I'm not volunteering to lead this effort. I don't think
anyone should
even think about that until and unless the Python Powers That Be
actually
decide that it is worth doing. That is what I meant by 'strong
On Jun 6, 2:22 pm, ant shi...@uklinux.net wrote:
I get the strong feeling that nobody is really happy with the state of
Python GUIs.
snip...
What an interesting set of responses I got!
And - even more interesting - how few of them actually seem to think
there is a problem, let
alone make any
I get the strong feeling that nobody is really happy with the state of
Python GUIs.
Tkinter is not widely liked, but is widely distributed. WxPython and
PyGtk are both
powerful, but quirky in different ways. PyQt is tied to one platform.
And there are
dozens more.
Whether or not we like graphics
On May 25, 6:35 pm, LittleGrasshopper seattleha...@yahoo.com wrote:
With so many choices, I was wondering what editor is the one you
prefer when coding Python, and why. I normally use vi, and just got
I use GVim or vim if on a terminal. There are quite a few plugins and
scripts I find
On May 20, 6:46 pm, namekuseijin namekusei...@gmail.com wrote:
anyway, again, thanks for the laughs.
I'm a Java developer in my day job, and I use Jython for testing out
ideas and prototyping, due to the way Jython makes writing Java so
much easier... Those examples were spot on - things weren't
on
the y-axis. The closest I can get is to have two subplots, one above
the other.
Thanks in advance,
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
On May 14, 3:52 pm, Hyuga hyugaricd...@gmail.com wrote:
...
On the other hand, I just took a peek at the matplotlib example
gallery, which is very diverse, and it has an example that I think is
exactly what you're looking
for:http://matplotlib.sourceforge.net/examples/api/two_scales.html
the default install directory of Python,
particularly if you are non-techy as some packages installers may
look for Python in the default location.
--
Ant
--
http://mail.python.org/mailman/listinfo/python-list
company called Zabkat.
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
On Mar 24, 7:59 am, Sreejith K sreejith...@gmail.com wrote:
...
data is the whole file, but 'less' gives only the two lines...
From this statement (that you are using less), it appears that you are
redirecting sys.stdout to a file or similar - if that is the case, you
may need to flush or close
On Jan 15, 6:43 am, James Mills prolo...@shortcircuit.net.au
wrote:
...
That is a good idea :) Windows teaches you nothing!
Not true. Windows teaches you the art of the workaround...
--
http://mail.python.org/mailman/listinfo/python-list
A 0-width positive lookahead is probably what you want here:
s =
... hdhd a href=http://mysite.com/blah.html;Test iString/i OK/
a
...
...
p = r'href=(http://mysite.com/[^]+)(.*)(?=/a)'
m = re.search(p, s)
m.group(1)
'http://mysite.com/blah.html'
m.group(2)
'Test iString/i OK'
The (?=...)
On Jan 8, 9:06 pm, Tim Arnold tim.arn...@sas.com wrote:
Is there any lib or recipe(s) for doing something like this via python?
Look into the PyWin32 extension module. It gives access to Windows
internals including the COM interface. You'll need to do some research
into how to automate the GUI
You could look at something like the following to turn the class
iteslf into a decorator (changed lines *-ed):
class TaggedWrapper():
* def __init__(self, logMixin, stream):
self.__tag = '%...@%s' % (logMixin.describe(), stream)
logMixin._debug('Created %s' % self)
On Jan 5, 9:47 am, Jack.Chu working...@gmail.com wrote:
Hello guys:
I created a simple tool to count how I wasted my time day by day
;-)http://www.flickr.com/photos/34017...@n07/3169438647/sizes/o/
Looks interesting - did you have some sort of time machine to be
spending that much time in
On Nov 29, 8:44 pm, Josh [EMAIL PROTECTED] wrote:
If you were a beginning programmer and willing to make an investment in
steep learning curve for best returns down the road, which would you pick?
Personally I'd choose Vim for the following reasons:
1) Vim is ubiquitous on Linux/Unix servers.
On Oct 22, 10:03 am, wooly booly [EMAIL PROTECTED] wrote:
I would like to execute a Python script from Windows command line:
Python myscript.py
This works if myscript.py resides in the current folder. My question is:
Is it possible to execute the command above from another folder?
I put
Python with screen.
Thanks for the info. Shame but - cygwin python for this setup it is
(Though I may hunt for a native windows port of screen rather than the
cygwin one.)
Cheers,
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
anyone
know if this is a known issue with screen/Python, or if there is a
workaround, as I'd prefer to have just a single Python instance
installed rather than having Cygwin python and windows Python both
installed.
Cheers,
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
only have
one side of the story.
--
Ant
--
http://mail.python.org/mailman/listinfo/python-list
pyparsing.ParseException: Expected start of line (at char 81), (line:9,
col:1)
Any help appreciated!
Cheers,
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
, and will provide a base for extending the list format.
Thanks,
Ant...
--
http://mail.python.org/mailman/listinfo/python-list
Today's XKCD comic has a nice Python reference!
http://xkcd.com/413/
--
http://mail.python.org/mailman/listinfo/python-list
On Apr 21, 12:23 pm, Diez B. Roggisch [EMAIL PROTECTED] wrote:
http://xkcd.com/413/
:)
Didn't realise you'd posted this when I posted my Batteries
Included... post. Amused me as well!
--
http://mail.python.org/mailman/listinfo/python-list
On Apr 3, 12:37 pm, [EMAIL PROTECTED] wrote:
What's the neatest and/or most efficient way of testing if one of a
A different approach:
words = [he, sh, bla]
name = blah
True in (word in name for word in words)
True
name = bling
True in (word in name for word in words)
False
Perhaps not
On Apr 3, 2:27 pm, George Sakkis [EMAIL PROTECTED] wrote:
...
It's even prettier in 2.5:
any(word in name for word in words)
George
And arguably the most readable yet!
--
http://mail.python.org/mailman/listinfo/python-list
On Mar 31, 5:40 pm, Rui Maciel [EMAIL PROTECTED] wrote:
...
So far the decision seems to be a no brainer. Yet, Python 3000 will arrive
in a few months. As it isn't backwards compatible with today's Python,
there is the risk that no matter what I learn until then, I will end up
having to
there for us all in the future given the ubiquity of the JVM in
the enterprise and willingness of corporations to accept such
endorsements!
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
In the spirit of Simple is better than complex. and totally
bypassing the intention of quines (though not necessarily the
definition):
--- probably_not_a_real_quine.py
import sys
for line in open(sys.argv[0]):
print line,
--
;-)
--
Ant.
--
http
and numpy/scipy
communities) may have ignored this thread.
Cheers,
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
be achieved by
doing pairs.sort() and pairs.reverse() before iterating over the pairs
list.
Cheers,
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
Hi all,
The Jython team got an honourable mention on the Headius blog this
morning. Apparently they have got Django working with the latest
builds of Jython: http://headius.blogspot.com/2008/01/jythons-back-baby.html
So congratulations!
--
Ant.
--
http://mail.python.org/mailman/listinfo/python
On Jan 2, 7:07 pm, Rob Williscroft [EMAIL PROTECTED] wrote:
Ant wrote in news:34a84caa-5387-40a2-a808-
1) Is there a module out there for extracting files from an ISO?
There are command line programs that can do this:
http://cdrecord.berlios.de/old/private/cdrecord.html
...
One problem
there for extracting files from an ISO?
2) Is there a module out there for extracting icons from a Windows
exe?
Cheers,
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
between the jar of phlogiston and the perpetual
motion machine.
lol!
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
Python on xkcd:
http://xkcd.com/353/
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
that it is the
same for the Mac, and I shouldn't think it has anything to do with
your problem here.
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
On Nov 30, 9:10 am, SMALLp [EMAIL PROTECTED] wrote:
Hello!
I'm new in wxPython and before i start doing anything I have one qustion.
Shoul I use some of editors like boa, spe or shoud i use my favorite
text editor!
i used IDLE on windows and it seamd nice. Now i have linux installed on
my
On Nov 22, 7:14 pm, oj [EMAIL PROTECTED] wrote:
On Nov 22, 3:02 pm, Ant [EMAIL PROTECTED] wrote:
...
It's basically just one line to implement:
foldr = lambda f, i: lambda s: reduce(f, s, i)
It's just reduce with currying, I'm not sure it adds that much to what
python already offers.
Yes
, not just
from the built-ins but (I believe) from the standard library as well.
I thought that at the last count it was merely being moved out into
functools (or somewhere similar).
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
On Nov 23, 4:09 am, kyo guan [EMAIL PROTECTED] wrote:
...
'120.exe'.rstrip('.exe')
Another approach since you seem to be working with filenames is using
the os.path module:
import os.path as path
s = test.torrent
t = test.exe
u = test
path.splitext(s)[0]
'test'
path.splitext(t)[0]
'test'
), )
commaSeparate(myList)
Of course the lambda function in this case could be a named function,
helping with both readability and reuse, but I think the latter is
conceptually easier to grasp when reading the code.
Discuss.
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
the
graphical side of things.
--
Ant
--
http://mail.python.org/mailman/listinfo/python-list
On Nov 6, 9:59 am, Shriphani [EMAIL PROTECTED] wrote:
...
My main intention is to state that each of the variables namely a, b,
c, ## can take value from 1 to 9.
How do I go about this ?
It sounds like you are after something like:
for var in (a, b, c, d, e, f):
assert var in [1, 2, 3, 4,
a
look at
http://antroy.blogspot.com/2007/04/swing-testing-with-jython-and-jemmy.html
for an example of how I have successfully used Jython for Swing
testing. More information can be found on
http://www.jython.org/Project/index.html
Cheers,
--
Ant.
--
http://mail.python.org/mailman/listinfo
On Nov 1, 9:12 am, Anand [EMAIL PROTECTED] wrote:
...
This code works for dictionaries of any nested level.
At least up to the max recursion depth.
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
in Jython. It's be interesting to see a proper comparison of
how different types of program run.
The VM startup overhead is much slower mind, but then that's only an
issue for very small programs.
Cheers,
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
On Nov 1, 1:23 pm, Ant [EMAIL PROTECTED] wrote:
On Nov 1, 11:37 am, Ze'ev [EMAIL PROTECTED] wrote:
...
... Jython is currently significantly slower than Python.
...
Not according to this
:http://blogs.warwick.ac.uk/dwatkins/entry/benchmarking_parallel_pytho...
...
So that's parallel
On Oct 22, 10:44 am, Paul Brauner [EMAIL PROTECTED] wrote:
Hi, I'm working on a project that outputs several languages including
(hopefully) python. My problem is that the generic backend architecture
has not been designed to output correctly indented code, and that would
be helpful if there
= b-1
if b a: a = a-1
# end if
else:
print 'oops!'
# end if
# end def foobar
The help in the script looks pretty good.
--
Ant...
--
http://mail.python.org/mailman/listinfo/python-list
On Oct 22, 1:26 pm, Py-Fun [EMAIL PROTECTED] wrote:
I'm stuck trying to write a function that generates a factorial of a
number using iteration and not recursion. Any simple ideas would be
appreciated.
The following simple adder functions should give you an idea of how
recursion can be recast
if j == 6:
return fn(i, j)
I guess to an extent it would depend on the exact situation as to
which of these is more suitable. Are there any other recommended
solutions to this?
--
Ant...
--
http://mail.python.org/mailman/listinfo/python-list
frameworks/modules that
they use are available and b) if and when doing so would be
advantageous.
I suspect that many of the projects I have that are solid and are in
no imminent need of development will remain 3k for several years.
Cheers,
--
Ant
--
http://mail.python.org/mailman/listinfo
On Sep 21, 4:47 am, W. Watson [EMAIL PROTECTED] wrote:
How about in the case of MS Win?
Both emacs and vim have GUI versions that run on Windows.
--
Ant...
--
http://mail.python.org/mailman/listinfo/python-list
for arbitrary keywords with arbitrary rules.
--
Ant...
--
http://mail.python.org/mailman/listinfo/python-list
via Add/Remove Programs and then reinstall 2.5
again.
--
Ant...
--
http://mail.python.org/mailman/listinfo/python-list
:\0test.py action key=value key=value
action
key=value
key=value
--
Ant.
--
http://mail.python.org/mailman/listinfo/python-list
):
stops = 0
while True:
stops += 1
wage = stops * std_rate + max(0, stops - limit) * (over_rate -
std_rate)
yield stops, wage
truck = counter(0.4, 1.4, 22)
for i in range(30):
print Stopped %s times, with accumulated wage of $%s %
truck.next()
--
Ant...
http
: os.path.abspath(os.curdir)
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Aug 21, 10:29 am, [EMAIL PROTECTED] wrote:
On 21 Aug, 11:27, Ant [EMAIL PROTECTED] wrote:
On Aug 21, 10:10 am, [EMAIL PROTECTED] wrote:
...
myLocation = GetMyLocation()
print myLocation
C:/folder
Do you mean the folder containing the script? Or the current working
On Aug 21, 10:47 am, Bjoern Schliessmann usenet-
[EMAIL PROTECTED] wrote:
Ant wrote:
...
| print os.path.split(sys.argv[0])[0]
$ cd tmp
~/tmp$ ../test.py
..
~/tmp$
That's rather not what's intended. I'd try os.path.abspath(__file__)
instead.
Fair point. On Win32 sys.argv[0] always seems
implementation for
the .Net platform.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
in the standard library should do most
of what you want, perhaps with the addition of beautiful soup if you
need to scrape the pages for data: http://www.crummy.com/software/BeautifulSoup/
HTH.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
that operate by side
effect), and so is not used directly.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
such as for loops etc)
*must* start on a new line (with indentation as necessary):
http://docs.python.org/ref/compound.html
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
by default (you have to wrap the standard collections
in a synchronised wrapper to make them thread safe).
--
Ant...
--
http://mail.python.org/mailman/listinfo/python-list
On Aug 10, 11:47 am, [EMAIL PROTECTED] wrote:
On 10 kol, 11:02, Ant [EMAIL PROTECTED] wrote:
...
yes,Python 2.5 is on the path, but how can I remove panda3d from that
path?
Hit Win - Break to bring up the System Properties dialog (you can also
get here through the Control Panel).
Go
! I don't know the answer to the OP's
question mind you, I'd played around a little with it a while ago, but
nothing more.
Python: Batteries and Turtles included!
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
echo %PATH
% into your console window to find out if Python2.5 is in the path. If
you are using the default setup, then c:\Python25 should be on the
path.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
index 9.
Cheers,
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
are using m.group(1) with your match object
instead of m.group(0) - the former gets the first group (i.e.
everything between the first set of parens - in your case the wmv|3gp
expression), whereas the latter will return the entire match.
Post your actual code, not just the regex.
--
Ant...
http
On Aug 5, 12:31 pm, Campbell Barton [EMAIL PROTECTED] wrote:
...
* ubuntu have some of their install tools in python.
Gentoo Linux's Portage package management tool is written in Python.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
just after a wage), and secondly that I have
experience in good development practice (the open source projects I
worked on had better infrastructure in place than two of the three
companies I've worked for since!)
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo
win32clipboard, win32con, random
text = Some text to stick on the clipboard
win32clipboard.OpenClipboard()
win32clipboard.SetClipboardData(win32con.CF_TEXT, text)
win32clipboard.CloseClipboard()
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
and variables, then the python equivalent is a module.
I'm new to python, and I can't seem to find in the docs how to create
the python equivalent of what's called in most OOP languages static
classes, can you give me a hint ?
Hope the above was what you are looking for.
--
Ant...
http
driver from www.mysql.com,
and you an then use JDBC from within Jython. You'll just need to add
the mysql jdbc jar to your classpath.
HTH.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
class CServerThread(threading.Thread):
def __init__(self, network):
self.network = network
def run(self):
while (1):
self.clientSocket, self.clientAddress =
self.network.accept()
...
HTH.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org
as I can tell.
I've certainly never bothered with them.
In the case of your statAdd above, self is never used in the method
body, and so this is a clear indication that a module level function
would be more appropriate.
--
Ant...
http://antroy.blogspot.com/
--
http://mail.python.org/mailman
1 - 100 of 304 matches
Mail list logo