Error I don't understand

Support for macOS users
Post Reply
Lily
Posts: 8
Joined: 19 May 2024, 08:05

Error I don't understand

Post by Lily »

I am trying to use different formats for renaming my files and at the time they were working, but now it isn't. I checked the log and am getting errors. Please help me understand what I did wrong.

Code: Select all

# /Users/teadek/.filebot/logs/error.log
May 18, 2024 2:02:24 AM net.filebot.DiskStore acquireDiskStore
WARNING: Initialize new disk cache: /Users/teadek/.filebot/cache/0
May 19, 2024 4:05:25 AM net.filebot.License lambda$verifyLicense$2
WARNING: Activate License [P61787773] on [Sun May 19 04:05:25 PDT 2024]
May 19, 2024 4:41:45 AM net.filebot.Parallelism lambda$async$2
WARNING: Binding "file": undefined
java.util.concurrent.ExecutionException: net.filebot.format.SuppressedThrowables: Expression yields empty value: Binding "file": undefined
	at net.filebot.Parallelism.lambda$async$1(Unknown Source)
	at net.filebot.Parallelism.lambda$async$2(Unknown Source)
Caused by: net.filebot.format.SuppressedThrowables: Expression yields empty value: Binding "file": undefined
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.ui.rename.ExpressionFormatter.format(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	... 2 more
Caused by: net.filebot.format.BindingException: Binding "file": undefined
	at net.filebot.format.MediaBindingBean.getMediaFile(Unknown Source)
	at net.filebot.format.MediaBindingBean.getMediaParentFolder(Unknown Source)
	at net.filebot.format.ExpressionBindings$MethodBinding.call(Unknown Source)
	at net.filebot.format.ExpressionBindings.get(Unknown Source)
	at net.filebot.format.ExpressionFileFormat$1.get(Unknown Source)
	at Script.run(Script:1)
	at net.filebot.format.ExpressionEngine.evaluateScriptlet(Unknown Source)
	... 7 more

May 19, 2024 4:41:45 AM net.filebot.Parallelism lambda$async$2
WARNING: Binding "file": undefined
java.util.concurrent.ExecutionException: net.filebot.format.SuppressedThrowables: Expression yields empty value: Binding "file": undefined
	at net.filebot.Parallelism.lambda$async$1(Unknown Source)
	at net.filebot.Parallelism.lambda$async$2(Unknown Source)
Caused by: net.filebot.format.SuppressedThrowables: Expression yields empty value: Binding "file": undefined
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.ui.rename.ExpressionFormatter.format(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	... 2 more
Caused by: net.filebot.format.BindingException: Binding "file": undefined
	at net.filebot.format.MediaBindingBean.getMediaFile(Unknown Source)
	at net.filebot.format.MediaBindingBean.getMediaParentFolder(Unknown Source)
	at net.filebot.format.ExpressionBindings$MethodBinding.call(Unknown Source)
	at net.filebot.format.ExpressionBindings.get(Unknown Source)
	at net.filebot.format.ExpressionFileFormat$1.get(Unknown Source)
	at Script.run(Script:1)
	at net.filebot.format.ExpressionEngine.evaluateScriptlet(Unknown Source)
	... 7 more

May 19, 2024 4:41:45 AM net.filebot.Parallelism lambda$async$2
WARNING: Binding "file": undefined
java.util.concurrent.ExecutionException: net.filebot.format.SuppressedThrowables: Expression yields empty value: Binding "file": undefined
	at net.filebot.Parallelism.lambda$async$1(Unknown Source)
	at net.filebot.Parallelism.lambda$async$2(Unknown Source)
Caused by: net.filebot.format.SuppressedThrowables: Expression yields empty value: Binding "file": undefined
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.ui.rename.ExpressionFormatter.format(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	... 2 more
Caused by: net.filebot.format.BindingException: Binding "file": undefined
	at net.filebot.format.MediaBindingBean.getMediaFile(Unknown Source)
	at net.filebot.format.MediaBindingBean.getMediaParentFolder(Unknown Source)
	at net.filebot.format.ExpressionBindings$MethodBinding.call(Unknown Source)
	at net.filebot.format.ExpressionBindings.get(Unknown Source)
	at net.filebot.format.ExpressionFileFormat$1.get(Unknown Source)
	at Script.run(Script:1)
	at net.filebot.format.ExpressionEngine.evaluateScriptlet(Unknown Source)
	... 7 more

May 19, 2024 5:02:32 AM net.filebot.Parallelism lambda$async$2
WARNING: Pattern not found: \d+: gesture_critiques_with_marshall_vandruff_premium
java.util.concurrent.ExecutionException: net.filebot.format.SuppressedThrowables: Expression yields empty value: Pattern not found: \d+: gesture_critiques_with_marshall_vandruff_premium
	at net.filebot.Parallelism.lambda$async$1(Unknown Source)
	at net.filebot.Parallelism.lambda$async$2(Unknown Source)
Caused by: net.filebot.format.SuppressedThrowables: Expression yields empty value: Pattern not found: \d+: gesture_critiques_with_marshall_vandruff_premium
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.format.ExpressionFormat.format(Unknown Source)
	at net.filebot.ui.rename.ExpressionFormatter.format(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	at net.filebot.ui.rename.FormattedFuture.doInBackground(Unknown Source)
	... 2 more
Caused by: net.filebot.InvalidInputException: Pattern not found: \d+: gesture_critiques_with_marshall_vandruff_premium
	at net.filebot.format.ExpressionFormatMethods.match(Unknown Source)
	at net.filebot.format.ExpressionFormatMethods.match(Unknown Source)
	at Script.run(Script:3)
	at net.filebot.format.ExpressionEngine.evaluateScriptlet(Unknown Source)
	... 7 more

May 19, 2024 5:17:11 PM net.filebot.ui.rename.PresetEditor lambda$new$12
WARNING: Syntax Error: Unexpected character: '#'
May 19, 2024 6:22:52 PM net.filebot.Main lambda$initializeLogging$20
WARNING: Uncaught Exception in AWT-EventQueue-0: Index 4 out of bounds for length 0
java.lang.IndexOutOfBoundsException: Index 4 out of bounds for length 0
	at net.filebot.ui.rename.RenameModel$FormattedFutureEventList.get(Unknown Source)
	at net.filebot.ui.rename.RenameModel$FormattedFutureEventList.get(Unknown Source)
	at net.filebot.ui.rename.RenameList$1.mouseDragged(Unknown Source)

Code: Select all

Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/01-Hi--Im-artist-Jay..mp4	{"@type":"SimpleFileInfo","path":"/Volumes/jasmine4400.synology.me/video/Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/01-Hi--Im-artist-Jay..mp4","length":9293649}
Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/02-What-do-you-learn-in-class.mp4	{"@type":"SimpleFileInfo","path":"/Volumes/jasmine4400.synology.me/video/Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/02-What-do-you-learn-in-class.mp4","length":5701305}
Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/03-What-to-bring--iPad-and-Procreate.mp4	{"@type":"SimpleFileInfo","path":"/Volumes/jasmine4400.synology.me/video/Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/03-What-to-bring--iPad-and-Procreate.mp4","length":4311058}
Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/05-Procreate-5.2-update-details.mp4	{"@type":"SimpleFileInfo","path":"/Volumes/jasmine4400.synology.me/video/Art/American anime style character illustration, from design to completion by Jay (Korean, Eng Spa sub)/Welcome-Let's learn step by step, character drawing/05-Procreate-5.2-update-details.mp4","length":909605}
These are the presets I created. I am not tech savvy so I wrote based on what I understood and gave me the best results.
AUTO EPISODE- To add episode number automatically

Code: Select all

{
	folder.dir.dir
}
/
{
	def n = folder.dir.name
	def s = folder.name.match(/\d+/)
	def e = i.pad(2)
	def t = fn
	
	"$n/Season $s/$n - S${s}E${e} - $t"
}
TEST- Something I can tweak a bit in regards to the title names and takes the episode number from the last number of the file name.

Code: Select all

{
	folder.dir.dir
}
/
{
	def n = folder.dir.name
	def s = folder.name.match(/\d+/)
	def e = fn.match(/(\d+)(?!.*\d)/).pad(2)
	def t = fn.after('-')
	
	"$n/Season $s/$n - S${s}E${e} - $t"
}
TUTORIALS-Based on the general solution provided.

Code: Select all

{
	folder.dir.dir
}
/
{
	def n = folder.dir.name.removeAll(/\[.+?\]/).removeAll(/\(.+?\)/)
	def s = folder.name.match(/\d+/)
	def e = fn.match(/\d+/)
	def t = fn.after(/\d+/)

	"$n/Season $s/$n - S${s}E${e} - $t"
}
This is the result given:
https://imgur.com/a/wPgDoSu
Lily
Posts: 8
Joined: 19 May 2024, 08:05

Re: Error I don't understand

Post by Lily »

Don't worry, I think the folder just needed a number attached to it.
User avatar
rednoah
The Source
Posts: 23924
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Error I don't understand

Post by rednoah »

Yep, the {...} block will yield no result if the code fails, e.g. due to match() not being able to find the given pattern. The Format Editor will give you a very clear status message in this case. See Learn how {expressions} work and useful Helper Functions for details.


:idea: You can do Double-Click <New Names item> ➔ Edit Format to open the Format Editor for the specific item at hand and see the status message.
:idea: Please read the FAQ and How to Request Help.
Post Reply