Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
thinh-vu committed Aug 5, 2024
2 parents 4966e9f + 9e74dec commit 435a2bc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions vnstock3/core/utils/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ def get_logger(name):
handler = logging.StreamHandler()
formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s')
handler.setFormatter(formatter)
handler.setLevel(logging.DEBUG) # Set the level for the handler
logger.addHandler(handler)
logger.setLevel(logging.DEBUG) # You might want to make the level configurable
logger.propagate = False # Prevent log messages from being passed to the handlers of ancestor loggers
return logger

def advanced_logger(name,
Expand Down
2 changes: 1 addition & 1 deletion vnstock3/explorer/vci/financial.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def _get_ratio_dict(self, show_log:Optional[bool]=False, get_all:Optional[bool]=
df.columns = [camel_to_snake(col) for col in df.columns]
effective_get_all = get_all if get_all is not None else self.get_all
selected_columns = ['field_name', 'name', 'en__name', 'type', 'order', 'unit']
df['unit'] = df['unit'].map(_UNIT_MAPPING)
df['unit'] = df['unit'].map(_UNIT_MAP)
if effective_get_all is False:
df = df[selected_columns]
df.columns = [col.replace('__', '_') for col in df.columns]
Expand Down

0 comments on commit 435a2bc

Please sign in to comment.