Regular Expressions, Speed, Python, and NFA

2017-04-14 Thread Malik Rumi
I am running some tests using the site regex101 to figure out the correct regexs to use for a project. I was surprised at how slow it was, constantly needing to increase the timeouts. I went Googling for a reason, and solution, and found Russ Cox’s article from 2007: https://swtch.com/~rsc/rege

Pyvenv puts both Python 2 and Python 3 in the same environment. Shocked!

2016-12-20 Thread Malik Rumi
I just created a new venv using pyvenv from a 2.7 install. Now I am shocked to see that I can get both 2.7 and 3.4 in this same venv: (memory) malikarumi@Tetuoan2:~/Projects/cannon/New2.7Projects/memory$ python Python 2.7.12 (default, Nov 19 2016, 06:48:10) [GCC 5.4.0 20160609] on linux2 Type "h

Re: the best online course

2016-07-09 Thread Malik Rumi
I want one of those "knuckle down and learn" classes. But even more than that, I want a class with a real teacher who is available to answer questions and explain things. I've done a lot of books and online video, but there's usually no help. If I search around long enough, I can often find an a

Struggling with os.path.join and fileinput (was 'Path, strings, and lines'

2015-06-15 Thread Malik Rumi
On Saturday, June 13, 2015 at 1:25:52 PM UTC-5, MRAB wrote: > On 2015-06-13 05:48, Malik Rumi wrote: > > On Friday, June 12, 2015 at 3:31:36 PM UTC-5, Ian wrote: > >> On Fri, Jun 12, 2015 at 1:39 PM, Malik Rumi wrote: > >> > I am trying to find a list of strings in

Re: Path, strings, and lines

2015-06-12 Thread Malik Rumi
On Friday, June 12, 2015 at 6:48:18 PM UTC-5, Chris Angelico wrote: > On Sat, Jun 13, 2015 at 5:39 AM, Malik Rumi wrote: > > for line in lines: > > for item in fileinput.input(s2): > > if line in item: > > with open(line + '_list', &#x

Re: Path, strings, and lines

2015-06-12 Thread Malik Rumi
On Friday, June 12, 2015 at 3:31:36 PM UTC-5, Ian wrote: > On Fri, Jun 12, 2015 at 1:39 PM, Malik Rumi wrote: > > I am trying to find a list of strings in a directory of files. Here is my > > code: > > > > # -*- coding: utf-8 -*- > > import os > > import f

Path, strings, and lines

2015-06-12 Thread Malik Rumi
I am trying to find a list of strings in a directory of files. Here is my code: # -*- coding: utf-8 -*- import os import fileinput s2 = os.listdir('/home/malikarumi/Projects/P5/shortstories') with open('/home/malikarumi/Projects/P5/list_stories') as f: lines = f.readlines() for line in lin

Re: Is anyone else unable to log into the bug tracker?

2015-02-26 Thread Malik Rumi
On Thursday, February 26, 2015 at 10:49:19 AM UTC-6, Skip Montanaro wrote: > I have not had problems, but I use the Google login (Open ID, I presume) > option. > > > Skip Ok, I got it. In short, capitalization (or not) matters. Thanks to all. -- https://mail.python.org/mailman/listinfo/python

Re: Windows permission error, 64 bit, psycopg2, python 3.4.2

2015-02-26 Thread Malik Rumi
On Thursday, February 26, 2015 at 2:55:07 PM UTC-6, Mark Lawrence wrote: > On 26/02/2015 15:10, Malik Rumi wrote: > > I am one of those struggling with compile issues with python on 64 bit > > windows. I have not been able to get the solutions mentioned on Stack > > Ove

Windows permission error, 64 bit, psycopg2, python 3.4.2

2015-02-26 Thread Malik Rumi
I am one of those struggling with compile issues with python on 64 bit windows. I have not been able to get the solutions mentioned on Stack Overflow to work because installing Windows SDK 7.1 fails for me. So I stumbled across a precompiled psycopg2, and that reported that it worked, but then

Re: Is anyone else unable to log into the bug tracker?

2015-02-26 Thread Malik Rumi
On Friday, January 9, 2015 at 7:49:09 PM UTC-6, Steven D'Aprano wrote: > I'm having trouble logging into the bug tracker. Is anyone else having the > same problem, that is, your user name and password worked earlier but > doesn't work now? > > http://bugs.python.org/ > > (Yes, I've checked the ca