microsoft / microsoft/Qcodes

Custom dataset location impossible?

Open
#896 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

new dataset
Dominant language
Python
Stars
459
Forks
359
Avg merge
3d 6h
Merged PRs (30d)
73

Description

### Steps to reproduce
```
import qcodes as qc
from qcodes.dataset.sqlite_base import init_db, connect

dataDB = 'C:/Users/Junkie/Documents/Programming/Python/QCoDeS/datapool/experiments.db';
qc.config["core"]["db_location"] = dataDB;

conn = connect(dataDB, debug=True)
init_db(conn)

from qcodes.dataset.experiment_container import Experiment
from qcodes.dataset.measurements import Measurement
from qcodes import new_data_set, new_experiment
```

### Expected behaviour
Use the database under the path dataDB for the storage of measurements..

### Actual behaviour
It uses the database created under the current working directory instead.

### System
**operating system**

**qcodes branch**
feature/dataset

**qcodes commit**

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with qcodes.dataset.sqlite_base.init_db and connect, then trace how new_data_set and new_experiment select the database after qc.config["core"]["db_location"] is set. Reproduce the example using the supplied dataDB path and verify that measurements are stored there rather than in the current working directory.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
databases
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.