Tagger Script- Some Commands not Applied Automatically, but will work Manually?

Tags: #<Tag:0x00007f839fb43ed8>

I’ve got a tagger script setup with the box is ticked, [:heavy_check_mark:] so it runs automatically. I should see six new lines. I only get 4.

The first two lines do not do anything when the album is loaded on the Right.

But if I run the same script manually…

…the the additional two will populate:

$noop(Retains original filename & pathname for backup)


So it appears to not be doing anything with the _Variables during loading. Is this due to exactly when that script is run and those not being set yet? Or should it be doing them?

This is due of file variables not available to the tagger script. The scripts are executed when data gets loaded from MusicBrainz and usually there are no files available at that point. I think there are some cases where the above might work, but I’m not entirely sure when this applies.

There have been some attempts to fix this in the past, but there was no satisfying solution. IHMO the way to handle this would actually be to allow the user when to run a script. E.g. at a minimum you might want to be able to run a script either on metadata load (current behavior) or when a file gets matched to a track.

With current Picard versions you have two options of fixing this:

  1. Apply the script manually after files are available
  2. Implement it in a plugin using a file_post_addition_to_track_processor