feder-observatory / stellarphot

Stellar aperture photometry
https://stellarphot.readthedocs.io
BSD 3-Clause "New" or "Revised" License
4 stars 12 forks source link

`console_log` in photometry functions does not actually control console logging #271

Closed mwcraig closed 5 months ago

mwcraig commented 9 months ago

The current code only uses console_log to control whether there is loggin to console in addition to file logging. If there is no file logging than console logging is always done.

I think it should be possible to turn off console logging altogether, but the issue isn't critical to fix before 2.0.

mwcraig commented 9 months ago

See this link for the relevant code in multi-image photometry.

JuanCab commented 5 months ago

The logic is supposed to be that if no file logging is requested, there should be no console logging (not that it is always done). When logging is turned on, it defaults to file logging with console logging as an option if the person want to also see the output on screen.

You state that "If there is no file logging than console logging is always done." Can you clarify this with an example (I know you filed this a few months ago, but hoping you might remember when you stumbled across this)?

JuanCab commented 5 months ago

Nevermind, I think I see what you are getting at. The problem is logging is ALWAYS activated and once activated, it has to send the output somewhere. Let me dig into the code a bit.