Working with graphs - Kevin Bacon game

2019-01-09 Thread jskako
I am working on Kevin Bacon game. I have "movies.txt" text file that looks like: Apollo 13 (1995);Bill Paxton;Tom Hanks;Kevin Bacon Begyndte ombord, Det (1937);Aage Schmidt;Valso Holm Bersaglio mobile (1967);Dana Young;Bebe Drake Bezottsovshchina (1976);Yelena Maksimova;Lev Prygunov Dark, The (19

Re: Working with graphs - Kevin Bacon game

2019-01-09 Thread Chris Angelico
On Wed, Jan 9, 2019 at 8:56 PM wrote: > class cvor: > __slots__ = ('ime','susjed') > > My problem is that when I print graph with "print (graph)" I am getting: > > "[<__main__.cvor object at 0x01475275EBE0>, <__main__.cvor object at > 0x01475275EEF0>, <__main__.cvor object at 0x01

Re: Working with graphs - Kevin Bacon game

2019-01-09 Thread MRAB
On 2019-01-09 09:53, jsk...@gmail.com wrote: I am working on Kevin Bacon game. I have "movies.txt" text file that looks like: Apollo 13 (1995);Bill Paxton;Tom Hanks;Kevin Bacon Begyndte ombord, Det (1937);Aage Schmidt;Valso Holm Bersaglio mobile (1967);Dana Young;Bebe Drake Bezottsovshchina (19

Re: Working with graphs - Kevin Bacon game

2019-01-09 Thread Josip Skako
Thank You for your answer, I fixed everything as You said. -- https://mail.python.org/mailman/listinfo/python-list

Re: Working with graphs - Kevin Bacon game

2019-01-09 Thread Josip Skako
Thank You for Your answer, I am not sure what to try anymore, I guess I have to return "ime" from __slots__ at cvor() class to show proper strings and I am not able to do it. Now I am not sure that I am going at right direction to do Kevin Bacon game and will I be able to load this data into gr

Re: Working with graphs - Kevin Bacon game

2019-01-09 Thread MRAB
On 2019-01-09 12:46, Josip Skako wrote: Thank You for Your answer, I am not sure what to try anymore, I guess I have to return "ime" from __slots__ at cvor() class to show proper strings and I am not able to do it. With: class cvor: __slots__ = ('ime','susjed') def __repr__(self):

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread dude . jimbo
On Wednesday, January 9, 2019 at 6:06:35 AM UTC+1, Matthew Lemon wrote: > Hi, > > I would start from scratch with this. > > 1. You have latest Python 2 version. > 2. Use virtualenv to create and activate a new virtual environment. > 3. pip install wxPython and other dependencies. > 4. Get your ap

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread Chris Angelico
On Thu, Jan 10, 2019 at 12:46 AM wrote: > step 5, pyinstaller, is yet another hurdle I hope to avoid. It worked with > py2exe, and it should still work with py2exe (within the efforts I'm prepared > to put into this). Of course py2exe might be ancient and horrible and a bunch > of other things

Re: Working with graphs - Kevin Bacon game

2019-01-09 Thread Josip Skako
I get it now, basically you are accessing class atributes with "self.something", thank You. So now I get this: "['Apollo 13 (1995)', 'Bill Paxton', 'Tom Hanks', 'Kevin Bacon\n', 'Begyndte ombord, Det (1937)', 'Aage Schmidt', 'Valso Holm\n', 'Bersaglio mobile (1967)', 'Dana Young', 'Bebe Drake\

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread Grant Edwards
On 2019-01-09, Chris Angelico wrote: > On Thu, Jan 10, 2019 at 12:46 AM wrote: >> step 5, pyinstaller, is yet another hurdle I hope to avoid. It worked with >> py2exe, and it should still work with py2exe (within the efforts I'm >> prepared to put into this). Of course py2exe might be ancient a

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread songbird
Chris Angelico wrote: ... > You want it to work with minimal effort? Then forget about py2exe and > just distribute your .py files. WAY easier. which then forces the work onto every other person who might install it, if they are on a different architecture or system it even gets worse if you add

Re: Working with graphs - Kevin Bacon game

2019-01-09 Thread MRAB
On 2019-01-09 14:09, Josip Skako wrote: I get it now, basically you are accessing class atributes with "self.something", thank You. So now I get this: "['Apollo 13 (1995)', 'Bill Paxton', 'Tom Hanks', 'Kevin Bacon\n', 'Begyndte ombord, Det (1937)', 'Aage Schmidt', 'Valso Holm\n', 'Bersaglio m

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread MRAB
On 2019-01-09 14:56, songbird wrote: Chris Angelico wrote: ... You want it to work with minimal effort? Then forget about py2exe and just distribute your .py files. WAY easier. which then forces the work onto every other person who might install it, if they are on a different architecture o

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread Grant Edwards
On 2019-01-09, MRAB wrote: > .py files work on any platform that supports Python: Windows, Linux, > MacOs, ... Only after python has been installed along with any other required libraries. > How many platforms support .exe files that were compiled for Windows? None. But when your requirement

How to find files with a string

2019-01-09 Thread anton . gridushko
Hello everyone! I need to find a file, that contains a string TeNum I try to import os import sys def find_value(fname): value = 0 with open(fname, encoding='cp866') as fn: try: for i in fn: if 'TeNam' in i: print(fname) ex

Re: How to find files with a string

2019-01-09 Thread Peter Otten
anton.gridus...@gmail.com wrote: > Hello everyone! > > I need to find a file, that contains a string TeNum > > I try to > > import os > import sys > def find_value(fname): > value = 0 > with open(fname, encoding='cp866') as fn: > try: > for i in fn: >

Re: How to find files with a string

2019-01-09 Thread Brian Oney via Python-list
On Wed, 2019-01-09 at 08:29 -0800, anton.gridus...@gmail.com wrote: > Hello everyone! > > I need to find a file, that contains a string TeNum > > I try to > > import os > import sys > def find_value(fname): > value = 0 > with open(fname, encoding='cp866') as fn: > try: >

Email blast management?

2019-01-09 Thread Tobiah
I'm tasked with adding the ability for users of a website to send bulk emails out to their customers. Before I write it all from scratch, are there any good tools that will allow me to provide: * A place to compose their email, with images and links * A way to manage their list

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread Chris Angelico
On Thu, Jan 10, 2019 at 2:37 AM Grant Edwards wrote: > > On 2019-01-09, MRAB wrote: > > > .py files work on any platform that supports Python: Windows, Linux, > > MacOs, ... > > Only after python has been installed along with any other required > libraries. > > > How many platforms support .exe f

RE: Working with graphs - Kevin Bacon game - WOT

2019-01-09 Thread Avi Gross
[HUMOR ALERT] Others have given answers that are on topic so mine is not needed. I was amused by the understandable spelling error about doing the unusual variant of a Breath First Search when it is clear they meant Breadth. But it may apply in this case. The Keven Bacon Game is a variation on ca

Re: Email blast management?

2019-01-09 Thread Chris Angelico
On Thu, Jan 10, 2019 at 4:19 AM Tobiah wrote: > > I'm tasked with adding the ability for users of a website to > send bulk emails out to their customers. Before I write it all > from scratch, are there any good tools that will allow me to provide: > > > * A place to compose their email, w

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread Matthew Lemon
If the OP was able to take the time to familiarise himself with the technologies, rather than bemoan the difficulty of deploying a ten year old code-base without mininal effort, he might have some success. Code rot is an issue after weeks sometimes, never mind ten years, and Python deployment is

RE: How to find files with a string

2019-01-09 Thread Avi Gross
Anton, OVERVIEW: SET vs DICT Some of us have less experience decoding Cyrillic error messages. The part we can read suggests the program objected to the way a dictionary was being updated. ValueError: dictionary update sequence element #0 has length 35; 2 is required (The Russian said someth

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread Grant Edwards
On 2019-01-09, Chris Angelico wrote: > On Thu, Jan 10, 2019 at 2:37 AM Grant Edwards > wrote: > >> > How many platforms support .exe files that were compiled for Windows? >> >> None. >> >> But when your requirement is to support Windows users who are not >> capable of installing Python, WxWindow

Re: How to find files with a string

2019-01-09 Thread Terry Reedy
On 1/9/2019 11:29 AM, anton.gridus...@gmail.com wrote: I need to find a file, that contains a string TeNum IDLE's 'Find in Files' is a mid-level grep with GUI interface. The code is in idlelib/grep.py if you want to copy code. -- Terry Jan Reedy -- https://mail.python.org/mailman/listinf

curses textpad.py UTF-8 support

2019-01-09 Thread elig0n
is non existent. Unicode input text won't show up. It probably needs to be rewritten with get_wch() as was suggested in the following SO question before get_wch() was implemented, together with proper key code parsing (in do_command()) and probably more as to prevent breakage [ https://stackove

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread songbird
Chris Angelico wrote: ... > This is true - but on the flip side, it's a bit unfair to say "blah > blah Python sucks because py2exe is hard". That's not Python's fault. > You have an additional requirement ("support people who can't install > Python"), and that's going to have extra hassles. LOTS of

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread songbird
MRAB wrote: > On 2019-01-09 14:56, songbird wrote: >> Chris Angelico wrote: >> ... >>> You want it to work with minimal effort? Then forget about py2exe and >>> just distribute your .py files. WAY easier. >> >>which then forces the work onto every other >> person who might install it, if they

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread songbird
Grant Edwards wrote: ... > That said, I've recently switched from py2exe to cx_freeze. However, > even that isn't simple enough for my users, and I bundle the output > from those with Inno Setup. i looked at the one and stopped at that because alas, i have no Windows or MacOS machines to genera

Re: The following modules appear to be missing ['_sysconfigdata']

2019-01-09 Thread songbird
Matthew Lemon wrote: > If the OP was able to take the time to familiarise himself with the > technologies, rather than bemoan the difficulty of deploying a ten year old > code-base without mininal effort, he might have some success. Code rot is an > issue after weeks sometimes, never mind ten ye

RE: How to find files with a string ++

2019-01-09 Thread Avi Gross
[This message comments on three different items being discussed and also on how to find out what kind of help is actually requested and warranted.] People don't usually provide enough context in their requests and I see wildly different attempts to help. When some code is supplied along with perha

RE: dangerous class neighborhood

2019-01-09 Thread Avi Gross
This message is a delayed reply to what Chris wrote late last year and I initially chose not to reply to. My fault, as I was having a few bad days and did not see the content as constructive. But as things are fine now and I have seen more of what Chris posts, I will reply, but not in-line as I