Skip to content

Commit

Permalink
Update the log file:
Browse files Browse the repository at this point in the history
  • Loading branch information
akikuno committed Apr 24, 2024
1 parent 08f3c71 commit f179c26
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 11 deletions.
36 changes: 32 additions & 4 deletions docs/RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
## 🐛 Bug Fixes
## 🔧 Maintenance
## ⛔️ Deprecated
- XXX [Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx)
[Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx)
-->

<!-- 💡 ToDo
Expand All @@ -18,17 +18,45 @@
- Flaskではなく、streamlitでGUIを作る
-->

v0.4.5 (2024-04-24)
v0.4.6 (2024-04-24)

## 🐛 Bug Fixes
## 💥 Breaking

+ In version 0.4.4 of strand_bias_handler.remove_biased_clusters, there was an error in the continuation condition for removing biased clusters, which has now been corrected. The correct condition should be 'there are alleles with and without strand bias **and** the iteration count is less than or equal to 1000'. Instead, it was incorrectly set to 'there are alleles with and without strand bias **or** the iteration count is less than or equal to 1000'. [Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/b72b3855121d0da6ac80636089315ecc26464657)
+ Update the log file [Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx)
+ Add the version of DAJIN2 to the log file to track the version of the analysis.
+ Rename the log file to `DAJIN2_log_<current time>.txt` from `<current time>_DAJIN2.log` to enabling open the file in any text editor.

## 📝 Documentation

+ Enhance the descriptions in GitHub Issue templates to clarify their purpose. [Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/08f3c71bf9f8b755e718eea79dd4a2562aa59297)


## 🔧 Maintenance

+ Move `DAJIN2_VERSION` to `utils.config.py` from `main.py` to make it easier to recognize its location. [Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx)


<!-- TEMPLATE
## 📝 Documentation
## 🚀 New Features
## 🐛 Bug Fixes
## ⛔️ Deprecated
[Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx)
-->

-------------------------------------------------------------

# Past Releases

<details>
<summary> v0.4.5 (2024-04-24) </summary>

## 🐛 Bug Fixes

+ In version 0.4.4 of strand_bias_handler.remove_biased_clusters, there was an error in the continuation condition for removing biased clusters, which has now been corrected. The correct condition should be 'there are alleles with and without strand bias **and** the iteration count is less than or equal to 1000'. Instead, it was incorrectly set to 'there are alleles with and without strand bias **or** the iteration count is less than or equal to 1000'. [Commit Detail](/~https://github.com/akikuno/DAJIN2/commit/b72b3855121d0da6ac80636089315ecc26464657)
<details>


<details>
<summary> v0.4.4 (2024-04-23) </summary>

Expand Down
5 changes: 4 additions & 1 deletion src/DAJIN2/core/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

from pathlib import Path

from DAJIN2.utils import io, fastx_handler
from DAJIN2.utils import io, config, fastx_handler
from DAJIN2.core import classification, clustering, consensus, preprocess, report
from DAJIN2.core.preprocess.input_formatter import FormattedInputs

Expand All @@ -18,6 +18,9 @@


def execute_control(arguments: dict):

logger.info(f"\N{runner} Start running DAJIN2 version {config.DAJIN_VERSION}")

logger.info(f"{arguments['control']} is now processing...")

###########################################################
Expand Down
5 changes: 1 addition & 4 deletions src/DAJIN2/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@
from DAJIN2.utils import io, config, report_generator, input_validator, multiprocess


DAJIN_VERSION = "0.4.5"


def generate_report(name: str) -> None:
report_generator.report(name)
print(
Expand Down Expand Up @@ -165,7 +162,7 @@ def execute():
"-g", "--genome", type=str, default="", help="Reference genome ID (e.g hg38, mm39) [default: '']"
)
parser.add_argument("-t", "--threads", type=int, default=1, help="Number of threads [default: 1]")
parser.add_argument("-v", "--version", action="version", version=f"DAJIN2 version {DAJIN_VERSION}")
parser.add_argument("-v", "--version", action="version", version=f"DAJIN2 version {config.DAJIN_VERSION}")
parser.add_argument("-d", "--debug", action="store_true", help=argparse.SUPPRESS)

###############################################################################
Expand Down
4 changes: 2 additions & 2 deletions src/DAJIN2/utils/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

from sklearn.exceptions import ConvergenceWarning


DAJIN_VERSION = "0.4.6"
DAJIN_RESULTS_DIR = Path("DAJIN_Results")
TEMP_ROOT_DIR = Path(DAJIN_RESULTS_DIR, ".tempdir")

Expand All @@ -28,7 +28,7 @@ def emit(self, record):

def get_logfile() -> Path:
current_time = datetime.datetime.now().strftime("%Y%m%d_%H%M%S")
return Path(f"{current_time}_DAJIN2.log")
return Path(f"DAJIN2_log_{current_time}.txt")


def set_logging(path_logfile: Path) -> None:
Expand Down

0 comments on commit f179c26

Please sign in to comment.