Hi Anthon

yes, i'm interested since i have  web2py running in mod_wsgi.

in my current setting, hittingn the 'versioning' menu issues a ticket
IOError: sys.stdin access restricted by mod_wsgi

--
Teru

Error ticket for "admin"
Error traceback

Traceback (most recent call last):
  File "gluon/restricted.py", line 178, in restricted
    exec ccode in environment
  File "/var/www/web2py/applications/admin/controllers/mercurial.py",
line 29, in <module>
  File "gluon/globals.py", line 102, in <lambda>
    self._caller = lambda f: f()
  File "/var/www/web2py/applications/admin/controllers/mercurial.py",
line 6, in commit
    uio = ui.ui()
  File "/var/lib/python-support/python2.5/mercurial/ui.py", line 50,
in __init__
    self.readconfig(util.rcpath())
  File "/var/lib/python-support/python2.5/mercurial/ui.py", line 166,
in readconfig
    self.fixconfig(root=root)
  File "/var/lib/python-support/python2.5/mercurial/ui.py", line 222,
in fixconfig
    self.interactive = self.isatty()
  File "/var/lib/python-support/python2.5/mercurial/ui.py", line 74,
in isatty
    ui._isatty = sys.stdin.isatty()
IOError: sys.stdin access restricted by mod_wsgi



On 9月22ζ—₯, 午後6:12, Anthon <[email protected]> wrote:
> Is anyone using the versioning feature?
> It seems currently broken out of the box on my mod_wsgi/apache system.
> The main problem exists because mercurial writes to sys.stdout if some
> warning/error occurs.
> On my fresh system I get those writes because of two issues:
> - non existence of a username in ~/.hgrc for the user running apache
> - readding already added files
>
> The one thing you can do is to capture sys.stdout in mercurial.py:
> commit,
> but that hides all messages/error writing from mercurial.
> The two issues can be resolved differently:
> - by checking for the .hgrc and setting HGUSER if it is not available
> - by using a .hgignore file and not adding an explicit list in
> mercurial.py but using hg addremove option (that is also much nicer
> when doing mercurial commands in the application directory from the
> commandline as it hides all the non-tracked data)
>
> I can provide a patch if there is interest in this way of solving this
> issue
>
> Anthon
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to