Τη Δευτέρα, 4 Μαρτίου 2013 5:14:00 μ.μ. UTC+2, ο χρήστης Νίκος Γκρ33κ έγραψε:
> Hello pythonistas!
>
>
>
> I'am tryign to populate a table with dictionary keys and values:
>
>
>
> Foe that iam using an html template and the questions is what i should write
> inside 'files.html' so then then
On 03/05/2013 01:48 AM, Lowly Minion wrote:
For a typical dict:
i.e.
d = { '1': 'a', '2', 'b' }
I might use something like:
d.get('1', None)
To get the value of 1.
What would be the most pythonic way of getting a nested value of a dictionary
within a list:
some_list = [{ 'item': { 'letter'
VGNU Linux writes:
> ...
> Here is my code:
> from suds.client import Client
> wsdlurl = 'https://46.51.221.138/PBExternalServices/v1/soap?wsdl'
> client = Client(wsdlurl)
> print client
>
> And following is the error that occurs on trying to print client.
> Traceback (most recent call last):
> .
For a typical dict:
i.e.
d = { '1': 'a', '2', 'b' }
I might use something like:
d.get('1', None)
To get the value of 1.
What would be the most pythonic way of getting a nested value of a dictionary
within a list:
some_list = [{ 'item': { 'letter': 'b',
'wor
Hi,
Typing URL in the browser displays document tree as a web page.
Is it right or there is something wrong with it ?
Regards,
VGNU
On Mon, Mar 4, 2013 at 6:45 PM, Joel Goldstick wrote:
>
>
>
> On Mon, Mar 4, 2013 at 5:37 AM, VGNU Linux wrote:
>
>> Hi Guys,
>> I am pretty new to web services.
On Monday 04 March 2013 23:00:31 Chris Angelico did opine:
> On Tue, Mar 5, 2013 at 1:42 PM, Steven D'Aprano
>
> wrote:
> > It's easy for him to
> > deal with it, all he has to do is get a goat to eat the garden waste I
> > toss over the fence, and his problem is solved.
>
> Sounds like someone
On 03/04/2013 01:06 PM, Ferrous Cranus wrote:
> What do you advise me to do?
> Generate html via python code like print '''stuf..''' or use an
> html templating system?
> Up until now i was using the first method and i though it would be a
> nice idea to seperate design from code.
>
> But p
Thanks for the few answers, though those few were very Helpful. The problem
was that some people (even after 4 or more years of university), especially
including almost all beginners, do not know how to start building something
that does something helpful for soceity and everyone around them -- and
On Tuesday, March 5, 2013 3:20:28 AM UTC+8, ian douglas wrote:
> On 03/04/2013 11:06 AM, io wrote:
>
> > esclusioni_file = open('/home/io/btc_trading/exclusions.txt','r')
>
> >
>
> > Windows error :
>
> >
>
> > Traceback (most recent call last):
>
> >File "C:\btc_trading\scripts
>
> > \i
On Tue, Mar 5, 2013 at 1:42 PM, Steven D'Aprano
wrote:
> It's easy for him to
> deal with it, all he has to do is get a goat to eat the garden waste I
> toss over the fence, and his problem is solved.
Sounds like someone got Steven's goat.
*dives for cover*
ChrisA
--
http://mail.python.org/mai
On Mon, 04 Mar 2013 11:09:10 -0500, David Robinow wrote:
> But here's what I don't understand. Why does somebody who posts as
> much as Steven (and thanks for that. Getting cussed at occasionally is a
> cheap price for all the free advice) not set up a simple mail filter
> which trashes all mail
On 2013.03.04 19:58, Steven D'Aprano wrote:
> Windows understands forward slashes in paths too. You can make your code
> (almost) platform-independent, and avoid a lot of problems with unescaped
> backslashes, by always using forward slashes in paths.
Or use os.path.join, the entire purpose of wh
On Mon, 04 Mar 2013 11:20:28 -0800, ian douglas wrote:
> The error tells you everything you need to know: the file system has no
> path/file called "/home/io/btc_trading/markets.csv"
>
> I imagine your CSV file lives in a different location on your Windows 7
> system (which also uses back-slashes
On Mon, 04 Mar 2013 16:36:36 +, Grant Edwards wrote:
> On 2013-02-28, kramer65 wrote:
>
>> I'm using Python for a while now and I love it. There is just one thing
>> I cannot understand. There are compilers for languages like C and C++.
>> why is it impossible to create a compiler that can c
On Mar 4, 2013 3:02 PM, "CM" wrote:
>
>
> > The main issue is that python has dynamic typing. The type of object
> > that is referenced by a particular name can vary, and there's no way
> > (in general) to know at compile time what the type of object "foo" is.
> >
> > That makes generating object
On Tue, Mar 5, 2013 at 9:55 AM, CM wrote:
>
>> The main issue is that python has dynamic typing. The type of object
>> that is referenced by a particular name can vary, and there's no way
>> (in general) to know at compile time what the type of object "foo" is.
>>
>> That makes generating object
On 3/4/2013 5:55 PM, CM wrote:
Could you help me understand this better? For example, if you
have this line in the Python program:
foo = 'some text'
bar = {'apple':'fruit'}
If the interpreter can determine at runtime that foo is a string
and bar is a dict, why can't the compiler figure that o
On Tuesday, March 5, 2013 6:55:06 AM UTC+8, CM wrote:
> > The main issue is that python has dynamic typing. The type of object
>
> > that is referenced by a particular name can vary, and there's no way
>
> > (in general) to know at compile time what the type of object "foo" is.
>
> >
>
> > Tha
> The main issue is that python has dynamic typing. The type of object
> that is referenced by a particular name can vary, and there's no way
> (in general) to know at compile time what the type of object "foo" is.
>
> That makes generating object code to manipulate "foo" very difficult.
Could y
فيس بوك facebook
https://www.facebook.com/pages/%D9%86%D8%AA%D8%A7%D8%A6%D8%AC-%D8%A7%D9%84%D8%A7%D9%85%D8%AA%D8%AD%D8%A7%D9%86%D8%A7%D8%AA-%D9%88%D8%A7%D9%84%D8%AC%D8%A7%D9%85%D8%B9%D8%A7%D8%AA-%D9%88%D8%A7%D8%AC%D8%AA%D9%85%D8%A7%D8%B9%D9%8A%D8%A7%D8%AA/299719160065550?ref=hl
--
http://mail.pyt
Try unpacking the nested struct as a fixed width string and then unpacking the
string.
Then unpack the string
On Monday, March 4, 2013 10:22:07 AM UTC-8, Ari King wrote:
> Hi,
>
>
>
> I'm trying to nest the "info_header", "info_body", and "info_trailer" structs
> (see below) into a "data_
On 3/4/2013 2:20 PM, ian douglas wrote:
I imagine your CSV file lives in a different location on your Windows 7
system (which also uses back-slashes '\' instead of forward-slashes '/',
Forward slashes work fine on Windows except for invoking the executable
at a Command Prompt command line, wh
On Tue, Mar 5, 2013 at 6:59 AM, io wrote:
> Genius!
>
> The code i posted was an example.
> My real code was c:\btc_trading
>
> i was just missing the double slashes!
>
> Thanks , thankyou very much.
>
> :-)
Even on Windows, you can use / as a directory separator. This
generally saves you th
Thanks, btw ...i'm the IT guy!
I was missing the double slash as dougas suggested!++Thanks anyway.
--
http://mail.python.org/mailman/listinfo/python-list
Genius!
The code i posted was an example.
My real code was c:\btc_trading
i was just missing the double slashes!
Thanks , thankyou very much.
:-)
--
http://mail.python.org/mailman/listinfo/python-list
io :
>The following scripts are working fine on linux but, using the same
>version, can't work on windows because i receive the following message:
Thats because there is No such file or directory: '/home/io/btc_trading/
on that Windows PC.
--
Wir danken für die Beachtung aller Sicherheitsbest
Am 04.03.13 20:06, schrieb io:
The following scripts are working fine on linux but, using the same
version, can't work on windows because i receive the following message:
snip
f = open("/home/io/btc_trading/markets.csv","wb")
Windows error :
Traceback (most recent call last):
File "C
On 03/04/2013 11:06 AM, io wrote:
esclusioni_file = open('/home/io/btc_trading/exclusions.txt','r')
Windows error :
Traceback (most recent call last):
File "C:\btc_trading\scripts
\import_json_2_csv_from_web_and_exclusions.py", line 10, in
f = open("/home/io/btc_trading/markets.csv","w
The following scripts are working fine on linux but, using the same
version, can't work on windows because i receive the following message:
Script:
import json
import urllib
import csv
url = "http://bitcoincharts.com/t/markets.json";
response = urllib.urlopen(url);
data = json.loads(response.r
What you wrote seems interesting but i haven't understood.
Can you explain in simple words considering i'm italian and i'm not
understanding so well some terms you use.
Sorry, i'm sure you are suggesting something really valid but can't
understand it.
Marco.
--
http://mail.python.org/mailman/li
On 03/04/2013 11:15 AM, David Robinow wrote:
Crap. I just forgot to do what I just said I would do and didn't go
through my "inconvenient" sequence.
Sorry, Steven. It was unintentional.
FWIW, you don't have to bother moving the python-list address to a To:
field. Just remove the personal add
Hi,
I'm trying to nest the "info_header", "info_body", and "info_trailer" structs
(see below) into a "data_packet" struct. Does anyone know how I can/should
accomplish this? Thanks.
batch_header_format = struct.Struct('!c2h')
info_header_format = struct.Struct('!2hl')
mkt_status_format = struct
Τη Δευτέρα, 4 Μαρτίου 2013 5:59:34 μ.μ. UTC+2, ο χρήστης Michael Torrie έγραψε:
> On 03/04/2013 08:14 AM, Ferrous Cranus wrote:
>
> > Instead of writing the above html data inside my html template how
>
> > would i write it with a for that then will be substituted by the
>
> > python script?
>
El 04/03/13 09:18, newtopython escribió:
Hi all,
I'm super new to python, just fyi.
In the piece of code below, secretWord is a string and lettersGuessed is a
list. I'm trying to find out if ALL the characters of secretWord are included
in lettersGuessed, even if there are additional values i
On Mon, 04 Mar 2013 07:07:53 -0800, Bryan Devaney wrote:
> On Sunday, March 3, 2013 6:45:26 PM UTC, Kwpolska wrote:
>> On Sun, Mar 3, 2013 at 7:46 AM, Michael Torrie
>> wrote:
>>
>> > On 02/21/2013 03:18 AM, leonardo wrote:
>>
>> >> thanks, problem solved
>>
>>
>> >
>> > Apparently not. The
On Mon, Mar 4, 2013 at 8:07 AM, Bryan Devaney wrote:
> On Sunday, March 3, 2013 6:45:26 PM UTC, Kwpolska wrote:
>>
>> It is! How else could he type those two question marks and 10 double-quotes?
>>
>
> Onscreen Keyboard?
Or voice recognition, perhaps. We have no idea what the OP's actual
input
On Mon, Mar 4, 2013 at 7:34 AM, Bryan Devaney wrote:
>> if character not in lettersGuessed:
>>
>> return True
>>
>> return False
>
> assuming a function is being used to pass each letter of the letters guessed
> inside a loop itself that only continues checking if true is returned
On 2013-02-28, kramer65 wrote:
> I'm using Python for a while now and I love it. There is just one
> thing I cannot understand. There are compilers for languages like C
> and C++. why is it impossible to create a compiler that can compile
> Python code to machinecode?
The main issue is that pyth
Crap. I just forgot to do what I just said I would do and didn't go
through my "inconvenient" sequence.
Sorry, Steven. It was unintentional.
--
http://mail.python.org/mailman/listinfo/python-list
Ignoring my own posting ban, since I've clearly been misunderstood ..
On Sat, Mar 2, 2013 at 10:21 PM, Steven D'Aprano
wrote:
> On Sat, 02 Mar 2013 21:11:04 -0500, David Robinow wrote:
>
>> Do you consider it rude that you choose to use a newsreader, thus
>> inconveniencing those of us who use th
On 03/04/2013 08:14 AM, Ferrous Cranus wrote:
> Instead of writing the above html data inside my html template how
> would i write it with a for that then will be substituted by the
> python script?
What templating system are you using? Django's?
> can you please write an example for me that use
On Monday, March 4, 2013 6:18:20 AM UTC-6, newtopython wrote:
[Note: Post has be logically re-arranged for your comprehensive pleasures]
> for character in secretWord:
> if character not in lettersGuessed:
> return True
> return False
>
> What this code is doing is only checking
On Tue, Mar 5, 2013 at 2:35 AM, Tomas Kotal wrote:
> Seems like I found the problem: os._exit probably takes as parametr unsigned
> char, so it uses as error code whatever value it gets modulo 256:
>
> os._exit(1) # process.exitcode == 1
> os._exit(255) # process.exitcode == 255
> os._exit(256)
Dne pondělí, 4. března 2013 15:31:41 UTC+1 Tomas Kotal napsal(a):
> Hi all.
>
>
>
> Recently I discovered a strange behavior with multiprocessing library and
> call to function os.system (a different behavior under Linux and Windows to
> be more specific). I have this simple testing script:
>
> Under Unix, the return value from os.system() encodes more than one
>
> piece of information:
>
>
>
> http://docs.python.org/2/library/os.html#os.system
>
> http://docs.python.org/2/library/os.html#os.wait
>
>
>
> 32512 is 127*256, meaning that the shell exited with return code 127
>
> w
Hi there,
last week I announced the latest and greatest pylint/astng release
but didn't noticed at that time that the download links on our web site
were broken, and that the upload to pypi failed.
This is now fixed, for those who tried during the mean time.
Sorry for the convenience,
--
Sylv
Hello pythonistas!
I'am tryign to populate a table with dictionary keys and values:
Foe that iam using an html template and the questions is what i should write
inside 'files.html' so then then the python script populate the table.
SuperHost - Economy
Χώρος στο δίσκο: 1 GB
On Sunday, March 3, 2013 6:45:26 PM UTC, Kwpolska wrote:
> On Sun, Mar 3, 2013 at 7:46 AM, Michael Torrie wrote:
>
> > On 02/21/2013 03:18 AM, leonardo wrote:
>
> >> thanks, problem solved
>
> >
>
> > Apparently not. The shift key on your keyboard still seems to be
>
> > non-functional. ;)
>
On Tue, Mar 5, 2013 at 1:31 AM, Tomas Kotal wrote:
> But when I run same script on Linux, what I get is this:
>
> 0
> 32512
Under Unix, the return value from os.system() encodes more than one
piece of information:
http://docs.python.org/2/library/os.html#os.system
http://docs.python.org/2/librar
Hi all.
Recently I discovered a strange behavior with multiprocessing library and call
to function os.system (a different behavior under Linux and Windows to be more
specific). I have this simple testing script:
import sys
import os
from multiprocess
> if character not in lettersGuessed:
>
> return True
>
> return False
assuming a function is being used to pass each letter of the letters guessed
inside a loop itself that only continues checking if true is returned, then
that could work.
It is however more work than is need
2013/3/4 :
> I have a problem with encoding in python 27 shell.
>
> when i write this in the python shell:
>
> w=u'العربى'
>
> It gives me the following error:
>
> Unsupported characters in input
>
> any help?
> --
> http://mail.python.org/mailman/listinfo/python-list
Hi,
I guess, you are using
On 03/04/2013 07:18 AM, newtopython wrote:
Hi all,
I'm super new to python, just fyi.
Welcome to the Python list.
In the piece of code below, secretWord is a string and lettersGuessed is a
list. I'm trying to find out if ALL the characters of secretWord are included
in lettersGuessed, eve
On Mon, Mar 4, 2013 at 5:37 AM, VGNU Linux wrote:
> Hi Guys,
> I am pretty new to web services.
> After some googling found that python suds is a suitable module to create
> web service client. I am trying to create a client but its giving me an
> error which is quite confusing for me.
>
> Here i
On Mon, Mar 4, 2013 at 7:18 AM, newtopython wrote:
> Hi all,
>
> I'm super new to python, just fyi.
>
Welcome. Next time write a better subject line, and be sure the code you
post is actually the code you are running. Provide the results you want
and what you get. Provide the traceback if the
In fact this code is already doing what you want, but if the second
character, by example, is not in secrectWord it'll jump out of the for and
return. If you want that interact through the all characters and maybe
count how many them are in the secrectWord, just take of the return there
or do some
Hi all,
I'm super new to python, just fyi.
In the piece of code below, secretWord is a string and lettersGuessed is a
list. I'm trying to find out if ALL the characters of secretWord are included
in lettersGuessed, even if there are additional values in the lettersGuessed
list that aren't in s
Hi Guys,
I am pretty new to web services.
After some googling found that python suds is a suitable module to create
web service client. I am trying to create a client but its giving me an
error which is quite confusing for me.
Here is my code:
from suds.client import Client
wsdlurl = 'https://46.5
On Mon, 04 Mar 2013 01:37:42 -0800, yomnasalah91 wrote:
> I have a problem with encoding in python 27 shell.
>
> when i write this in the python shell:
>
> w=u'العربى'
>
> It gives me the following error:
>
> Unsupported characters in input
>
> any help?
Firstly, please show the COMPLETE err
Am 01.03.2013 17:28, schrieb Isaac Won:
What I really want to get from this code is m1 as I told. For this
purpose, for instance, values of fpsd upto second loop and that from
third loop should be same, but they are not. Actually it is my main
question.
You are not helping yourself...
In any
On 2013-03-04 10:37, yomnasala...@gmail.com wrote:
I have a problem with encoding in python 27 shell.
when i write this in the python shell:
w=u'العربى'
It gives me the following error:
Unsupported characters in input
any help?
Maybe it is not Python related. Did you get an exception? Can yo
I have a problem with encoding in python 27 shell.
when i write this in the python shell:
w=u'العربى'
It gives me the following error:
Unsupported characters in input
any help?
--
http://mail.python.org/mailman/listinfo/python-list
On 01 mars 07:41, Melton Low (devl) wrote:
> Hi Sylvain,
Hi,
> Clicking on the download linked from [1] below gives me an error.
> Same with logilab-astng link [2].
>
> Not Found
>
> The requested URL /pub/pylint/pylint-0.27.0.tar.gz was not found on
> this server.
>
> Apache/2.2.16 (Debian)
63 matches
Mail list logo