Generate Missing Track Dummy Files?

Is there a way on web source script or conversion action to automatically produce a 0 byte dummy file for missing tracks within a release?

I did search but not sure what keywords to use without bringing up a load of results

i.e. folder content for a 4 track release with one missing track.


After Web Source/Conversion:
1 - Artist - Track Title.mp3
2 - Artist - Track Title.mp3
3 - Artist - Track Title.missing (or any extension except mp3)
4 - Artist - Track Title.mp3

Kind of automatically identifying what tracks are missing.

Any pointers on this would be much appreciated :slight_smile:

maaaayyyybe, there could be some some way. it would not be a straight forward solution. but maybe i could achieve it with my discogs web script and a one or two extra actions.

tell me if you have interest! i will think about it.

Do you want "3 - Artist - Title.missing" or would "3 - Albumartist - unknown.missing" enough?

a friend of mine who hates duplicates in his collection but still wants to see the full list of files in an album inserts .lnk-files to indicate the missing file.
(as these are duplicates he manually links them to the real content file - this would obviously be impossible in a script)
But perhaps it is possible to create such a link file which then does not upset an editor or player.

Very much interest. That would be great. :smiley:

Whatever would be easier, ultimately the best way (in my noob minds eye) would be a blank mp3 template file with just tags that gets inserted into the missing track gap, then filename formatting could still be done the regular way.

(%discogs_catalog%) (%album%) $num(%track%,2) - %artist% - %title%

but then I suppose the formatting would force it to be .mp3 extension, but that would still be an acceptable possibility as you could just search for the missing tracks based on filesize and it would only be header + tags + cover art. And also the fact Im not sure how flexible the file handling is on the scripting side of things.

Sorry, was thinking as was typing so might not make much sense, I hope you get the idea.

TBH I would be happy with whatever progress you can make on this :wink: Whatever the final filename formatting will be good :wink:

Again, many thanks.

Although I do get annoyed with duplicates I prefer a 'tidy house' to extra space. But that still sounds like a manual creation, whereas I was hoping for a more automated way to achieve this. Not a bad idea though

ok, my idea is something like this:

Mmy discogs script can write the total track number in a tag field, and it can also wirte the whole tracklist or a release into a tag field.

Based on that, you have different way in mp3tag to compare the data:
You could make a export which writes only the track number or full tracknumber/artist/title (if tracklist is writen in a tag field) of the missing files in a txt file (and maybe even in a txt file with a mp3 ending). The problem is, that you can only export one file per folder. so you would need to put all files in extra folder first (would be easy with a action), or perform the export several time, each time creating a new file.

I will do some thinking.

Until than, the way I deal incomplete releases:
I just leave the lines blank at the web sources and remember the missing tracknumbers. Afterwards I perform the following action group:

  1. Action: Format Tag Field
    Field: ALBUM
    Formatstring: %album% [INCOMPLETE]

  2. Action: Format Tag Field
    Field: COMMENT
    Formatstring: INCOMPLETE: missing tracks:

After that, i manually write the missing tracknumbers at the end of the comment field.

Sorry, I can't get it working. All my tries ended in being able to create an extra file for every file present, but not for the missing ones.

Since some time I fill partly existing albums with 1-byte dummy mp3 files.
This makes it possible to tag track numbering and other data such as images or lyrics via Internet services. Thus, all files from an album are fully tagged.
When the missing music data will be available later in the course of time, then the music file can be completely tagged by copy and pasting the whole tag from the dummy file to the original file.

To create a 1-byte 3-byte dummy mp3 file in the current folder just type in at the command line prompt, for example:
ECHO.x>"01 My Dummy File.mp3"

It has become clear, that it is better for the usage with Mp3tag, to create a dummy file with a byte size of greater than zero.

See also:
Bessere Performance beim Hinzuf├╝gen umfangreicher Tags


Well, having had more thinking about it, I found a solution. As I thought, it involves more than one step, but when you have created all the action groups, it works with a few key shortcuts.

Step 1:
Get my web sources sript for discogs: /t/9226/1
When you are at step 6 of the "installation" described there, it is important that you change DISCOGS_TOTALTRACKS from "no" to "totaltracks" (or however you want to call it, but you must have that field written).

Step 2:
Tag your incomplete albums with my script. At the "adjust tag information" window in the web source process, move the < no association > lines to the missing tracks.

Step 3:
The first action group:

Action 1: Format Value
Formatstring: %track% - - - TRACK IS MISSING - - -.mp3\%_filename%

Action 2: Format Value
Formatstring: .\%_filename%

Action 3: Export
Export File Name: $if($geql(%totaltracks%,1),1 - - - TRACK IS MISSING - - -.mp3,$getenv(appdata)\Mp3tag\dummy file.txt)
Export File Code: $filename($if($geql(%totaltracks%,1),1 - - - TRACK IS MISSING - - -.mp3,$getenv(appdata)\Mp3tag\dummy file.txt),ansi)

Action 4: Export
Export File Name: $if($geql(%totaltracks%,2),2 - - - TRACK IS MISSING - - -.mp3,$getenv(appdata)\Mp3tag\dummy file.txt)
Export File Code: $filename($if($geql(%totaltracks%,2),2 - - - TRACK IS MISSING - - -.mp3,$getenv(appdata)\Mp3tag\dummy file.txt),ansi)

Action 5: Export
Export File Name: $if($geql(%totaltracks%,3),3 - - - TRACK IS MISSING - - -.mp3,$getenv(appdata)\Mp3tag\dummy file.txt)
Export File Code: $filename($if($geql(%totaltracks%,3),3 - - - TRACK IS MISSING - - -.mp3,$getenv(appdata)\Mp3tag\dummy file.txt),ansi)

Actions 6 - ???:
Repeat this export as many times as you think the maximal tracknumber of a release could be. I would reccomend about 50 or 60 times to be able to deal with 2CD releases. Only change number on the positions i marked in blue print. Change the number in such a way, that it counts from 1 to ???, each Export represents one tracknumber. The mte file for the the export only needs one line as showed above.

last Action: Format Value
Formatstring: %track% - - - TRACK IS MISSING - - -.mp3\%_filename%

After that action you get a error message from Mp3tag which says, that the "x - - - TRACK IS MISSING - - -.mp3" file could not be created for every track that is there. That is intentional and the idea my solution builds on. The creation is prevented by the existence of the folder with the same name.

$getenv(appdata) can only be used if you have Mp3tag v2.48a or newer. If you use a older version (as your profile says) and do not want to update, you have to replace this by the path to you application date folder (which is C:\Users<user name>\AppData\Roaming) at my Windos Vista. At this place a little dummy file.txt file gets written for every tracknumbe which is higher than TOTALTRACKS. Only one file is written and overwritten everytime you use this action group. So you don't have to care about deleting it.

Step 4:
The second action group:
Action: Format Value
Formatstring: .\

Now you have dummy mp3 files for every missing track. When you are happy without further artist and title information, you don't have to go through the last two steps. In this case, you might als like a different file ending at this point. If so, replace all instances of "mp3" in orange print above with "missing" (or whatever you like).

Step 5:
Press F5 to refresh the folder and see the new dummy mp3 files.
Use my web sources script again to tag the dummy mp3 file. (you don't have to search this time at discogs, choose the direct by ID or direct by URL script)

Step 6:
The third action group:

Action 1: Format Value
Formatstring: (%discogs_catalog%) (%album%) $num(%track%,2) - %artist% - %title%$if($eql($right(%_filename%,29), - - - TRACK IS MISSING - - -), - - - TRACK IS MISSING - - -,)

Action 2: Regular Expression
Regular Expression: (.+) - - - TRACK IS MISSING - - -.mp3
Replace Matches With: $1.missing

As you see I have take you formatstring here. You can change that part in purple print to whatever you like. The important part comes in the $if function afterwards.
And of course you could also leave away Action 3 of Step 6 if you want to see the dummy representators of the missing files in you media library. In this case I would recommend you a action wich puts a MISSING in capital letters after the trackname for not loosing the overview in your collection over what is there and what is missing.

As I have have already created the action groups to thest this, I attach them to this post. Put the mta file inside the Mp3tag/data/actions folder and the mte files inside of Mp3tag/export. I have made only six exports at the first action group for testing. You will have to copy and change the other yourself. (2.25 KB)