1
0
mirror of synced 2024-12-12 15:01:09 +01:00

Fix the subtle bug caused by using Vs as symbols for symbol definitions

This commit is contained in:
Stepland 2021-05-01 13:17:09 +02:00
parent dbac208fd2
commit 45b53eb686
9 changed files with 20 additions and 11 deletions

View File

@ -1,7 +1,12 @@
# v0.1.2
## Fixed
- jubeat analyser
- Fix decimal -> fraction conversion to correctly handle numbers with only 3 decimal places #1
- Remove Vs from the allowed extra symbols lists as it would clash with long note arrows
# v0.1.1
## Fixed
- Loading a #memo2 file that did not specify any offset (neither by `o=...`, `r=...` nor `[...]` commands) would trigger a TypeError, not anymore ! Offset now defaults to zero.
# v0.1.0
- Initial Release

View File

@ -83,9 +83,11 @@ DIFFICULTIES = {"BSC": 1, "ADV": 2, "EXT": 3}
# I put a FUCKTON of extra characters just in case some insane chart uses
# loads of unusual beat divisions
# The Vs are left out on purpose since they would be mistaken for long note
# arrows
DEFAULT_EXTRA_SYMBOLS = (
""
""
""
""
"あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわをん"
"アイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワヲン"
)

View File

@ -13,7 +13,6 @@ from typing import Callable, Dict, Iterator, List, Optional, Set, Tuple, Union,
from more_itertools import chunked, collapse, intersperse, mark_ends, windowed
from sortedcontainers import SortedKeyList
from jubeatools import __version__
from jubeatools.formats.filetypes import ChartFile, JubeatFile
from jubeatools.song import (
BeatsTime,
@ -25,6 +24,7 @@ from jubeatools.song import (
TapNote,
Timing,
)
from jubeatools.version import __version__
from ..command import dump_command
from ..dump_tools import (

View File

@ -13,7 +13,6 @@ from typing import Dict, Iterator, List, Optional, Set, Tuple, Union
from more_itertools import chunked, collapse, intersperse, mark_ends, windowed
from sortedcontainers import SortedKeyList
from jubeatools import __version__
from jubeatools.formats.filetypes import ChartFile, JubeatFile
from jubeatools.song import (
BeatsTime,
@ -26,6 +25,7 @@ from jubeatools.song import (
Timing,
)
from jubeatools.utils import lcm
from jubeatools.version import __version__
from ..command import dump_command
from ..dump_tools import (

View File

@ -13,7 +13,6 @@ from typing import Dict, Iterator, List, Optional, Set, Tuple, Union
from more_itertools import chunked, collapse, intersperse, mark_ends, windowed
from sortedcontainers import SortedKeyList
from jubeatools import __version__
from jubeatools.formats.filetypes import ChartFile, JubeatFile
from jubeatools.song import (
BeatsTime,
@ -28,6 +27,7 @@ from jubeatools.song import (
Timing,
)
from jubeatools.utils import lcm
from jubeatools.version import __version__
from ..command import dump_command
from ..dump_tools import (

View File

@ -12,7 +12,6 @@ from typing import Dict, Iterator, List, Mapping, Optional, Tuple
from more_itertools import collapse, intersperse, mark_ends, windowed
from sortedcontainers import SortedKeyList
from jubeatools import __version__
from jubeatools.formats.filetypes import ChartFile, JubeatFile
from jubeatools.song import (
BeatsTime,
@ -24,6 +23,7 @@ from jubeatools.song import (
TapNote,
Timing,
)
from jubeatools.version import __version__
from ..dump_tools import (
BEATS_TIME_TO_SYMBOL,

View File

@ -1,6 +1,7 @@
from jubeatools.song import TapNote, LongNote, NotePosition
from fractions import Fraction
from jubeatools.song import LongNote, NotePosition, TapNote
notes = {
TapNote(time=Fraction(0, 1), position=NotePosition(x=0, y=0)),
TapNote(time=Fraction(0, 1), position=NotePosition(x=0, y=1)),

View File

@ -3,8 +3,10 @@ from fractions import Fraction
from pathlib import Path
from typing import Set, Union
from hypothesis import given, example
from hypothesis import example, given
from jubeatools.formats.jubeat_analyser.memo.dump import _dump_memo_chart
from jubeatools.formats.jubeat_analyser.memo.load import MemoParser
from jubeatools.song import (
BeatsTime,
BPMEvent,
@ -18,8 +20,6 @@ from jubeatools.song import (
)
from jubeatools.testutils.strategies import NoteOption
from jubeatools.testutils.strategies import notes as notes_strat
from jubeatools.formats.jubeat_analyser.memo.dump import _dump_memo_chart
from jubeatools.formats.jubeat_analyser.memo.load import MemoParser
from . import example1

View File

@ -7,6 +7,7 @@ Most timing-related info is stored as beat fractions,
otherwise a decimal number of seconds is used
"""
from __future__ import annotations
from collections import UserList, namedtuple
from dataclasses import astuple, dataclass, field
from decimal import Decimal