INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Problem with Rename, Move and Copy Files  (Read 1903 times)

FKatz

  • Recent member
  • *
  • Posts: 35
Problem with Rename, Move and Copy Files
« on: June 16, 2021, 12:23:35 pm »

I am having a problem when I rename, move and copy files.
I have files that I have ripped in a directory N:\Music-New
Once I have decided which ones I want to keep I transfer them to a directory E:\Music-New
I have base path E:\Music-New
Rule : [Artist]\[Album]
Filename rule: [Artist] - [Name] - [Album] - [Track #]

I don't know when it started but it must have been fairly recently but when I rename  and move there are two spaces added before the period separating the filename and extension so if I have
N:\Music-New\Dubliners, The - Farewell To Ireland - 50 Years - 05.flac

When I move it to the E:\Music-New directory, I get

E:\Music-New\Dubliners, The - Farewell To Ireland - 50 Years - 05  .flac

Two spaces have been added after the track number

This didn't used to happen. What's going on and how can I prevent this happening?

Thanks

Frank



Logged

JimH

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 72531
  • Where did I put my teeth?
Re: Problem with Rename, Move and Copy Files
« Reply #1 on: June 16, 2021, 12:39:36 pm »

Filename rule: [Artist] - [Name] - [Album] - [Track #]
Are there spaces at the end of that rule?

Is N: a network drive?  What is it?
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: Problem with Rename, Move and Copy Files
« Reply #2 on: June 16, 2021, 01:11:50 pm »

Next build of MC28:
Changed: Spaces are trimmed from the head and tail of the filename and directory rule in the rename tool.
Logged
Matt Ashland, JRiver Media Center

FKatz

  • Recent member
  • *
  • Posts: 35
Re: Problem with Rename, Move and Copy Files
« Reply #3 on: June 16, 2021, 01:42:36 pm »

N: is an external hard drive but I've had the same problem when transferring from an internal drive.

There are no added spaces in the file name. This problem only just started occurring, or should I say I only just noticed it, and I've been using JRiver for about 10 years. I certainly don't intend to pay for an upgrade to solve a problem which shouldn't exist.

Maybe I'm doing something wrong - you keep adding features with very little explanation of what the features do so maybe there is some setting in 27 that has changed from 26 that I am unaware of.

Someone please come up with a solution for this.

Thank you

Frank
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: Problem with Rename, Move and Copy Files
« Reply #4 on: June 16, 2021, 02:01:51 pm »

In the filename and directory rules, make sure you don't have spaces at the end.  That's what we'll trim in v28.
Logged
Matt Ashland, JRiver Media Center

FKatz

  • Recent member
  • *
  • Posts: 35
Re: Problem with Rename, Move and Copy Files
« Reply #5 on: June 16, 2021, 03:02:54 pm »

I don't have spaces at the end. What else can this problem be?
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: Problem with Rename, Move and Copy Files
« Reply #6 on: June 16, 2021, 03:06:09 pm »

Just use [Name].  Does that have a space?  If not, add more until you find the space.  Then let us know.  Thanks.
Logged
Matt Ashland, JRiver Media Center

JimH

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 72531
  • Where did I put my teeth?
Re: Problem with Rename, Move and Copy Files
« Reply #7 on: June 16, 2021, 03:12:17 pm »

N: is an external hard drive but I've had the same problem when transferring from an internal drive.

There are no added spaces in the file name. This problem only just started occurring, or should I say I only just noticed it, and I've been using JRiver for about 10 years. I certainly don't intend to pay for an upgrade to solve a problem which shouldn't exist.
Let's not be pointing any fingers until we find out what it is.  I've never seen this problem or heard of it, and MC27 is pretty stable, so what could be different? 

Has anything changed recently?

External drive N.  Please be specific.

And is E an internal drive?
Logged

FKatz

  • Recent member
  • *
  • Posts: 35
Re: Problem with Rename, Move and Copy Files
« Reply #8 on: June 16, 2021, 03:19:53 pm »

Since the first item in the file name is artist, I cut out all the other items
I put in [Artist] and end up with [Artist]  .flac
I also tried adding to the string and put [Bit Depth] after [Track #] and get [Bit Depth]  .flac
The program wants to add those two spaces whatever I do.
Interestingly, if I move to one directory and then move from that directory to another I would have though that I would have ended up with four spaces but I only end up with two.
Logged

FKatz

  • Recent member
  • *
  • Posts: 35
Re: Problem with Rename, Move and Copy Files
« Reply #9 on: June 16, 2021, 03:38:10 pm »

"External drive N.  Please be specific."
I'm not sure what you mean by be specific - N: is a Western Digital My Book 4TB external drive. I've been using this for years as a temporary home for my music files and done hundreds of transfers (maybe thousands) without this happening.

"And is E an internal drive?" E: is a partition on my computer's main hard drive - again, the same drive I have used for several years.

The only thing that I can think of that has changed is that there has been a new update to Windows 10 and I know that sometimes things get quirky when that happens. The last time I did a transfer was a couple of weeks ago before the Windows 10 update. I don't know if it occurred then or not since I wasn't paying attention.

The reason I noticed this is that I did a purge of duplicates from my main music directory E:\Music and decided to reorganize to make sure that all the files were where they should be. I expected that when I did the replace and rename procedure it would find a few files that I may have relocated by other means but was surprised that it seemed to want to perform the procedure on all the files (about 85,000) - once it completed this, I looked more closely which is when I realized that those 85,000 files had two spaces after the track number. I then used a file manager to remove all those extra spaces but I really don't want to have to do that on a regular basis so I'm hoping that someone can come up with a resolution to this.
Logged

JimH

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 72531
  • Where did I put my teeth?
Re: Problem with Rename, Move and Copy Files
« Reply #10 on: June 16, 2021, 04:09:49 pm »

Google windows flac problem.  There was one recently.
Logged

JimH

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 72531
  • Where did I put my teeth?
Re: Problem with Rename, Move and Copy Files
« Reply #12 on: June 16, 2021, 04:20:04 pm »

Is drive N connected via USB?  USB 3.0?
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: Problem with Rename, Move and Copy Files
« Reply #13 on: June 16, 2021, 05:40:17 pm »

You could send a library backup to matt at jriver and I could restore the files and settings and try.  It might turn something up?
Logged
Matt Ashland, JRiver Media Center

FKatz

  • Recent member
  • *
  • Posts: 35
Re: Problem with Rename, Move and Copy Files
« Reply #14 on: June 16, 2021, 06:19:41 pm »

It's not just flac files that this occurs with - it happens with any kind of audio file I have.

My N: drive is connected via USB - I have a bunch of USB ports so I need to check to see if it's 2 or 3

I'll look into getting a copy of the backup to Matt.

It sounds like nothing like this has happened before and I'm relieved, in a way, that I'm not the only one stumped.

Thanks for all the suggestions and I'm open to any other ones so I can get back to doing the rename, move and copy without all these hassles.
Logged

markf2748

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 849
Re: Problem with Rename, Move and Copy Files
« Reply #15 on: June 17, 2021, 11:07:18 am »

Interesting.  I keep copies of all my music files on multiple external USB drives, some on my MC server and others on wi-fi networked computers.
I regularly do file compares (Beyond Compare) for manual backup.  In a compare yesterday, I noticed about half a dozen flac files (out of thousands) that had extra spaces in the file name (on server, main MC external drive) just as described by OP.  I removed the spaces and files were binary identical as expected. 

Lately I've been doing a lot of messing around with views in MC, but  I have not used rename, move and copy files recently.

I've never seen this before.  The files with extra spaces seemed random, not necessarily played recently, and were scattered among different albums.

I just noticed a windows optional quality update (KB5004476) sitting ready for install.  In the past, I have encountered all sorts of disruptions to MC when there is a windows update waiting to be installed.  May be related, may be not.

MC 27.0.85 (64-bit)
Win 10 Pro 64-bit, Ver. 21H1, OS Build 19043.1052
Windows Feature Experience Pack 120.2212.2020.0
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: Problem with Rename, Move and Copy Files
« Reply #16 on: June 17, 2021, 01:17:12 pm »

There was a newline at the end of the rule.  That's why it put a space there.  I'll think about trimming that as well for v28.
Logged
Matt Ashland, JRiver Media Center

lepa

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2036
Re: Problem with Rename, Move and Copy Files
« Reply #17 on: June 19, 2021, 05:29:22 pm »

Just to note that this trimming of those badly implemented expressions rule will break rename rules if one has used "/"s to format rules to multiline for better readibility of complex rules. Just realized that my files I have renamed with builds .24-25 have now unintended filenames...

You should advertise this change loudly so that people will realize that you cannot use any kind formation of expression in RMC tool anymore

After removing "/" to ignore line feeds and getting expression to work

I now have to maintain this:
IfElse(IsEqual([Media Sub Type],Audiobook),If(IsEmpty([Track #],1),[Name],If(IsEqual([Disc #],Unknown Disc #),[Track #] - [Name],PadNumber([Disc #],2)#[Track #] - [Name])),IsEqual([Media Type],Audio),If(IsEmpty([Track #],1),[Name],If(IsEqual([Disc #],Unknown Disc #),[Track #] - [Name],PadNumber([Disc #],2)#[Track #] - [Name])),IsEqual([Album Art],1),[Name],IsEqual([Media Sub Type],TV Show),[Series] - SPadNumber([Season],2)EIf(Compare(ListCount([Episode],-),>,1),PadNumber(ListItem([Episode],0,-),2)-PadNumber(ListItem([Episode],1,-),2),PadNumber([Episode],2)) - [Name],IsEqual([Media Sub Type],Movie),[Name]If(!IsEmpty([Version,0]),/[[Version]/],) /([Date (Year)]/)If(IsEqual([Definition],4K),/[4K/],),IsEqual([Media Sub Type],Music Video),If(IsEmpty([Date (Year)],1),[Artist] - [Name],[Artist] - [Name] /([Date (Year)]/)),IsEqual([Media Sub Type],Other),[Episode],IsEqual([Media Sub Type],Music),[Name] /([Date (Year)]/),IsEqual([Media Sub Type],Concert),[Name] /([Date (Year)]/),IsEqual([Media Sub Type],Educational),If(!IsEmpty([Series],1),[Series] - SPadNumber([Season],2)EPadNumber([Episode],2) - [Name],[Name] /([Date (year)]/)),IsEqual([Media Sub Type],Extras),[Episode],1,[Name])

Instead of this:
Code: [Select]
IfElse(
    IsEqual([Media Sub Type],Audiobook),
        If(IsEmpty([Track #],1),[Name], If(IsEqual([Disc #],Unknown Disc #),[Track #] - [Name],PadNumber([Disc #],2)#[Track #] - [Name])),
    IsEqual([Media Type],Audio),If(IsEmpty([Track #],1),[Name],
        If(IsEqual([Disc #],Unknown Disc #),[Track #] - [Name],PadNumber([Disc #],2)#[Track #] - [Name])),
    IsEqual([Album Art],1),
        [Name],
    IsEqual([Media Sub Type],TV Show),
        [Series] - SPadNumber([Season],2)EIf(Compare(ListCount([Episode],-),>,1),PadNumber(ListItem([Episode],0,-),2)-PadNumber(ListItem([Episode],1,-),2),PadNumber([Episode],2)) - [Name],
    IsEqual([Media Sub Type],Movie),
        [Name]If(!IsEmpty([Version,0]),/ /[[Version]/],) /([Date (Year)]/)If(IsEqual([Definition],4K),/ /[4K/],),
    IsEqual([Media Sub Type],Music Video),
        If(IsEmpty([Date (Year)],1),[Artist] - [Name],[Artist] - [Name] /([Date (Year)]/)),
    IsEqual([Media Sub Type],Other),
        [Episode],
    IsEqual([Media Sub Type],Music),
        [Name] /([Date (Year)]/),
    IsEqual([Media Sub Type],Concert),
        [Name] /([Date (Year)]/),
    IsEqual([Media Sub Type],Educational),
        If(!IsEmpty([Series],1),[Series] - SPadNumber([Season],2)EPadNumber([Episode],2) - [Name],[Name] /([Date (year)]/)),
    IsEqual([Media Sub Type],
        Extras),[Episode],
    1,[Name]
)
Logged

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9162
Re: Problem with Rename, Move and Copy Files
« Reply #18 on: June 19, 2021, 11:38:08 pm »

I too was really quite nervous about this change, but for whatever reason, mine are still working as expected. Perhaps it's because I haven't actually changed anything whilst this 'fix' was put in place... With these, I never need to concern myself with what files I'm asking MC to move. So long as the tags are correct, I just open the tool, give the target previews a quick check and press OK. Having to maintain these as a single string was not something I would find either enjoyable or user-friendly....

lepa

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2036
Re: Problem with Rename, Move and Copy Files
« Reply #19 on: June 20, 2021, 02:51:15 am »

It works as you don't have used "/" to skip linefeed but your linefeeds should be gone at least mine are
Logged

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9162
Re: Problem with Rename, Move and Copy Files
« Reply #20 on: June 20, 2021, 02:58:02 am »

Not gone, they're still there when I right click in the field and choose expression  editor, that's how it presents, with new lines intact.

lepa

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2036
Re: Problem with Rename, Move and Copy Files
« Reply #21 on: June 20, 2021, 03:04:06 am »

Then there is some fortunate bug in the line feed trim and it isn't trimming your lines... ;D
Copied expression from zelda to MC and opened expression editor again.

E: maybe it will update (remove lines) only when you update your rule..



Logged

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9162
Re: Problem with Rename, Move and Copy Files
« Reply #22 on: June 20, 2021, 03:18:50 am »

Tis what I wondered too.

Can't help the feeling that a sledge hammer has been used to crack a nut here. If the trailing line feed is what caused the original problem, why not just trim any trailing feeds rather than not permit any at all?

Complex expressions without new lines are a nightmare to interpret.

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: Problem with Rename, Move and Copy Files
« Reply #23 on: June 20, 2021, 06:36:18 am »

I'll bring newlines back and just do a replacement in the output.  Thanks for testing.
Logged
Matt Ashland, JRiver Media Center

lepa

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2036
Re: Problem with Rename, Move and Copy Files
« Reply #24 on: June 20, 2021, 08:31:00 am »

That's a relief. Thank you for listening,
Logged
Pages: [1]   Go Up