Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 3396 by alexkb...@gmail.com: No logging in RB 1.7.25 - instead getting apache error
http://code.google.com/p/reviewboard/issues/detail?id=3396

What version are you running?
Review Board 1.7.25 on Centos 6.5 with Apache 2.2.15; Python 2.6. As best I can tell, I'm using Django 1.4.11 and Djblets 0.7.29.

What's the URL of the page containing the problem?
Running on local network (no public url)

What steps will reproduce the problem?
1. From web ui, create new review request assigned to self, with summary, description, and all other fields left blank
2. Publish request
3a. Navigate to admin panel > Server Log
3b. From ssh tunnel to server: list the contents of the error log directory (as specified from the web ui config pane under Admin > Logging)

What is the expected output? What do you see instead?
Expected to see something logged in the web ui; expected to see a log file in the log file directory. Log file from ui and log file directory are both empty. Instead, the apache error log contains:
[Mon Jun 02 17:32:53 2014] [error] Traceback (most recent call last):
[Mon Jun 02 17:32:53 2014] [error] File "/usr/lib64/python2.6/logging/__init__.py", line 776, in emit
[Mon Jun 02 17:32:53 2014] [error]     msg = self.format(record)
[Mon Jun 02 17:32:53 2014] [error] File "/usr/lib64/python2.6/logging/__init__.py", line 654, in format
[Mon Jun 02 17:32:53 2014] [error]     return fmt.format(record)
[Mon Jun 02 17:32:53 2014] [error] File "/usr/lib64/python2.6/logging/__init__.py", line 439, in format
[Mon Jun 02 17:32:53 2014] [error]     s = self._fmt % record.__dict__
[Mon Jun 02 17:32:53 2014] [error] KeyError: 'request_info'

See below for additional details.

What operating system are you using? What browser?
See version section. Not browser related.

Please provide any additional information below.
Bug report requested by Christian Hammond after an email exchange, included below:

From: Christian Hammond <chip...@chipx86.com>
Subject: Re: 1.5 to 1.7 DB Migration
Date: May 30, 2014 at 3:45:40 PM MDT
To: alexkb...@gmail.com
Cc: "reviewbo...@googlegroups.com" <reviewbo...@googlegroups.com>

It's more likely to be a bug than a configuration issue. This code is old, though. I'm surprised people are starting to report issues here.

I need more of the traceback. Can you show me the entire trace, along with the exact repro case?

In fact, would you mind filing a bug with this information, so we can track it?

Christian

--
Christian Hammond - chip...@chipx86.com
Review Board - http://www.reviewboard.org
Beanbag, Inc. - http://www.beanbaginc.com


On Fri, May 30, 2014 at 2:20 PM, <alexkb...@gmail.com> wrote:
I'm having a very similar problem to schmi...@gmail.com. I'm running Review Board 1.7.25 on Centos 6.5 with Apache 2.2.15; Python 2.6. As best I can tell, I'm using Django 1.4.11 and Djblets 0.7.29. (I found this by looking at __init__.py from the /usr/lib/python2.6/site-packages/djblets and ...django.) This is a new install of RB, not a migration from a previous version.

I have not been able to get the RB logging to do anything. I changed the settings from the admin panel as documented - nothing. (empty log files, nothing on the web ui Server Log.) I checked the ownership of the logging directory - apache user has write permissions. I know from some other debugging that the Apache server is running as the 'apache' user. To be really sure it wasn't a permission issue, I set the logging directory to /tmp - still nothing there and nothing from the web ui.

Next step was the apache error logs, which led me to this discussion. I am getting errors from /usr/lib64/python2.6/logging/__init__.py

I noticed that they at a different line number from <schmi...@gmail.com>'s post, and that I'm using python 2.6 instead of 2.7.

Here is the apache error log snippet:
[Fri May 30 00:01:24 2014] [error] Traceback (most recent call last):
[Fri May 30 00:01:24 2014] [error] File "/usr/lib64/python2.6/logging/__init__.py", line 776, in emit
[Fri May 30 00:01:24 2014] [error]     msg = self.format(record)
[Fri May 30 00:01:24 2014] [error] File "/usr/lib64/python2.6/logging/__init__.py", line 654, in format
[Fri May 30 00:01:24 2014] [error]     return fmt.format(record)
[Fri May 30 00:01:24 2014] [error] File "/usr/lib64/python2.6/logging/__init__.py", line 439, in format
[Fri May 30 00:01:24 2014] [error]     s = self._fmt % record.__dict__
[Fri May 30 00:01:24 2014] [error] KeyError: 'request_info'

A note on versions/install:
following the review board install instructions: http://www.reviewboard.org/docs/manual/dev/admin/installation/linux/
Python: it says 2.5 or newer is acceptable , so I'm fine on that front.
CentOS: it supports it, but requires the EPEL package repository, which I have

However, I was not the one who installed RB, so I can't confirm that the install procedure was exactly followed.

Do you have any suggestions about what I may have mis-configured to cause this problem?

Thanks for your help,
Alex


On Tuesday, April 15, 2014 3:31:12 PM UTC-6, Christian Hammond wrote:
You must always use the version of Djblets that Review Board requires, or you'll hit problems.

This particular error shouldn't happen if you have the proper versions of both. If it's happening on a modern 1.7.x release still, I'd like to know about it. Note that removing the request_info may result in other issues.

Christian

--
Christian Hammond - chi...@chipx86.com

Review Board - http://www.reviewboard.org
Beanbag, Inc. - http://www.beanbaginc.com


On Tue, Apr 15, 2014 at 1:25 PM, <schm...@gmail.com> wrote:
Following up on this old thread since it was the only search result I found for strange errors we noticed in our Apache error.log after an upgrade to 1.7.16:

[Mon Apr 14 20:44:43 2014] [error] File "/usr/lib/python2.7/logging/__init__.py", line 467, in format
[Mon Apr 14 20:44:43 2014] [error]     s = self._fmt % record.__dict__
[Mon Apr 14 20:44:43 2014] [error] KeyError: 'request_info'
[Mon Apr 14 20:44:43 2014] [error] Logged from file __init__.py, line 84
I tracked this error down to the following log formatting config in the Djblets (version 0.7.29) module, in djblets/log/__init__.py:
DEFAULT_LINE_FORMAT = \

    "%(asctime)s - %(levelname)s - %(request_info)s - %(message)s"
Once I got rid of that %(request_info)s portion, the errors went away. Not sure if our config is to blame here -- we upgraded ReviewBoard without upgrading Djblets, and had to fix a symlink to Djblets manually at some point during the upgrade.

--
Get the Review Board Power Pack at http://www.reviewboard.org/powerpack/
---
Sign up for Review Board hosting at RBCommons: https://rbcommons.com/
---

Happy user? Let us know at http://www.reviewboard.org/users/
---
You received this message because you are subscribed to the Google Groups "reviewboard" group. To unsubscribe from this group and stop receiving emails from it, send an email to reviewboard...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.




--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard-issues+unsubscr...@googlegroups.com.
To post to this group, send email to reviewboard-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.

Reply via email to