Tuesday, June 19, 2012


Work log June 13 - June 19


I tried to setup the community site on Windows on my desktop. MySQL worked well. However, I got all kinds of errors when I installed python packages. Thus, I got errors when I local tested the community site. 


Here is what I did: 
Download community_csdt tree from https://github.com/electricity345/community.csdt
Installation on Windows:
1 Install mySQL:

* Download MySQL Installer for Windows:
http://www.mysql.com/downloads/
       I also tried the 'MySQL server only'. Installation failed twice.
     * Install 
     * On configuration page, leave current password BLANK, and set new password '12345678'. Patrick used '12345' here. Edit passwd="12345678" in models/database.py correspondingly. 
     * Follow Patrick's community.csdt/docs/installation/config.mySQL.txt:
        **Creating the database (2)-(4)
        (4) init.sql is in community_csdt/community_csdt/config/db
2. Install Pyramid:
     http://docs.pylonsproject.org/projects/pyramid/en/1.3-branch/narr/install.html
  1. Install, or find Python 2.6 for your system.
  2. Install the Python for Windows extensions. Make sure to pick the right download for Python 2.6 and install it using the same Python installation from the previous step.
  3. Install latest setuptools distribution into the Python you obtained/installed/found in the step above: download ez_setup.py and run it using the python interpreter of your Python 2.6 installation using a command prompt:
    c:\> c:\Python26\python ez_setup.py
    
  4. Use that Python’s bin/easy_install to install virtualenv:
    c:\> c:\Python26\Scripts\easy_install virtualenv
    
  5. Use that Python’s virtualenv to make a workspace:
    c:\> c:\Python26\Scripts\virtualenv --no-site-packages env
    
  6. Switch to the env directory:
    c:\> cd env
    
  7. (Optional) Consider using Scripts\activate.bat to make your shell environment wired to use the virtualenv.
  8. Use easy_install pointed at the “current” index to get Pyramid and its direct dependencies installed:
    c:\env> Scripts\easy_install pyramid
* Follow Patrick's community.csdt/docs/installation/pyramid.installation.txt:
        **Initial setup (6)-(9)

Problems during initial setup: 

1. **Initial setup (3): errors in easy_install packages. 
2.                           (6): could not find ezPyCrypto.py in Pycrypto-2.3 as instructed.
3.                           (9): pserve development.ini --reload
                                      error: pkg_resources.DistributionNotFound: community-csdt


UPDATE: 
1. Install MySQL-python for windows, because I actually installed Python2.7: 
    http://www.codegood.com/archives/129



What to do next:
Setup the community using a Linux development server. 
Implement the "friends" and "comments" of users. 

No comments:

Post a Comment