lamson icon indicating copy to clipboard operation
lamson copied to clipboard

Lamson on Windows (initially, a python-daemon issue)

Open claytondaley opened this issue 12 years ago • 2 comments

I wanted to play with Lamson on a Windows 7 system. Unfortunately, python-daemon won't install. A similar issue (for another python app) and fix is documented here:

https://github.com/josegonzalez/beaver/issues/141

Perhaps an equivalent code change will work for Lamson.

claytondaley avatar Oct 26 '13 20:10 claytondaley

Unfortunately, daemon is more deeply integrated into lamson so the fix isn't as easy. However,

  • Once installed, Lamson will run in debug mode on Windows
  • To get Lamson to install, edit setup.py and replace (in install-requires) the package python-daemon with lockfile
  • Lamson commands weren't running from the command line for me so I had to manually execute c:/path/to/python/python.exe c:/path/to/python/scripts/lamson <commands>
    • If you want the ability to ctrl-c to close, you'll need to open multiple command prompts for ... lamson start --debug, ... lamson log --debug, and all of your ...lamson send... calls.
    • Alternatively, you can use pythonw.exe to run the start and log commands without a command prompt. As a result, you cannot ctrl-c to exit and will have to shut them down using the task manager. In theory, this is fine since the default project is setup to use Router.RELOAD = True which "tell[s] the Router to reload all the handlers for each request" so you shouldn't need to restart the server much.

After python setup.py install, I couldn't run Mutt either. However,

  • A Windows (native) version of Mutt can be downloaded from http://sourceforge.net/projects/mutt-win32.berlios/
  • This program will start with the `mutt -F muttrc' command and mail can be read.
  • HOWEVER, the program will not send emails.
    • First, mutt depends on vi. You can get around this issue by downloading winvi (http://www.winvi.de/en/download.html), renaming the EXE to vi.exe and adding it to the PATH variable. This lets you compose an email.
    • Second, the program generates a permission denied email when trying to access run/queue/.Sent so it won't actually send out mails.

claytondaley avatar Oct 29 '13 00:10 claytondaley

FWIW, last year I tried to use Lamson on Windows:

https://github.com/berdario/lamson/commit/b17da7fe091a68781864a728864f77363d199ef4

I don't have any real interest in neither Lamson nor Windows (I've done it for a friend), if I remember correctly some simple commands would work with that patch, but I never bothered to open a proper PR. Still this might be of interest to someone

berdario avatar Sep 13 '14 19:09 berdario