Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

expandRepeats don't work as expected

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

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

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
22/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
python
領域
data

調査の方向性

The bug is in expandRepeats() on a score parsed from MusicXML with converter.parse, so start from that method and how it expands repeat markers. The attached snippet is not runnable as posted, so first rebuild it with a small 10-measure stream that has a repeat over measures 5 to 10 and check whether measures are duplicated. Done means expanding that stream gives each measure the expected number of times, and the issue's expected output is confirmed. The thread has no maintainer answer for over 300 days, so expect little help.

索引モデルが issue の本文から書いたものです。

説明

music21 version

9.8.7

Problem summary

I have got a musicxml file with 10 measures one repetition from 5 to 10.
I parse my file with convert.parse and then expandRepeats
music21 repeat from measure repeat 5 to 10 correctly and then do another 1 to 10 - 5 to 10

Paste minimal code example here. Most issues can be reproduced with just a few elements.
Attach external files only after attempting to reproduce using a simple stream.
 score = converter.parse(filepath, format='musicxml')
    score = score.expandRepeats()
    measures = score.recurse().getElementsByClass('Measure')
    score.write("musicxml", fp="file.xml")

Expected vs. actual behavior

Expected : Not repeat one more time

主要言語
Python
スター
2.6k
フォーク
459
平均マージ
12時間 54分
マージ済み PR(30日)
45

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

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

cuthbertLab/music21 のほかの issue

cuthbertLab/music21 の issue をすべて見る

似ている issue

Python の issue をもっと見る

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

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