on.org/pipermail/python-list/2018-July/735735.html
[2] https://mail.python.org/pipermail/python-list/2018-September/737020.html
Hi,
I hope you are getting better.
Cheers
Karim
--
https://mail.python.org/mailman/listinfo/python-list
On 28/03/2017 18:35, Chris Angelico wrote:
On Wed, Mar 29, 2017 at 3:32 AM, Karim wrote:
On 28/03/2017 18:05, Chris Angelico wrote:
On Wed, Mar 29, 2017 at 2:59 AM, wrote:
Please help if this wont resolve, I have to completely move away from
python.
How about, instead, moving away from
On Wednesday, December 7, 2016 at 12:18:51 PM UTC-5, Michael Torrie wrote:
> On 12/07/2016 09:38 AM, Karim Farokhnia wrote:
> > I am writing a batch file in Python. The batch file, in part, calls a
> > program named "oq-console.bat" to run. Then once the program comes up
&
Hi there,
I am writing a batch file in Python. The batch file, in part, calls a program
named "oq-console.bat" to run. Then once the program comes up (it looks like
windows CMD), I need the batch file to type some commands to make it run (just
like I would do it by myself).
I need the batch f
On 16/11/2016 11:21, M.-A. Lemburg wrote:
s a true Pythonista from the heart. He will always be remember
RIP Rob.
Karim
--
https://mail.python.org/mailman/listinfo/python-list
w in rows:
# NOTE!!!: could have UnicodeEncodeError exception raised here!
try:
writer.writerow(row)
except UnicodeEncodeError, e:
print("\nWarning: {0}. Row '{1}' will not be
extracted!".format(e, row))
Regards
Karim
--
https://mail.python.org/mailman/listinfo/python-list
or the element.
"""
# The idea is to print your Element in a string, parse it using
# minidom and convert it again in XML using toprettyxml function.
raw_string = et.tostring(element, encoding='UTF-8', method='xml')
reparsed = minidom.parseString(raw_string)
return reparsed.toprettyxml(indent='\t', encoding='UTF-8')
Cheers
Karim
--
https://mail.python.org/mailman/listinfo/python-list
main__':
#print(np('\n'.join(find(dirs='.', exts='li',
exclude_filenames='cds.li'
# Test
l = tuple(find(dirs='.', filenames='cds.lib'))
print('\n'.join(l))
Cheers
Karim
--
https://mail.python.org/mailman/listinfo/python-list
f the
year. Numerologists may wish to upgrade to Python 3 before we hit the
unlucky 2.7.13.
Servus,
Benjamin
2.7 release manager
Thank you!
Karim
--
https://mail.python.org/mailman/listinfo/python-list
])
You should also give it the full path of ffmpeg.
On the other hand, in-loop solution would be more preferable since it lets
me to use variable names of the images and paths..
--
https://mail.python.org/mailman/listinfo/python-list
Why not use the split() method on the string of the command line.
Karim
--
https://mail.python.org/mailman/listinfo/python-list
On 26/05/2016 15:31, alex wright wrote:
From the link:
"If you are a woman, know English and have a laptop you can apply for a
pass!"
So it would appear so.
On Thu, May 26, 2016 at 5:39 AM, Karim wrote:
On 26/05/2016 10:58, M.-A. Lemburg wrote:
We’re pleased to announc
On 26/05/2016 10:58, M.-A. Lemburg wrote:
We’re pleased to announce a Django Girls workshop on Sunday, July 17,
the first day of the EuroPython 2016 conference.
If you want participate or know someone who’d like to join, please
fill in our application form on the Django Girls’ website:
On 25/04/2016 17:00, justin walters wrote:
On Mon, Apr 25, 2016 at 3:04 AM, Karim wrote:
On 25/04/2016 09:30, Palpandi wrote:
Hi,
I need to write different sections into a file.
At any point of time, content can be added to any section.
I don't want keep each section into a temp
7;my_file', 'wb').write(content.getvalue())
-
Karim
--
https://mail.python.org/mailman/listinfo/python-list
On 17/04/2016 03:27, Steven D'Aprano wrote:
On Sun, 17 Apr 2016 03:12 am, Mel Drosis wrote:
My phone my accounts my home network have all been affected because of
someone using coding from Python and Linux and GitHub and json. I don't
even know what this stuff is but how do I get rid of it al
On 08/04/2016 12:01, frantisek.fridr...@rubena.cgs.cz wrote:
Hello.
Thank you to Karim, thank you to Wildman for response.
I will describe my problem in more detail. Python on my computer is
installed in /usr directory. My Python contains additional modules such as
numpy, scipy, matplotlib
export PYTHONPATH=${PYTHONPATH}//
export PATH=${PATH}:/bin
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/lib
Mine for pyparsing:
export PYTHONPATH=~/project/pyparsing-2.0.3
Karim
--
https://mail.python.org/mailman/listinfo/python-list
On 29/03/2016 10:29, Sharad Singla wrote:
Thanks. This is more of invoking python code from TCL. I am looking
for the other way round.
Curious, did you rewrite all your TCL code in python?
Regards
Sharad
On Mar 29, 2016 1:10 PM, "Karim" <mailto:kliat...@gmail.com>> w
# @return:
#
variable interpreter
$interpreter exec "d_s = to_string(getDeviceDescription(opsdb,
'$libName', '$deviceName'))"
eval "set value [$interpreter eval {d_s}]"
return $value
}
Karim
--
https://mail.python.org/mailman/listinfo/python-list
e)
# Return target string whithin the cursor selection.
return open_found.getString().strip()
Hope this help.
Karim
--
https://mail.python.org/mailman/listinfo/python-list
Yes it changes your quotechar = "'" into quotechar = '"'
You should no more get the double quoting of the data string and no more
slicing step.
Karim
On 10/01/2016 00:15, Saran Ahluwalia wrote:
Thank you for the feedback on this. I believe that the excel dialec
^
SyntaxError: invalid token
I seek feedback and information on how to address utilizing the most Pythonic
means to do so. Ideally, is there a method that can leverage ElementTree. Thank
you, in advance, for your feedback and guidance.
In fact to get rid of double quote simply create your csv reader like that:
reader = csv.DictReader(data, dialect='excel', skipinitialspace=True)
You should then don't need to slice data variable and reformat it.
Karim
--
https://mail.python.org/mailman/listinfo/python-list
>>> import xml.etree.cElementTree as ElementTree
>>> data = 'RequestType="HoldInquiry">',0001,0070,'
File "", line 1
data = 'RequestType="HoldInquiry">',0001,0070,'
^
SyntaxError: invalid syntax
BUT IF you correct the string and remove the inner quote after
everything's fine:
>>> data = 'RequestType="HoldInquiry">,0001,0070,
'
>>> root = ElementTree.XML(data)
>>> root
Karim
--
https://mail.python.org/mailman/listinfo/python-list
On 01/01/2016 00:25, Mark Lawrence wrote:
On 31/12/2015 18:54, Karim wrote:
On 31/12/2015 19:18, otaksoftspamt...@gmail.com wrote:
I need to check a string over which I have no control for the first 2
non-white space characters (which should be '[{').
The string would
On 31/12/2015 19:54, Karim wrote:
On 31/12/2015 19:18, otaksoftspamt...@gmail.com wrote:
I need to check a string over which I have no control for the first 2
non-white space characters (which should be '[{').
The string would ideally be: '[{...' but could al
arsing' )
>>> print result.asList()
[' I am learning pyparsing']
You'll get your string inside the list.
Hope this help see pyparsing doc for in depth study.
Karim
--
https://mail.python.org/mailman/listinfo/python-list
t/medusa-2.0/medusa/ranking.py", line 9, in
from scheduler.predictionranking import get_prediction_metrics
File
"/home/xeon/repositories/git/medusa-2.0/medusa/scheduler/predictionranking.py", line
6, in
import hdfs
Hello,
Can you try to set your PYTHONPATH like that:
export PYT
Angelico
Comme dit Chris, cette mailing liste est en anglais et tu peux aller sur
le news group fr.comp.lang.python
pour du support en français. Mais je suppose que tu avais compris mais
au cas où.
Cordialement
Karim
--
https://mail.python.org/mailman/listinfo/python-list
On 03/08/2015 14:47, Jean-Michel Pichavant wrote:
te a logging Formatter that will re
Thank you Jean-Michel useful example
K
--
https://mail.python.org/mailman/listinfo/python-list
On 15/07/2015 08:27, Chris Withers wrote:
Hi All,
I'm pleased to announce the release of xlrd 0.9.4:
http://pypi.python.org/pypi/xlrd/0.9.4
This release includes the following changes:
- Automated tests are now run on Python 3.4
- Use ElementTree.iter() if available, not deprecated getiter
I am being sarc
Austerity for python programmers in Portugal !?
;o)
Karim
--
http://mail.python.org/mailman/listinfo/python-list
Thx ! I will update my 0.6 version!
Cheers
Karim
On 09/04/2013 21:38, Chris Withers wrote:
Hi All,
I'm pleased to announce the release of xlrd 0.9.2:
http://pypi.python.org/pypi/xlrd/0.9.2
This release includes the following changes:
- Fix some packaging issues that meant doc
ronic
Frontier Foundation, Creative Commons, and The Tor Project.
Very good book!
1000 Thanks for your unvaluable work.
By the way who is Aaron?
Karim
France
--
http://mail.python.org/mailman/listinfo/python-list
Hello,
There is no such notion in python.
But the closest are iterators and generator functions.
Cheers
Karim
On 18/04/2013 19:06, abdelkader belahcene wrote:
Hi everybody,
I am new to python and I am discovering it.
I know C well,
and want to know if python knows how to manage Pointers
it useful,
Thanks!
Timothy
Hi Timothy,
Very interesting!
Thx a lot!
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
On 01/03/2013 19:10, Vincent Vande Vyvre wrote:
Le 01/03/13 18:53, olsr.ka...@gmail.com a écrit :
comment tracer une cercle contient un numéro au un symbole dans le center dans
python tkinter?
Posez votre question ici:
http://www.developpez.net/forums/f96/autres-langages/python-zope/
Heuu
! = n*(n-1)*(n-2) for n > 1. For n = 0, 1 the
factorial is 1 the reason for the 'return 1'.
f *= n <=> f = f* n
f -= 1 <=> f = f - 1 but sure this is not correct as Kimmo said n = n -
1 or n -= 1
Regards
Karim
--
http://mail.python.org/mailman/listinfo/python-list
2 the factorial is 1 (return by the function).
in other case you multiply previous factoriel value by n (f *= n <=> f =
f *n).
And you decrement n by 1 (f -=1 <=> f = f - 1).
This gives n*(n-)*(n-2) general formula for factorial.
Regards
Karim
--
http://mail.python.org/mailm
On 10/01/2013 16:21, Matty Sarro wrote:
Have you looked a the pexpect class? It works like gangbusters,
especially if you're trying to run something with an interactive shell.
http://www.noah.org/wiki/pexpect
On Thu, Jan 10, 2013 at 9:25 AM, Karim <mailto:kliat...@gmail.com>> w
On 10/01/2013 09:31, Hugo Arts wrote:
On Thu, Jan 10, 2013 at 7:01 AM, Karim <mailto:kliat...@gmail.com>> wrote:
Hello all,
I want to run multiline shell command within python without using
a command file but directly execute several lines of shell.
I al
l lines of code directly.
Example:
cat< myfile
echo "foo"
echo "bar"
...
EOF
Regards
Karim
--
http://mail.python.org/mailman/listinfo/python-list
Le 18/07/2012 04:34, Simon Cropper a écrit :
On 18/07/12 11:44, Maria Hanna Carmela Dionisio wrote:
mmdionisio1...@yahoo.com.ph
Just a newbhie here :>
[snip]
You must know your password to change your options (including changing
the password, itself) or to unsubscribe. It is:
sweet1030
Le 06/07/2012 07:09, Terry Reedy a écrit :
On 7/5/2012 10:30 PM, Karim wrote:
An excellent link to derived all code example to python:
http://www.pitonyak.org/AndrewMacro.sxw.
Even though he only writes in OOBasic, you are right that he explains
the basic concepts needed for accessing the
Le 05/07/2012 23:20, Terry Reedy a écrit :
On 7/5/2012 5:12 AM, Thomas Jollans wrote:
On 07/05/2012 09:26 AM, Karim wrote:
Look at PyUNO from OpenOffice very large API:
http://www.openoffice.org/api/docs
I use to create all my documention (Excell, Writer, etc...) on this
API.
Note that
--
If you can avoid printing this e-mail, you are only doing good for our
planet.
Look at PyUNO from OpenOffice very large API:
http://www.openoffice.org/api/docs
I use to create all my documention (Excell, Writer, etc...) on this API.
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
Euhhh, j'ai pas tout suivi. C'est quoi la feinte?
Cheers
Karim
Le 27/06/2012 21:49, wxjmfa...@gmail.com a écrit :
# -*- coding: cp1252 -*-
# café.py
import sys
print(sys.version)
sys.path.append('d:\\crème')
import crème
import sucré
s = ' '.join([
ing (http://www.python-excel.org/)
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
Cool steven, very helpful
I have a db which holds units data it will avoids me to do such format
conversion.
Thnx
Cheers
Karim
Le 15/05/2012 10:30, Steven D'Aprano a écrit :
I am pleased to announce a new release of byteformat.
http://pypi.python.org/pypi/byteformat
byteformat
Le 07/04/2012 04:07, Keith Medcalf a écrit :
Karim wrote in
news:mailman.1309.1333529851.3037.python-l...@python.org:
This release manage the '.xlsx' format?
http://packages.python.org/openpyxl/
Ah Keith,
I just check this is only for xlsx format so I will make 2 code bran
27;t, I've just released 0.7.6, which will hopefully bring
an end to the brown-bagging.
Any more problems, please let the python-ex...@googlegroups.com
mailing list know...
cheers,
Chris
Hello,
This release manage the '.xlsx' format?
Thanks
Karim
--
http://mail.python.org/mailman/listinfo/python-list
minor difference.
The write() mehtod should keep existing comments.
Does anybody know or implement something like this or is there as
switrch, that I overlooked in hte documentaiton.
I use ConfigObj.
Sure configObj is a must...I use it too.
http://www.voidspace.org.uk/python/configobj.html
Cheers
dFamilyCounter)
patternList = updatePatternList(patternList, guess, bestFamily)
print(''.join(patternList))
if '_ ' not in patternList:
break
if '_ ' not in patternList:
print('SURELY you must be CHEATING, but
Le 29/02/2012 10:01, Karim a écrit :
Le 29/02/2012 09:25, Guillaume Chorn a écrit :
Hello All,
I have a .csv file that I created by copying and pasting a list of
all the players in the NBA with their respective teams and positions
(http://sports.yahoo.com/nba/players?type=lastname&fir
"))
for row in reader:
for key in row:
print("key=", key, " value=", row[key])
Code above not tested but should work.
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
Hello chris,
Thanks for the greet news!
Is there any chance that xlrd read .xlsx format and arrive to decode
special unicode instead of firing some unicode Exception?
Cheers
Karim
Le 21/02/2012 10:18, Chris Withers a écrit :
Hi All,
I'm pleased to announce the release of xlwt
Le 07/12/2011 12:30, Skip Montanaro a écrit :
Does anyone have a recipe for the subject build?
I know Solaris is a minority platform these days, but surely someone has tackled
this problem, haven't they?
Thx,
Skip
./configure
make
make install
Karim
--
http://mail.python.org/ma
tern which usually goes with the
Template pattern.
Except from that all better design or others critics will be welcome.
Regards
karim
___
from __future__ import p
On 08/02/2011 03:59 PM, Peter Otten wrote:
Karim wrote:
values = ( (22.5,21.5,121.5),
(5615.3,615.3,-615.3),
(-2315.7,315.7,415.7) )
it = _xrange_cellnames(rows=len(value), cols=len(values[0]))
table.getCellByName(it.next()).setValue(22.5)
table.getCellByName(it.next()).setValue(5615.3
Thanks Martin,
This is the generator expression version.
I can use both function generator or generator expression version
correction.
Cheers
Karim
On 08/02/2011 02:47 PM, Martin Gracik wrote:
def get_cellnames2(rows, cols):
rows = range(1, rows + 1)
cols = string.ascii_uppercase
On 08/02/2011 02:27 PM, Peter Otten wrote:
Karim wrote:
I need a generator to create the cellname in a excell (using pyuno)
document to assign value to the correct cell.
Isn't there a way to use a (row, column) tuple directly? If so I'd prefer
that. Also, there used to be an a
Thanks Chris!
It seems I am blind I should have seen it...
In fact I started with the need (imaginary) to use enumerate() to get
some indices
but ended in a more simple code. Indeed, your's is simpler.
For the double chars extension I will see if I need it in the future.
Cheers
Karim
Thanks Paul,
I never used string module.
In fact, cellnames.split('') gives a syntax error w/ empty string.
That's why I use the intermediate replace() which accept that.
Cheers
Karim
On 08/02/2011 02:04 PM, Paul Kölle wrote:
Am 02.08.2011 13:45, schrieb Karim:
Hello,
I n
Hello,
I need a generator to create the cellname in a excell (using pyuno)
document to assign value to
the correct cell. The following code does this but do you have some
optimizations
on it, for instance to get the alphabetic chars instead of hard-coding it.
Cheers
karim
Python 2.7.1
On 07/29/2011 03:42 PM, Web Dreamer wrote:
whitespace_split = True
Thanks for the tip!
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
g list.
It changed from non-sense verbal fightings I saw earlier in some discussions
like perl versus python related topic.
Karim
--
http://mail.python.org/mailman/listinfo/python-list
different from
shlex.split()
fonction. the char minus by default is taken as a individual word and in
split
it is not. get_token() method return '-' alone and you have to set
object attributes
wordchars += '-' to have the same behavior as shlex.split().
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
e in
zip(optionlist[0::2],optionlist[1::2])])
Karim
PS: I am from Grenoble, which place in France are from?
On 07/28/2011 06:37 PM, Nobody wrote:
On Thu, 28 Jul 2011 17:48:34 +0200, Web Dreamer wrote:
I would like to parse this TCL command line with shlex:
'-option1 [get_rule A1 B2]
Hello You have you feet on earth Web Dreamer!
Very clever!
Beautiful hack!
Many Thanks
Karim
On 07/28/2011 05:48 PM, Web Dreamer wrote:
Karim a écrit ce mercredi 27 juillet 2011 21:30
dans :
Hello All,
I would like to parse this TCL command line with shlex:
'-option1 [get_rule
On 07/28/2011 02:29 PM, Thomas Rachel wrote:
__all__ = AllList()
Hello Thomas,
Very beautiful and elegant code. Having both at the same time an
instance and a method...
With this 'small' topic, you taught me something today on property
application!
Cheers
Karim
--
http://mail.
Hello,
__all__ = 'api db input output tcl'.split()
or
__all__ = """
api
db
input
output
tcl
""".split()
for lazy boy ;o). It is readable as well.
On 07/28/2011 01:32 AM, Walter Prins wrote:
Hi Karim
On 28 July 2011 00:04, Karim <mailto:karim.liat...@free.fr>> wrote:
On 07/27/2011 12:34 AM, Alan Gauld wrote:
Karim wrote:
I use bpython interpreter. This is a very good interactive
CLI.
it as well.
Cheers
Karim
Michael
* Karim [2011-07-27 23:46]:
Hello,
I use bpython interpreter. This is a very good interactive CLI.
I want to create a CLI with the same features than bpython.
But the cmd std module seems no to be used in this project...
Is there a tool where I can plug a
On 07/27/2011 12:34 AM, Alan Gauld wrote:
Karim wrote:
I use bpython interpreter. This is a very good interactive CLI.
I had never heard of it and had to google for it.
It appears to be a curses based CLI for *nix and MacOS
Ah Windows user.
I want to create a CLI with the same features
using
pyParsing still be easer.
Thanks
Cheers
On Wed, Jul 27, 2011 at 2:08 PM, Karim <mailto:karim.liat...@free.fr>> wrote:
Thank you Dan for answering.
I ended with this and gave up with shlex:
split = ['-option1', '[get_rule', 'A1', &
, highlights, etc...
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
, '$VAR', '-option3',
'TAG']
['-option1', '[get_rule A1 B2]', '-option2', '$VAR', '-option3', 'TAG']
Sure pyParsing seems to be pretty simple but my constraint is to use
standard lib (at maximum). To bad it is
TAG']
Then I will gather in tuple 2 by 2 the arguments.
I tried to the shlec properties attributes 'quotes', 'whitespace', etc...
But I make 'choux blanc'.
If somebody has complex experiences with this module I am in.
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
Very good.
Karim
On 07/25/2011 05:46 PM, jfine wrote:
Hi
I gave a tutorial at this year's EuroPython that covered metaclasses.
You can get the tutorial materials from a link on:
http://ep2011.europython.eu/conference/talks/objects-and-classes-in-python-and-javascript
Jonathan
--
Be careful when using double underscore prefix the variable is "said" to
be private but in fact you can modify it. It is a convention to say
don't change it. And to discourage to use it python change its name
to '___myvar' appending the prefix '_' to
y one '_' after.
Thanks to take time to point that.
Regards
Karim
On 07/22/2011 02:06 PM, Thomas Jollans wrote:
On 22/07/11 13:32, Karim wrote:
I think you did a typo
it is
def foo2(self, len = self._myvar):
while i< len:
dosomething
That, of course, won't wo
not the same variable and behavior in case you want
to access it.
Regards
Karim
On 07/22/2011 01:12 PM, caccolangrifata wrote:
I'm very very new with python, and I have some experience with java
programming, so probably you guys will notice.
Anyway this is my question:
I'd like to use
Hello Michele,
Your solution is great!
You can combine it perhaps with the use of set_defaults() method of the
argparse parser, I gave.
Cheers
karim
On 07/18/2011 01:56 PM, Michele Simionato wrote:
Here is an example by using my own library plac
(http://pypi.python.org/pypi/plac):
class
(namespace_arg.type_of_server)
SERVER.check()
def do_the_build(namespace_args):
if not SERVER:
SERVER = Server(namespace_arg.type_of_server)
SERVER.build()
If I correctly understood your issue.
Regards
Karim
On 07/18/2011 03:48 AM, Victor Hooi wrote:
Hi,
I have a simple Python script to perform
t that information in a
column, where the header is the first line of the column, with the
data following underneath, like so:
Header1Header2Header3Header4
1 2 3 4
5 6 7 8
9
On 06/01/2011 09:39 PM, ru...@yahoo.com wrote:
On Jun 1, 11:11 am, Chris Rebert wrote:
On Wed, Jun 1, 2011 at 12:31 AM, rakesh kumar
Hi
i have a file which contains data
//ACCDJ EXEC DB2UNLDC,DFLID=&DFLID,PARMLIB=&PARMLIB,
// UNLDSYST=&UNLDSYST,DATABAS=MBQV1D0A,TABLE='ACCDJ
ything looks
like a nail", Python's seems to be, "I've got a great collection of all
kinds of neat tools, so I'm going to pretend the hammer that's in there
doesn't exist because I once smashed my thumb with it and it hurt a lot".
HAHAHAHAHAHA Very funny!
This thread is awsome.
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
On 05/26/2011 10:03 PM, Terry Reedy wrote:
On 5/26/2011 11:36 AM, John Bokma wrote:
Ben Finney writes:
[impolite comment not quoted]
Get a life. Or better, just fuck off and die. It will improve both the
world and the Python community, of which you are nothing but a little,
smelly shits
On 05/19/2011 11:35 PM, Andrew Berg wrote:
On 2011.05.16 02:26 AM, Karim wrote:
Use regular expression for bad HTLM or beautifulSoup (google it), below
a exemple to extract all html links:
Actually, using regex wasn't so bad:
import re
import urllib.request
url = 'http://x264.nl
On 05/17/2011 03:05 AM, Andrew Berg wrote:
On 2011.05.16 02:26 AM, Karim wrote:
Use regular expression for bad HTLM or beautifulSoup (google it), below
a exemple to extract all html links:
linksList = re.findall('.*?',htmlSource)
for link in linksList:
print link
I was afra
xx" strings and the style tag following.
The parser doesn't like this. I don't know a solution other than
fixing the html.
(I created a local copy, edited it and it worked.)
Hello,
Use regular expression for bad HTLM or beautifulSoup (google it), below
a exemple to extrac
he help.
So It seems easy to a different pass formatter_class to ArgumentParser.
You can inherite
from HelpFormater class but you have to know the implementation details:
File is located at /lib/python2.7/argparse.py
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
iterables of strings:
new_string = "|".join(str(x) for x in iterable_of_custom_objects)
You just have to implement __str__() python special method for your
"custom_objects".
Regards
Karim
Cheers,
Chris
--
http://rebertia.com
--
http://mail.python.org/mailman/listinfo/python-list
AND MAIN CODE:
try:
webpage = post_request(url=MAIN_URL, data=make_form_data(query))
html= webpage.read()
print('Authentication Information: access granted.')
except URLError, e:
print('Authentication Information: {msg}.'.format(msg=e))
sys.exit(1)
That's all folks Authentication+Posting a request.
make_form_data() is the most important.
To find cgi data dict you can use ClientForm.py (google it!) it is a
good helper to find form data.
Regards
Karim
--
http://mail.python.org/mailman/listinfo/python-list
e a look in std libs (>=v2.7).
Regards
Karim
--
http://mail.python.org/mailman/listinfo/python-list
ry method!
To memorize this pythonic way.
Regards
Karim
--
http://mail.python.org/mailman/listinfo/python-list
On 02/14/2011 01:41 PM, Karim wrote:
Hello,
As I get no response from the tutor python list, I am continuing to
investigate my problem.
In fact the issue is that there are 2 forms in the interactive page
and my request does nothing
instead I get the interactive page not the submission I
7;:"false",
'QueryName': "DKPV",
'QueryType': "personal",
'ACTION': "Query"
}
So the question is how could I specify the correct FORM submission and
how could I chose the correct action because
t
me.sleep(172800)
in the bash script which calls mytunnel.py :
./mytunnel.py ${USERN} ${HMM} ${P2USE} ${p2use2} &
echo $! >>pids
this way I have all the pids
Cheers !
Noah wrote:
On May 5, 7:18 am, Karim Bernardet <[EMAIL PROTECTED]> wrote:
ssh_tunnel = pexpect.spawn (tunnel_co
process. I have tried to get it like this
ssh_tunnel = pexpect.spawn (tunnel_command % globals())
...
print ssh_tunnel.pid
but ssh_tunnel is not the pid of the ssh tunnel
Is there a way to get it using pexpect ?
Cheers
Karim
--
http://mail.python.org/mailman/listinfo/python-list
rks great. The only problem is that I cant see anything in the log
file when I try to open it say with notepad while the program is
running...and this is not good at all!
Any suggestions are appreciated.
Karim
_
See Firewo
1 - 100 of 105 matches
Mail list logo