importadded: Set added field before moving files
- Dominant language
- Python
- Stars
- 15.7k
- Forks
- 2.1k
- Avg merge
- 4d 21h
- Merged PRs (30d)
- 31
Description
I have a collection that I organize according to year of purchase (or acquisition) and I want to import it to beets with the same hierarchy.
So I activated the importadded plugins and have the following path :
```
default: $format/%left{$mtime,4}/$albumartist - $album%aunique{}/$track $title
```
or (which should be better) :
```
default: $format/%left{$added,4}/$albumartist - $album%aunique{}/$track $title
```
so that I get (for an album that has mtime 2011) : MP3/2011/artist - album/01 title.mp3
This does not seem to work, the files are put in MP3/1970/artist...
After importing one test album I try out ```
$ beet ls -f '%left{$mtime,4} %left{$added,4} $artist $title'
2011 2011 artist title
[snip]
```
which seems correct. I guess the added or mtime is filled into the database later in the process, or is this another bug ?
```
Contributor guide
Research direction
Start by tracing the importadded plugin and the import/move sequence reproduced with the shown beet import and beet ls commands. Confirm whether $added and $mtime are set before the path template is evaluated; done means the imported album is placed under MP3/2011 and beet ls reports 2011 for both fields.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100