View Issue Details

IDProjectCategoryView StatusLast Update
0004810MMW v4Properties/Auto-Toolspublic2008-11-28 17:52
Reporterpeke Assigned To 
PrioritynoneSeveritytrivialReproducibilityalways
Status resolvedResolutionno change required 
Summary0004810: Disk#/Track# do not support Negative Values
DescriptionIn case of Auto-Tag from filename where path is
1. C:\Music\Alternative\Alice in Chains\Dirt (Special Limited Edition)\CD1\[Track# Title]
1. C:\Music\Alternative\Alice in Chains\Dirt (Special Limited Edition)\Vol2\[Track# Title]

There is no way to use single <Disk#> mask:
1. CD<Disc#>\<Track#:2><Title>
2. Vol<Disc#>\<Track#:2><Title>

If <Disk#> Support negative value <Disk#:-1> mask will be filled correctly in both cases

1&2. <Disc#:-1>\<Track#:2><Title>

Updated: Due the fact that Disk# and Track# support strings it is resonable to support functions that work with strings.
Additional InformationRelated Forum Topic
http://www.mediamonkey.com/forum/viewtopic.php?f=1&t=32014

and
http://www.mediamonkey.com/support/staff/index.php?_m=tickets&_a=viewticket&ticketid=1783 (point d)

http://www.mediamonkey.com/support/staff/index.php?_m=tickets&_a=viewticket&ticketid=3021
TagsNo tags attached.
Fixed in build

Activities

peke

2008-08-16 01:04

developer   ~0014454

Assigning to Rusty for priority determination and possible assignment to Ludek as he had done mask fixes recently.

peke

2008-09-06 01:13

developer   ~0014536

Last edited: 2008-09-06 01:14

a) As noted in Rustys email here is an Auto-Tag from Filename example of current behavior and desired behavior on two sample tracks using their full path/filenames.

Example files:
1. E:\temp\Theo Kamann CD 10 - 17\Theo Kamann - Kamannmix Vol.16\Theo Kamann Kamannmix Volume 16 FULL CD.mp3
2. E:\temp\Theo Kamann CD 18 - 22\Theo Kamann - Kamannmix CD21\Theo Kamann Kamannmix 21 FULL CD.mp3

Current Behavior:
<Artist> - <Album> <Track#>\<title> will give results of
1.
Title: Theo Kamann Kamannmix 16 FULL CD
Arist: Theo Kamann
Album: Kamannmix
Track#: Vol.16

2.
Title: Theo Kamann Kamannmix 21 FULL CD
Arist: Theo Kamann
Album: Kamannmix
Track#: CD21

or <Artist> - <Album> <Track#:2>\<title>
1.
Title: Theo Kamann Kamannmix 16 FULL CD
Arist: Theo Kamann
Album: Kamannmix
Track#: Vo

2.
Title: Theo Kamann Kamannmix 21 FULL CD
Arist: Theo Kamann
Album: Kamannmix
Track#: CD

Both masks do not work and return invalid values which needs additional masks and settings
1. <Artist> - <Album> Vol.<Track#:2>\<title>
2. <Artist> - <Album> CD<Track#:2>\<title>
which results that for user would be easier to edit Properties for each track than use Auto-Tag.

Desired behavior that will handle both issues correctly in single mask:
<Artist> - <Album> <Track#:-2>\<title>
1.
Title: Theo Kamann Kamannmix 16 FULL CD
Arist: Theo Kamann
Album: Kamannmix
Track#: 16

2.
Title: Theo Kamann Kamannmix 21 FULL CD
Arist: Theo Kamann
Album: Kamannmix
Track#: 21

Explanation:
in both current and desired behaviors "Vol.16" and "CD21" is used for <Track#> Field but if <Track#:-2> is supported Track# would be filled with 2 chars right->Left and would exclude need for additional masks.

Note: we had big issues regarding false Track# after introducing String support for Track#

b) If Track# is replaced with Disk# it does not work at all (eg. Auto-Tag do not recognize <Disk#> mask)

c) Currently MediaMonkey do not have ability to strip leading zero padding from Numeric Tag fields (Track and Disk # are basically numeric fields even we support String input) and implementing mask feature with parameter ":0" would solve that and would give user additional customization and choice.

d) Even this is not directly to this bug introducing parameter ":0" in all String Mask would solve one of basic issues of Stripping leading/ending Space padded tags (eg. " Queen " -> "Queen")

e) Even this is not directly to this bug but it would be wise that all String Tag features should be able to support different Negative value behavior instead of only positive values. (<Title:-5>, <Artist:-5>,...)

rusty

2008-09-08 17:36

administrator   ~0014545

a)/e) So are you suggesting that we get rid of this existing functionality?

from the online help re. use of <field:-n>:
Same as above except that if n > the number of characters in the field, then the resultant path is padded with spaces or 0's (depending on whether the field is text or numeric) from the opposite side.

b) Auto-tag _does_ support the Disk# mask!

c) this could work though I wish it was more intuitive.

peke

2008-11-26 23:18

developer   ~0015165

Last edited: 2008-11-27 01:55

a)/e) I have read help more carefully and as you refer to <field:-n> I'm not sure that any of scripts uses it. Actually I do not know any real usage due the fact that Numeric Fields Are Padded left with 0 and text with Space on right

<Field:n> from help:
If n > the number of characters in the field, then the resultant path is padded with spaces or 0's depending on whether the field is text or numeric.

<Field:-n> I understand like in these examples

Text:
[String used in mask] -> [Auto Tag From Filename] = [result], [Auto-Organize] = Result]
"Pavle" -> <field:2> = "Pa", <field:10> = "Pavle_____"
so according to that negative should act like this as an opposite to positive value
"Pavle" -> <field:-n> = "le", <field:-10> = "_____Pavle"

Numeric are more complicated and can differ from each Numeric field like it was noted in help with example for year but it is handled internally according to Format rules of each type:
[Numeric value to read] -> [Auto-Tag from filename positive] = [Result], [Auto-Tag from filename Negative] = [Result]
no04 -> <Track#:2> = "no", <Track#:-2> = "04"

[value in Track] -> [Auto-Organize positive] = [Result], [Auto-Organize Negative] = [Result]
"4" -> <Track#:4> = "0004", <Track#:-4> = "4000"
"04" -> <Track#:4> = "0004", <Track#:-4> = "0400"
This Organize Mask was not possible due the fact that Windows Do not Allow "/" in Filename, but if we add Negative Value it would be easily possible.
"04/20" -> "<Track#:2> of <Track#:-2>" = "04 of 20"

So not exactly to remove but expand its functionality a little.

b) I uploaded Screenshot to FTP under Bug Number it looks that Auto-Tag misses recognizing <Disk#>

c)/d) I know that, but here are examples Why I thought it would be logic to use it like that for Auto-Organize as for Auto-Tag it is ignored due the Complete Mask property (Except in Case Of numeric fields and Zero Padding, example is below):
Auto-Organize:
" Pavle " -> <Title:0> = "Pavle"
"Pavle " -> <Title:0> = "Pavle"
" Pavle" -> <Title:0> = "Pavle"
"04" -> <Track#:0> = "4"

Auto-Tag exceptions:
"004. Pavle" -> "<Track#:0>. <Title>" = (Track# = "4") and (Title = "Pavle")

It should be clear now.

rusty

2008-11-27 18:43

administrator   ~0015200

Jiri, can you review this?

jiri

2008-11-28 10:37

administrator   ~0015226

There are currently better ways of handling strings in masks, e.g. function $Right() will achieve the functionality as needed and in more understandable manner.

peke

2008-11-28 15:56

developer   ~0015237

I'm not sure that I understand, can you elaborate.

Example Filename:
01Army of Me_Björk2004.mp3

Mask1 ??:
<Track#:2><Title>_<Artist>$Right(<Year:4>)

Mask2:
<Track#:2><Title>_<Artist><Year:-4>

jiri

2008-11-28 17:52

administrator   ~0015242

I missed that you mean Auto-tag from filename. However, still this seems to be unnecessary complex proposal that wouldn't be much used anyway. We can re-evalute in case it's really requested by more users.