Refactor code repetition in the time module

オープン
#606 コメント 0 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

@cdc-mitzimorris がすでに取り組んでいます。

2025年12月1日 から。

評価

この issue はまだ評価されていません。

説明

This looks like it works!

I think there is some unnecessary repetition e.g. in get_observation_indices where I think it would be cleaner to have an int pass into a function rather than if freq == "mmwr_weekly" then that int is 5 etc.

However, maybe lets make that a small refactor issue.

Originally posted by @SamuelBrand1 in https://github.com/CDCgov/PyRenew/pull/600#pullrequestreview-3310477343

I think for sustainability it would be nice to go back through this and cut out repetition code.

主要言語
Python
スター
30
フォーク
11
平均マージ
5日 4時間
マージ済み PR(30日)
9

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

CDCgov/PyRenew のほかの issue

CDCgov/PyRenew の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。