Hi,
I have serious problems getting along with custom export attributes. I just don't get how it works. I already searched the web, but basically the only helpful post I've found is this http://www.noodlesoft.com/forums/viewtopic.php?f=3&t=1587. I've used this as a tutorial.
Example workflow:
I want a file named 'test.txt' to be renamed in [date added][custom export attribute][name].txt:
Conditions:
1) Name is test
2) Kind is Text
3) Passes Apple Script (embedded script) -> Script should only return a custom attribute which is fixed to "02" for this example.
Action:
Rename with pattern: [date added][custom export attribute][name].txt


The problem is that returning the custom export attribute from Apple Script causes trouble. It seems that the return statement is wrong. I don't know if I'm doing it wrong or if this is a bug. The following error appears (also cf. the logfile at the end of this post):

My question: What do I have to do in order to return a custom attribute from an Apple Script and to use it in my actions. Can someone give me an example, please?
Any help is appreciated - thanks!
---
I'm using Hazel 3.3.4 (Build 1232) on Yosemite.
Logfile entry:
2015-02-21 18:57:56.259 hazelworker[1647] Processing folder testfolder
2015-02-21 18:57:58.561 hazelworker[1647] [Error] Error during rule evaluation: Received error while trying to evaluate rule rename txt-file on file test.txt
2015-02-21 18:57:58.561 hazelworker[1647] Error while matching rule rename txt-file against file /Users/homefolder/Desktop/testfolder/test.txt: Invalid AppleScript return value: <NSAppleEventDescriptor: { 'usrf':[ 'utxt'("hazelExportTokens"), { 'usrf':[ 'utxt'("qwertz"), 'utxt'("02") ] } ] }>.
2015-02-21 18:57:58.561 hazelworker[1647] ###main load address: 0x10118d000
2015-02-21 18:57:58.561 hazelworker[1647] ###Noodle load address: 0x1012a3000
2015-02-21 18:57:58.561 hazelworker[1647] ###CK load address: 0x101266000
2015-02-21 18:57:58.561 hazelworker[1647] (
0 CoreFoundation 0x00007fff8c7e366c __exceptionPreprocess + 172
1 libobjc.A.dylib 0x00007fff8f80b76e objc_exception_throw + 43
2 hazelworker 0x00000001011bd2a7 hazelworker + 197287
3 Foundation 0x00007fff8eafc16a -[NSPredicateOperator performOperationUsingObject:andObject:] + 285
4 Foundation 0x00007fff8eafb872 -[NSComparisonPredicate evaluateWithObject:substitutionVariables:] + 313
5 hazelworker 0x00000001011f3fb4 hazelworker + 421812
6 hazelworker 0x00000001011f40ac hazelworker + 422060
7 hazelworker 0x00000001011f2c99 hazelworker + 416921
8 hazelworker 0x00000001011fdc3f hazelworker + 461887
9 hazelworker 0x00000001011f1200 hazelworker + 410112
10 hazelworker 0x00000001011c55df hazelworker + 230879
11 hazelworker 0x00000001011945a6 hazelworker + 30118
12 hazelworker 0x0000000101195e12 hazelworker + 36370
13 hazelworker 0x0000000101197e42 hazelworker + 44610
14 libdyld.dylib 0x00007fff8db355c9 start + 1
)
2015-02-21 18:57:58.768 hazelworker[1647] Done processing folder testfolder