Skip to content

Commit

Permalink
Merge pull request #63 from the-virtual-brain/VT-81
Browse files Browse the repository at this point in the history
VT-81: change location of xircuits log file for jsc lab
  • Loading branch information
915-Misan-Teodora authored Feb 13, 2025
2 parents ecd7e97 + c5bb9c9 commit aad0c98
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "tvb-ext-xircuits",
"version": "2.0.1-alpha.2",
"version": "2.0.1-alpha.3",
"description": "Jupyterlab extension for building TVB workflows in a visual and interactive manner",
"keywords": [
"jupyter",
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ name = "tvb-ext-xircuits"
readme = "README.md"
license = { file = "LICENSE" }
requires-python = ">=3.8"
version = "2.0.1a2"
version = "2.0.1a3"
classifiers = [
"Framework :: Jupyter",
"Framework :: Jupyter :: JupyterLab",
Expand Down
6 changes: 5 additions & 1 deletion tvbextxircuits/logger/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,11 @@ def __init__(self, config_file_name='logging.conf'):
"""
current_folder = os.path.dirname(inspect.getfile(self.__class__))
config_file_path = os.path.join(current_folder, config_file_name)
logging.config.fileConfig(config_file_path, disable_existing_loggers=False)

home_directory = os.path.expanduser('~')
log_file_path = os.path.join(home_directory, '.tvb_ext_xircuits.log')

logging.config.fileConfig(config_file_path, disable_existing_loggers=False, defaults={'logfilename': log_file_path})
self._loggers = weakref.WeakValueDictionary()

def build_logger(self, parent_module):
Expand Down
2 changes: 1 addition & 1 deletion tvbextxircuits/logger/logging.conf
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ args=(sys.stdout,)
class=handlers.TimedRotatingFileHandler
level=INFO
formatter=simpleFormatter
args=('.tvb_ext_xircuits.log', 'midnight', 1, 30, None, False, False)
args=(r'%(logfilename)s', 'midnight', 1, 30, None, False, False)

############################################
## Formatters ##
Expand Down

0 comments on commit aad0c98

Please sign in to comment.