You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by carlosduclos <gi...@git.apache.org> on 2017/03/17 12:56:10 UTC

[GitHub] couchdb-nano issue #10: Broken logging

GitHub user carlosduclos opened an issue:

    https://github.com/apache/couchdb-nano/issues/10

    Broken logging

    [Original issue](https://github.com/dscape/nano/issues/284).
    
    __jzaefferer__
    I'm trying to get nano to log all requests while running tests, which are supposed to stub all nano calls. The logging looks like it should do that by providing DEBUG=nano/logger as an env var. Yet it doesn't actually log anything. After some searching I found that lib/logger.js exports a function that returns the logEvent function which then returns a log function. Unfortunately all the log() calls, like this one, end up calling the logEvent function, ignoring the resulting function, causing nothing to be logged.
    
    I can't tell what the intention of that inner log() function is, that seems unnecessary and could be removed. Usually I'd send a PR, but considering #265 I'll hold off on that for now. Maybe an existing contributor (and CLA signee) can just apply the fix (or tell me what I'm doing wrong).

----

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---