Re: [Tutor] can't install

2013-12-31 Thread Lolo Lolo
On Sunday, December 29, 2013 9:11 PM, Tobias M. wrote: /bin/pyvenv ~/my_venv source ~/my_venv/bin/activate wget python-distribute.org/distribute_setup.py python distribute_setup.py Hi, can i ask why the name ~/my_venv/  .. is that just to indicate ~ as the home directory? so pyvenv alre

Re: [Tutor] can't install

2013-12-29 Thread Lolo Lolo
install i want just for virtualenvs but i wonder if it would replace my other 3.3 as the default on the command line? On Wednesday, December 25, 2013 1:46 PM, Lolo Lolo wrote: >> On Wed, Dec 25, 2013 at 2:16 AM, Tobias M. wrote: >> Is this the error you get when executing distribut

Re: [Tutor] can't install

2013-12-25 Thread Lolo Lolo
>> On Wed, Dec 25, 2013 at 2:16 AM, Tobias M. wrote: >> Is this the error you get when executing distribute_setup.py? >> urllib.error.URLError: Thank you so much Tobias. And yes, that was the exact error message  >> On Tue, Dec 24, 2013 at 11:36 PM, Steven D'Aprano >>wrote: >> But the good n

[Tutor] can't install

2013-12-24 Thread Lolo Lolo
ive struggled all day to install pip on ubuntu 12.04 for python 3.3 . The only pip in the apt-get cache is for python 2. i tried to download pip from source but setuptools is missing when it tries to import it. This made me download setuptools with apt-get but the version there is only for pytho

[Tutor] hello.

2013-06-12 Thread Lolo Lolo
http://pictmania.com/tez.php___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] cant autoincrement

2013-04-26 Thread Lolo Lolo
thanks so much for the code sample eryksun. its working perfectly now:)___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] cant autoincrement

2013-04-26 Thread Lolo Lolo
what does your insert statement look like? According to the documentation (http://www.sqlite.org/faq.html#q1):  "whenever you insert a NULL into that column of the table, the NULL is automatically converted into (1 + the highest value)." The insert statement should look like:   "INSERT INTO

[Tutor] cant autoincrement

2013-04-26 Thread Lolo Lolo
I'm doing a test database with sqlite and have run into some problems. in my 1st table i have an id field:    id INTERGER Primary Key   the database has a few more fields, but when i insert into it, i leave the id field empty as it should be done automatically, but sql complains with an error th

Re: [Tutor] trouble installing library

2013-04-24 Thread Lolo Lolo
a\Fil es Data\virtualenv-1.9.1\scripts\gmapenv\build\googlemaps Storing complete log in C:\Users\Lolo\pip\pip.log     The 2 syntax errors look like python 2 vs python 3 errors:   print main.__doc__    The googlemaps package was created but im just not comfortable with the error as it may be incomp

Re: [Tutor] trouble installing library

2013-04-24 Thread Lolo Lolo
Thanks for the help guys   >> Scripts\activate.bat is a relative path, assuming your current working >> directory is that of the virtual environment.   your suggestion work. Initially i was doing Scripts/activate or Scripts/activate.bat. I guess it didnt like "/" and i didnt realise the differenc

Re: [Tutor] trouble installing library

2013-04-23 Thread Lolo Lolo
>> Run Scripts\activate.bat if your shell is cmd, or Scripts\activate.ps1 >> if you're using PowerShell. These are shell scripts. Do not run them >> with Python. I have to get some sleep but i believe i got the installation in the right version it also insta

Re: [Tutor] trouble installing library

2013-04-23 Thread Lolo Lolo
>> The dot (.) command is used to source a file, It executes Unix like commands >> in bin/activate. Not relevant when  you're on windows. >> Is there a .bat or >> .cmd file instead?   oh i had no idea.. i found the activate file inside a folder name Scripts (instead of bin) and and tried the sam

Re: [Tutor] trouble installing library

2013-04-23 Thread Lolo Lolo
guys having got the install to work, a part of the process fails me.. the full code instruction is:   $ virtualenv --no-site-packages gmapenv $ cd gmapenv $ ls bin/  include/  lib/ $ . bin/activate   since im on windows i used dir instead of ls, but this line:   $ . bin/activate   is not recog

Re: [Tutor] trouble installing library

2013-04-23 Thread Lolo Lolo
Thanks for your response guys:   >> what happens if you cd to the directory where you untarred the file, then >> run "python setup.py install"   This seems to have done the trick!   >> It's an honour to be communicating with the world's last Vista user ;-)))   lol And this was very uncalled for

[Tutor] trouble installing library

2013-04-23 Thread Lolo Lolo
im not sure if anyone is familiar with virtualenv but im tryng to follow a tutorial that has asked me to install virtualenv. i downloaded it in the form of a tar file and extracted it. There was no .exe file to install. The tutorial  asks for me to type this code : $ virtualenv --no-site-package

Re: [Tutor] Socket Programming

2013-04-08 Thread Lolo Lolo
on socket programming. if as a client or server, the information being sent has a buffer size on 2048, will this retrieve all data below 2KB? or can it be exceeded with say 2100? or does 2100 fall under 3KB?___ Tutor maillist - Tutor@python.org To uns

Re: [Tutor] send issue

2013-03-23 Thread Lolo Lolo
> Does this help?   THANKS!! Yes it definately helped. everything is so much clearer now. i always used to wonder about the u"" syntax in python 2___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.or

Re: [Tutor] send issue

2013-03-22 Thread Lolo Lolo
>You can use bytes() function: bytes('%d' % 3,  'utf-8') >b'3' >-m   thanks this has solved everything. can i ask if this is an issue only in python 3 where sockets cant send strings? the docs state the argument is a string, but i believe that was for 2.7. I knew nothing about b'' or bytes

[Tutor] send issue

2013-03-22 Thread Lolo Lolo
using a socket im trying to send a message between connections. it was a string and my python complained:  "TypeError: must be bytes or buffer, not str" .. so i put a b infront of the string. now this works fine but the problem is after recieving this message, i need to send it back with an int

Re: [Tutor] mysqlite

2013-03-08 Thread Lolo Lolo
I finished the tutorial and must say i am very happy. Ill probably go over it again while writing some test dbs. The SQL command line still troubles me   >I'm not running it from Python I'm running it from the OS command line. >You need to open a CMD shell window and cd to your SQL database folder

Re: [Tutor] mysqlite

2013-03-06 Thread Lolo Lolo
>I'm not running it from Python I'm running it from the OS command line. >You need to open a CMD shell window and cd to your SQL database folder >(E:\PROJECTS\SQL in the example above) and then run sqlite3. thanks ill give this a try.   >We can logically split it like this   >and putting them tog

Re: [Tutor] mysqlite

2013-03-06 Thread Lolo Lolo
> You are missing cur.execute('SELECT * from users') thanks:) this has fixed the 1st issue.    guys i still cant use the command line. but i guess i dont really mind as i can just make a .py file... i am having a lot of fun reading through alan's tutorial, everything is becoming very clear bu

[Tutor] mysqlite

2013-03-06 Thread Lolo Lolo
im working through alan's sql tutorial. i have a few questions from there but 1st i wanted to try out an example in Core python's sql example. >>> import sqlite3 >>> cxn = sqlite3.connect('sqlite_test/test') >>> cur = cxn.cursor() after this i created a table called users and inserted some data.

Re: [Tutor] some web and python version questions

2013-03-05 Thread Lolo Lolo
>System32 should be on the PATH, and reg.exe should be available in XP. >C'est la vie. Try "%windir%\System32\reg.exe" instead of "reg". No >rush. It's just an icon. sorry eryksun its my fault i havent been clear... im actually using windows vista not xp. i mixed your new command with the old but

Re: [Tutor] some web and python version questions

2013-03-05 Thread Lolo Lolo
>Check the output of the following command: >    reg query HKLM\Software\Classes\Python.File\DefaultIcon >For me the value is "C:\Python33\DLLs\py.ico".   i get:  'reg' is not recognized as an internal or external command, operable program or batch file.__

Re: [Tutor] some web and python version questions

2013-03-05 Thread Lolo Lolo
  due to the last 2 posts i was able to locate and delete the Iconcache.db through cmd. But after restarting, even though i have the refreshed cache, the icons are still not displaying properly. Will that website http://www.trishtech.com/winxp/rebuild_icon_cache_in_windows_xp.php provide an al

Re: [Tutor] some web and python version questions

2013-03-04 Thread Lolo Lolo
>Installing 3.3 associated .py files with %windir%\py.exe, but it seems >the icon cache wasn't refreshed. You can trigger a refresh by setting >any default in the "Default Programs" control panel applet. If that >fails, you can manually delete the cache from the cmd shell: >    del /a %localappd

Re: [Tutor] some web and python version questions

2013-03-04 Thread Lolo Lolo
> (Please get the quoting right in your messages.  Either you've got a > brain-dead mail program, or you're trying to bypass it's methods.  > On your last message you attributed Eryksun's comments as though they were > your own.)   sorry this is yahoo's fault, i have to manually insert the ">"

Re: [Tutor] some web and python version questions

2013-03-04 Thread Lolo Lolo
I don't know how that's working. There are no executables or batch files with those names in the default installations. It's always "python.exe". Plus the default install options don't muck with the PATH environment variable. Did you rename (or NTFS symlink) the executables and add the install dire

Re: [Tutor] some web and python version questions

2013-03-04 Thread Lolo Lolo
thanks for the recommendations. I think i will try a smaller framework first (haven't decided which) to learn how it all works without the additional features. Then probably will go for Django after i get comfortable working with the web    ___ Tuto

Re: [Tutor] some web and python version questions

2013-03-04 Thread Lolo Lolo
>Python 3.3 will definitely install independently of 3.0 on Windows. It's only >the minor versions that happen in place, like going from 3.3 >to 3.3.1 >If you're running your scripts explicitly, by something like: >   python  myscript.py >then you should be able to say >   python3.3  myscript.p

[Tutor] some web and python version questions

2013-03-04 Thread Lolo Lolo
Hey all, i am running python 3.0 but i realized a lot of modules that support version 3 do not support 3.0. now i want to install Python 3.3 but im worried the two versions (3.0 and 3.3) might confuse my machine. i don't want to lose my work in 3.0 and i installed some modules and saved some wor

Re: [Tutor] confusing installation

2013-03-02 Thread Lolo Lolo
> Like everything in my tutorial the intention is to get you to the point where > you can do the basics yourself but also read and understand > the in depth > tutorials when you need to go there.   i read through some of your tutorial last night and its definately what i need. so i will complete

Re: [Tutor] confusing installation

2013-03-01 Thread Lolo Lolo
> problems else where. i will look for some easy install tutorials > If you just want to know about SQL databases you could try my tutorial topic > (only in the V2 version at the moment but it's nearly > > identical on V3) It > uses SQLite which is part of standard Python, although you can also

Re: [Tutor] confusing installation

2013-03-01 Thread Lolo Lolo
> He is showing you what to expect.  Where ever you see a line starting with > C:\ that is what he typed into the command line session, and > the lines that > follow is the program you are installing informing you what it is doing. > (Until you get to the next C:\ or the end)   i managed to inst

Re: [Tutor] confusing installation

2013-03-01 Thread Lolo Lolo
> Since you use python 3 you will need to download the file: > distribute_setup.py.  To do so you will need a web browser or the > command > line tool curl.  I use Firefox and when I click on the url you give below it > immediately offers to download the required file. thanks i tried it on fire

Re: [Tutor] confusing installation

2013-03-01 Thread Lolo Lolo
> This should be relevant:  > http://www.voidspace.org.uk/python/articles/command_line.shtml in searching for command line tutorials i also came across Powershell and noticed commands that work in one don't work in the other. Would you recommend Powershell over CMD?_

Re: [Tutor] confusing installation

2013-03-01 Thread Lolo Lolo
>Welcome to the world of software development. GUIs like Windows are great for >doing simple things but they can't compete with >command line tools for doing >powerful things quickly. So pretty much every programmer has to get used to >using the command line >sooner or later. >If you are not us

[Tutor] confusing installation

2013-02-28 Thread Lolo Lolo
Hi all. Im working through a database tutorial in a book called Core Python Applications. On page 290 it asks of me to install something though its not clear what it is. I think it has to do with SQLAlchemy. It says if you use Python 3 you'll need to get distribute first. You'll need a web brows

Re: [Tutor] unicode type on cgi script

2005-03-15 Thread Lolo
Hi, Try this solution. Create a script named sitecustomize.py into your python lib directory (i.e /usr/lib/python2.3) and add the following code : #---sitecustomize.py--- import sys sys.setdefaultencoding('latin-1') See u, Lja --- BRINER Cedric <[EMAIL PROTECTED]> wrote: > python-2.3 apa