Re: How to save xarray data to csv

2018-04-16 Thread Rhodri James
h "b"? Don't leave us guessing, we might guess wrong. but the data saving in wrong format Really? It looks to me like you are getting exactly what you asked for. What format were you expecting? What are you getting that doesn't belong. I suspect that you don't

Re: How to save xarray data to csv

2018-04-17 Thread Rhodri James
ay of iterating through entries, surely? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Open (txt) editor and get its content

2018-04-19 Thread Rhodri James
don't, you will wish you had) and read the file back. Is there any other option for getting interactive multi line input from user. input() and patience :-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: seeking deeper (language theory) reason behind Python design choice

2018-05-09 Thread Rhodri James
istakes like that. They are, without fail, embarrassed when I turn on the compiler warning flags. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: seeking deeper (language theory) reason behind Python design choice

2018-05-14 Thread Rhodri James
all the time. Moreover, it's very hard to notice *in your own code* because you read what you meant, not what you wrote. Ask any author about proof-reading, and they'll tell you to get someone else to do it. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Extract data from multiple text files

2018-05-15 Thread Rhodri James
paste the traceback (don't retype it, and definitely don't send us screenshots; attachments aren't allowed on the mailing list). -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: object types, mutable or not?

2018-05-15 Thread Rhodri James
on't have types, or indeed anything much. They are just names, that's all. Every time you use the name, you get the object the name references (or "is bound to" as some people prefer to phrase it). -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: what does := means simply?

2018-05-18 Thread Rhodri James
uages is that to do it well, you need to understand both languages *and both cultures.* The same principle probably applies to computer languages as well; how often have we collectively complained about people trying to write (say) FORTRAN in Python? -- Rhodri James *-* Kynesim Ltd --

Re: syntax oddities

2018-05-18 Thread Rhodri James
proper quoting, trimming and interspersed posting. Clearly you've never worked in the right companies ;-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: syntax oddities

2018-05-18 Thread Rhodri James
nderstand what we're saying... (Disclaimer: I'm a Brit, so I'm poking fun at myself here :-)) It's not actually the worst thing you could do. People speaking NICE AND LOUDLY also tend to speak more slowly and with better diction, both of which make life simpler for your poor old

Re: Issue

2018-05-22 Thread Rhodri James
s, >> >> did you send a log file attached? > > yes I'm afraid it didn't make it to us. The mailing list strips off attachments. Please copy and paste the error into your message, and we'll do our best to decode it for you. -- Rhodri James *-* Kynesim Ltd -- ht

Re: Simple question: how do I print output from .get() method

2018-05-30 Thread Rhodri James
from that, but at its simplest, you could convert that to a list: print(list(sw_report)) Be aware that if you do this, you will exhaust the generator and won't be able to use it anywhere else. >>> def foo(): ... yield 1 ... yield 2 ... yield 3 ... >>>

Re: FULLSCREEN and DOUBLEBUF

2018-06-08 Thread Rhodri James
polite not to top post on this mailing list. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: FULLSCREEN and DOUBLEBUF

2018-06-08 Thread Rhodri James
On 08/06/18 12:41, Darren Pardoe wrote: On Friday, 8 June 2018 12:24:26 UTC+1, Rhodri James wrote: On 08/06/18 09:00, Paul St George wrote: PS: it's generally considered polite not to top post on this mailing list. -- Rhodri James *-* Kynesim Ltd Rhodri, Guys, I have always top posted

Re: Regex to extract multiple fields in the same line

2018-06-13 Thread Rhodri James
") parser.add_argument("--size") line = '06/12/2018 11:13:23 AM python toolname.py --struct=data_block --log_file=/var/1000111/test18.log --addr=None --loc=0 --mirror=10 --path=/tmp/data_block.txt --size=8' args = parser.parse_args(line.split()) print(args) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: How to apply filters to posts

2018-06-14 Thread Rhodri James
tion, in effect) and only read the threads that seem interesting. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Metasyntactic thingies

2018-06-18 Thread Rhodri James
oes anyone else have any? Sometimes I "mangle()" things, but I'm usually boring. "do_something()", "do_something_else()" or (if I'm feeling particularly nostalgic and helpless) "do_something_muttley()". -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: syntax difference

2018-06-18 Thread Rhodri James
x27;t take advantage of the tools. They're just tools, and they may be a help for programmers who can't be bothered to figure things out for themselves, but they aren't required by any means. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: syntax difference

2018-06-18 Thread Rhodri James
. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: syntax difference

2018-06-19 Thread Rhodri James
t("What about me?");'''\ print("And me? Where endeth");"""\ print('the assertion?');\'''' Chris, that's not code... That's a syntactical representation of some random flea circus. Fortunately, my Python interpreter i

Re: help install on Win 7

2018-06-28 Thread Rhodri James
lude the better. Cheers, Rhodri -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: about main()

2018-07-05 Thread Rhodri James
ntains things that might be useful as a module, use the "if __name__ == '__main__'" trick. Otherwise it can be more of a distraction than a help. I'm not a big fan of "main()" functions myself; creating a function which will be called exactly once seems

Re: Kindness

2018-07-13 Thread Rhodri James
counted on the fingers of one hand. Honestly, I don't know why anybody bothers responding to him. Boredom, I suppose. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Kindness

2018-07-16 Thread Rhodri James
On 13/07/18 20:46, Ethan Furman wrote: On 07/13/2018 11:52 AM, Rhodri James wrote: I should point out that the number of people I have killfiled in all my > Internet dealings can be counted on the fingers of one hand. Your left one? * -- ~Ethan~ * Bonus points for getting the refere

Re: Kindness

2018-07-16 Thread Rhodri James
On 16/07/18 15:20, Ethan Furman wrote: On 07/16/2018 06:22 AM, Rhodri James wrote: On 13/07/18 20:46, Ethan Furman wrote: On 07/13/2018 11:52 AM, Rhodri James wrote: I should point out that the number of people I have killfiled in all my  > Internet dealings can be counted on the fing

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

2018-07-16 Thread Rhodri James
On 16/07/18 17:22, Chris Angelico wrote: What characters does it use? Mostly Latin letters? Basic Latin plus U+0174 (LATIN CAPITAL LETTER W WITH CIRCUMFLEX) through to U+0177 (LATIN SMALL LETTER Y WITH CIRCUMFLEX) I think. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman

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

2018-07-16 Thread Rhodri James
also a question of what's required to correctly notate modern Welsh. Back in the late 1980s Acorn asked four Welsh-language scholars that question. They got four different answers :-( -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

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

2018-07-16 Thread Rhodri James
Could you explain? I've only ever had problems with strings *not* being Unicode, and I really don't understand what has you so hot under the collar. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

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

2018-07-16 Thread Rhodri James
On 16/07/18 19:31, Steven D'Aprano wrote: I'm simply not seeing the advantage of: from __future__ import no_unicode print("Hello World!") # stand in for any string handling on ASCII Sure this should be "from __past__ import no_unicode"? gd&

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

2018-07-16 Thread Rhodri James
On 16/07/18 18:38, Rhodri James wrote: Actually having an option of turning off Unicode *does* make it harder to use, because you end up coming across programs that have Unicode and surprise you when they misbehave.  And yes I saw that 90% of your programs aren't intended to get out int

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

2018-07-16 Thread Rhodri James
nd say "That's a gnu," people are likely to stop taking you seriously. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

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

2018-07-16 Thread Rhodri James
pulled the "storming off in a huff rather than answer a question anyone actually asked" defence, so we can go back to debating about important things like how to spell assignment expressions. Oh wait... :-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

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

2018-07-16 Thread Rhodri James
even when that means making sure you don't split characters across buffers. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

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

2018-07-17 Thread Rhodri James
On 17/07/18 02:52, Python wrote: On Mon, Jul 16, 2018 at 08:56:11PM +0100, Rhodri James wrote: The problem everyone is having with you, Marko, is that you are using the terminology incorrectly. [...] When you call UTF-32 a variable-width encoding, you are incorrect. But please don't ove

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

2018-07-17 Thread Rhodri James
On 17/07/18 13:41, Rhodri James wrote: On 17/07/18 02:52, Python wrote: On Mon, Jul 16, 2018 at 08:56:11PM +0100, Rhodri James wrote: The problem everyone is having with you, Marko, is that you are using the terminology incorrectly. [...] When you call UTF-32 a variable-width encoding, you are

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

2018-07-17 Thread Rhodri James
acters, but that's just a detail. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

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

2018-07-17 Thread Rhodri James
On 17/07/18 14:14, Marko Rauhamaa wrote: Rhodri James : On 17/07/18 02:17, Steven D'Aprano wrote: Ah yes, the unfortunate design error that iterating over byte-strings returns ints rather than single-byte strings. That decision seemed to make sense at the time it was made, but turned o

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

2018-07-17 Thread Rhodri James
postalveolar_affricate> Is there a difference between these expressions: rye train right rain right train Again, yes. Very much so this time. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: hello from a very excited and totally blind python programmer and game player

2018-07-25 Thread Rhodri James
is nothing particularly odd about this list that I can think of that might cause problems like that. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: NLTK

2018-08-06 Thread Rhodri James
d NLTK may be trying to do something more comprehensive. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: RFC -- custom operators

2018-08-07 Thread Rhodri James
;t think of any use cases I actually want off-hand. The sorts of things I might apply new operators to are various bits of byte buffer mangling, and most of those feel more pythonic as iterative processes. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: failed to execute scapy commands from remote server

2018-08-09 Thread Rhodri James
your machine have a network interface called "enp6s0f0"? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Object-oriented philosophy

2018-09-06 Thread Rhodri James
#x27;s a bit marginal in your case. I'm not that seasoned in object-oriented design either, but my yardstick would be how much common code does it eliminate? It's a very subjective measure, but basically it's the same subjective measure as for pulling any common code into a se

Re: I need help to put the output from terminal in a csv file

2018-09-07 Thread Rhodri James
ns a colon it may be what you want. "split()" the line at the colon and look at the first half. Once you have "strip()"ed off the spaces at the beginning and the end, is it "status"? If so, you've got your pass and the VALUE you want is in the second half. I hope that helps. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: getfqdn passes a hostname to gethostbyaddr instead of an ip address

2018-09-12 Thread Rhodri James
ist of aliases, and a list of IP addresses, for a host. The host argument is a string giving a host name or IP number. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Serializing complex objects

2018-09-21 Thread Rhodri James
debugger into. Would that be sufficient? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: This thread is closed [an actual new thread]

2018-10-02 Thread Rhodri James
I have been unimpressed with the moderation team for some weeks now, but this is just not acceptable. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Python indentation (3 spaces)

2018-10-08 Thread Rhodri James
catch up, and usually bring some new friends with them. Changing indent sizes is falling into the same trap as changing terminology, I'm afraid. It's an obvious, well-intentioned thought, but it won't actually change anything for the better. Thank you for bringing it up, th

Re: Observations on the List - "Be More Kind"

2018-10-08 Thread Rhodri James
their defense is hardly blameless behaviour, by the way.) Flatly, I do not see what you see. I'm open to persuasion, but I'll say up front I don't expect you to succeed. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Test before PR

2018-10-09 Thread Rhodri James
sonable to test, and hope that later QA and pre-release testing (which should involve running those hard-to-set-up tests) will catch anything that slips through. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Observations on the List - "Be More Kind"

2018-10-09 Thread Rhodri James
On 08/10/18 20:46, Ethan Furman wrote: On 10/08/2018 07:43 AM, Rhodri James wrote: I appreciate that the moderators are volunteers, but they have official power on this list.  Being volunteers doesn't mean that they can't get it wrong, or that we shouldn't call them on it wh

Re: From Mathematica to Jypyter

2018-10-10 Thread Rhodri James
at am I missing? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Observations on the List - "Be More Kind"

2018-10-10 Thread Rhodri James
On 09/10/18 12:12, Rhodri James wrote: On 08/10/18 20:46, Ethan Furman wrote: Banning Rick Johnson: Hopefully no explanation needed [2]. Explanation/justification needed, but given :-)  Again, I killfiled Rick ages ago, and I agree his language does justify banning

Re: Observations on the List - "Be More Kind"

2018-10-11 Thread Rhodri James
On 10/10/18 19:14, Ethan Furman wrote: On 10/10/2018 11:07 AM, Rhodri James wrote: Now I've had a chance to go back through the archive (it's been that kind of day at work), I'm going to have to recant.  I can't find anything that Rick wrote in the week or two before the

Re: From Mathematica to Jypyter

2018-10-11 Thread Rhodri James
On 10/10/18 17:24, jfine2...@gmail.com wrote: Rhodri James wrote: Robin Becker wrote: I'm a great fan of erroneous spelling and this blog needs a spelling check as this quote shows [Paul Romer's blog] "Mathematica exemplifies the horde of new Vandals whose pursuit

Re: Overwhelmed by the Simplicity of Python. Any Recommendation?

2018-10-12 Thread Rhodri James
writing idiomatic Python, never mind efficient Python (arguably I still don't, but as Rob says, who cares?). Don't worry about it; at some point you will discover that the "obvious" Python you are writing looks a lot like the code you are looking at now and thinking "that

Re: Python indentation (3 spaces)

2018-10-15 Thread Rhodri James
tabs are. If you used two-space tab stops and I used (the normal :-) eight, comfortable indentations for you would rapidly become uncomfortably large indentations for me. I'd care about that. I'd also care if you used spaces to make sub-tab stop adjustments to line up appropr

Re: Python indentation (3 spaces)

2018-10-15 Thread Rhodri James
oying behaviour. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Python indentation (3 spaces)

2018-10-15 Thread Rhodri James
On 15/10/18 12:28, Marko Rauhamaa wrote: Rhodri James : On 15/10/18 05:45, Marko Rauhamaa wrote: The two-space indentation is the out-of-the-box default for emacs. Ahem. It's the default for certain C styles. It's not even the default for C-mode itself, which is 4. You must be

Re: Python indentation (3 spaces)

2018-10-15 Thread Rhodri James
On 15/10/18 16:41, Marko Rauhamaa wrote: Rhodri James : On 15/10/18 12:28, Marko Rauhamaa wrote: Try running emacs -q abc.c and observe the indentation depth. """User Option: c-basic-offset This style variable holds the basic offset between indentation level

Re: gmpy2 problem

2018-11-01 Thread Rhodri James
d you copy the error text (preferably cut-and-paste the whole thing rather than retyping!)? The more information you can give us, the better the advice will be from the people who actually understand pip :-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: gmpy2 problem

2018-11-01 Thread Rhodri James
-externally-managed --compile" failed with error code 1 in /tmp/pip-install-kiqba_j_/gmpy2/ " A little googling suggests that you need to install the libgmp3-dev package: $ sudo apt install libgmp3-dev On Thu, 1 Nov 2018 at 16:46, Rhodri James wrote: On 01/11/2018 14:40, jacob m wrot

Re: gmpy2 problem

2018-11-05 Thread Rhodri James
Jacob, please reply to the list, not to me personally. As I said, I have no idea about gmpy2 or pip, I just know how to google. On 01/11/2018 23:28, jacob m wrote: I tried to install libgmp3-dev, but it didn't solved my problem On Thu, 1 Nov 2018 at 18:44, Rhodri James wrote: Replyi

Re: Unable to remove python from my computer.

2018-11-06 Thread Rhodri James
ed off by the mailing list as well. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: SyntaxError: can't assign to literal while using ""blkid -o export %s | grep 'TYPE' | cut -d"=" -f3" % (fs)" using subprocess module in Python

2018-11-06 Thread Rhodri James
ut' element of the pipeline. You have used double quotes in a double quoted string without escaping them. As a result, the interpreter thinks you are trying to assign the string literal " -f3" to the string literal "blkid -o export %s | grep 'Type' | cut -d" -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Unable to remove python from my computer.

2018-11-07 Thread Rhodri James
ignature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> On Tue, Nov 6, 2018 at 5:42 AM Rhodri James wrote: On 06/11/2018 09:25, Thomas Jollans wrote: On 2018-11-06 10:05, Varshit Jain wrote: Hi Python Suppo

Re: Issue in parsing the strings in python code

2018-11-12 Thread Rhodri James
4 NIFunkloch 1da7d068-4548-4446-bf88-a440e49db1b1 wifi -- [snipped for brevity] That looks conveniently aligned. Can't you just slice each line to get the entries you are after? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Question about the definition of the value of an object

2018-11-19 Thread Rhodri James
Attempting to define value here would be at best a massive distraction from the concepts the documentation is trying to get across. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Extend NTFS with "version" of file and "version" of folder, also optionally GIT integration or something like it.

2018-11-19 Thread Rhodri James
ling to see how this is relevant to Python. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Bytes vs Strings (Was Re: [Tutor] Error Python version 3.6 does not support this syntax)

2018-11-29 Thread Rhodri James
run shell commands and parse their output. Have you looked to see if there are existing Python modules that will Just Do The Work for you and avoid all this faffing about? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: multiple JSON documents in one file, change proposal

2018-12-03 Thread Rhodri James
case where you can't. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Fwd: PROBLEM IN LAUNCHING PYTHON...

2019-01-08 Thread Rhodri James
ert, but others here may be able to help if you give them enough information. (The temptation to say "Installing Linux will fix most of your problems" is strong :-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: ValueError: Input contains NaN, infinity or a value too large for dtype('float32')

2019-01-24 Thread Rhodri James
On 23/01/2019 22:29, paulmatth...@gmail.com wrote: You may be using the sklearn package incorrectly; you'll have to read the (apparently quite prolific) documentation yourself, I've never used it. -- Rhodri James *-* Kynesim Ltd So why would you try to answer it? I have the same

Re: Python program to phone?

2019-02-05 Thread Rhodri James
ird it's the "Reply List" button. Sorry I can't help you on your initial problem Likewise :-( -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: exit 2 levels of if/else and execute common code

2019-02-11 Thread Rhodri James
the common code in a function? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Feature suggestions: "Using declarations" i.e. context managers ("with" blocks) tied to scope/lifetime of the variable rather than to nesting

2019-02-19 Thread Rhodri James
be at odds with the broad intent. You're going to have to expand on this somewhat, because at the moment I 100% disagree with you. I would much rather be explicit about the code that a context manager applies to than have it magically add itself to some other block. -- Rhodri

Re: revisiting the "What am I running on?" question

2019-02-19 Thread Rhodri James
vices, it's listing platforms. Linux could be running on an ARM, an x64 chip, or probably a few other chips too. What *specifically* do you want, and why? -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: The NaNny State

2019-02-19 Thread Rhodri James
uot;. In this case, it really isn't helpful. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: How to play with Python in an existing app

2019-02-20 Thread Rhodri James
would be ideal (but expensive). -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Feature suggestion: "Using declarations" i.e. context managers ("with" blocks) tied to scope/lifetime of the variable rather than to nesting

2019-02-21 Thread Rhodri James
ht in your example, particularly as revised here, the context managers showed up the real structure of the code nicely. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Lifetime of a local reference

2019-02-27 Thread Rhodri James
be called until the suite has been executed, so the reference to the open file must exist for at least that long. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: ANN: Creating GUI Applications with wxPython

2019-02-27 Thread Rhodri James
larly when mobiles enter the picture. I'm not convinced it's a completely good idea; a sensible UI for a desktop probably won't be sensible for a phone and vice versa -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Lifetime of a local reference

2019-02-28 Thread Rhodri James
On 27/02/2019 21:39, Roel Schroeven wrote: Rhodri James schreef op 27/02/2019 om 15:18: Aren't we overthinking this? I think it's pretty clear that a variable is never deleted before it goes out of scope. A quick search in the documentation points me to (https://docs.python.org/3

Re: Class Issue`

2019-03-06 Thread Rhodri James
being careless, but it really shouldn't break your expectations. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Class Issue`

2019-03-06 Thread Rhodri James
On 06/03/2019 14:15, Calvin Spealman wrote: C++ (a language I have no respect for) This was uncalled for and inappropriate. Please keep discord civil. That was the civil version :-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Class Issue`

2019-03-06 Thread Rhodri James
spect here after all:) Fine, you've got me there :-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-11 Thread Rhodri James
-*- # -*- explicit -*- could be used to prevent it What exactly would you want "strict" (in whatever form) to do? I'm guessing, but it sounds like you want more static checking. Usually that's the province of linters and type annotation, depending on just what you wan

Re: "use strict"

2019-03-11 Thread Rhodri James
me special symbils to mark that. You sent this to me instead of the list, but never mind. If you want this, Guido's time machine strikes again. Just use type annotations and mypy, or pylint or the like for static checking of unexpected variables. -- Rhodri James *-* Kynes

Re: "use strict"

2019-03-12 Thread Rhodri James
'd hate to be the one trying to implement it and I imagine it's likely to slow down execution a fair bit. Under what condition do you want execution halted? At the moment you haven't been much more specific than "when my program is wrong", which isn't very he

Re: "use strict"

2019-03-12 Thread Rhodri James
all variables, because I think you know what the answer to that one will be. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Rhodri James
ouldn't be so easily the default. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Rhodri James
t to track maybe _var or something like that, i want to solve that problem and this is just a proposal Sorry, I still don't understand. *What* do you want to mark with "_var"? It that a comment? A new keyword? Just a leading underscore? Could you give a full example,

Re: Can my python program send me a text message?

2019-03-20 Thread Rhodri James
x27;t guarantee to deliver the texts at all. We have had clients become very unhappy when confronted with the reality of that. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Syntax for one-line "nonymous" functions in "declaration style"

2019-03-27 Thread Rhodri James
a[n] = x *n which makes it look a lot less magical. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Losing words

2019-04-01 Thread Rhodri James
want: s.send(bytes("PRIVMSG " + channel + " :" + mess + "\n", "UTF-8")) (Try printing out the line you want to send before sending it, and compare it with the example commands in the RFC.) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: DeprecationWarning in Python 3.6 and 3.7

2019-04-02 Thread Rhodri James
y are valid, and frankly I can't be bothered. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: requests

2019-04-04 Thread Rhodri James
h the documentation and see if it makes sense for your needs. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Kill stuck threads

2019-04-09 Thread Rhodri James
trategies. Killing and restarting a thread is always going to be a risky business, and will leave your system less stable. Don't do it unless you have no choice (and if you think you have no choice, you're probably wrong!). -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Friday Filosofical Finking: Import protections

2019-04-18 Thread Rhodri James
;t care about tags. That library is imported within a try/except block. Most imports I've seen have been for mandatory functionality; while my current code could run without its CRC library, everything it tried to talk to would reject its messages, for example! -- Rhodri James *-* Kynesi

Re: Read the table data from PDF files in Python

2019-04-24 Thread Rhodri James
text from the PDF. You are on your own for working out how to parse the tables out of that text, though; the structures in the data you are hoping for simply don't exist. -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

<    1   2   3   4   5   6   7   8   9   >