Skip to content

pastastore renames my oseries #246

Description

@OnnoEbbens

When I add an oseries to the pastastore with the name '1_101_1' and then obtain it later the name attribute of my series has changed to the integer 11011. This only happens when using the PasConnector, not with the DictConnector. The full code to reproduce my error is below:

import shutil
import pandas as pd
import pastastore as pst
import numpy as np
from pathlib import Path
pascondir = Path('testtest')
# remove old pstore
if pascondir.exists():
    shutil.rmtree(pascondir)
else:
    pascondir.mkdir()
pstore = pst.PastaStore(connector=pst.PasConnector(name="pastastore",path=pascondir))
s = pd.Series(index=pd.date_range('2000-1-1','2000-1-5'),
              data=np.random.randint(0,10,5).astype(float),
              name='1_101_1')
print(s.name)
pstore.add_oseries(s, '1_101_1')
s = pstore.get_oseries('1_101_1')
print(s.name)

This is probably due to some parsing when reading the file from the disk. It does lead to some nasty errors though.

Pastastore version : 1.13.0

Python version : 3.13.13
Pandas version : 2.3.3
Matplotlib version : 3.11.1
Pastas version : 1.14.0
PyYAML version : 6.0.3

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions