|Summary:||ASTERISK-16214: [patch] mistakes in the 1.4.19 core-sounds-en.txt file|
|Reporter:||Steve Murphy (murf)||Labels:|
|Date Opened:||2010-06-05 10:48:10||Date Closed:||2010-09-23 23:49:22|
|Environment:||Attachments:||( 0) check_sounds.c|
|Description:||1. missing entries (the sound file exists, but not recorded in the .txt file)|
a. dir-first: ... letters of your party's first name
b. digits/billion.wav: billion
2. non-existent entries (the sound file referenced isn't there!)
a. phonetic/niner (phonetic/9_p says "niner")
b. dollars (digits/dollars says "dollars")
And that's all for the obvious errors. I haven't listened to all 450 or so sounds to verify that the scripts are correct yet. If I do, and find a prob, I'll file a separate bug report.
|Comments:||By: Leif Madsen (lmadsen) 2010-06-09 09:51:29|
That's odd... that means our scripts are not working correctly because there is a chkcore and chkextra script which should be checking to make sure all sound files exist in the sounds*.txt files.
The scripts are now public in the repotools directory. Any chance you could review the scripts to determine why those files were missed?
By: Steve Murphy (murf) 2010-06-10 10:51:17
Yes, the chkcore script is pretty minimal. It only checks to make sure any .wav
file in the top level dir has an entry in the .txt file; it does not do the reverse check, that of making sure all files listed in the .txt file do indeed exist. That's why the dollars.wav and phonetic/niner weren't spotted.
The other two are also easy to explain. For the "dir-first" it found the
"dir-firstlast" entry instead, and was satisfied, and the phonetic/niner was missed because the script doesn't check the files in the subdirs like digits, phonetic, etc.
Both problems, I would think, would be easy to fix in the script; explicitly add the subdirs to the list for the for loop, and not get rid of the subdir in the base pattern match, and end the pattern match with a : to stop matching a partial file name.
Then you'd have to code up the reverse search; for each line in the .txt file,
grab the file name and find it, reporting files not found.
I've written my own checking program in C; It runs the above checks both ways and reports discrepancies. And, then it goes thru the files one at a time, listing them by number, name, and contents, then playing each one. It waits in between for commands to play, replay, list, jump, and quit. It will accept
multiple play commands on one line to expedite the process; you can play 4 or 10 in a row, and check them off.
This way, I can also verify that the scripts match the sound files. For instance, the script file says "conf-roll-callcomplete: Roll call complete.",
but it really says something else, and vm-intro says "vm-intro: Please leave your message after the tone. When done hang up or press the pound key. (simple tone sound plays)", but no simple tone ends the message.
I'd attach it to the bug here for general usage, but somehow I picture you guys wanting to just upgrade the script instead; it doesn't need to be compiled and would be less trouble. My program requires me to clean any blank lines and comments out of the the .txt file before running (to keep down any error messages.) and I know there's a range violation or two left in my code, but really, I don't care. It's sloppy but sufficient for me.
By: Leif Madsen (lmadsen) 2010-06-14 14:48:01
Well since I'm the one doing the sounds releases now, it might not be a bad idea to attach it here. Perhaps I can use a combination of both scripts. I don't know.
I'm not much of a programmer, so I'm not sure how to make all those changes. I might if I had some time to devote to it. I can't imagine anyone else having the time to look at this though.
By: Steve Murphy (murf) 2010-06-16 10:31:43
I've attached the program. I didn't do a makefile; I just compile it with
"gcc -o check_sounds check_sounds.c"
It's a little better than just doing "for i in *.wav; do play $i; done
By: Digium Subversion (svnbot) 2010-07-05 09:11:33
r725 | lmadsen | 2010-07-05 09:11:32 -0500 (Mon, 05 Jul 2010) | 13 lines
Add additional program to check sounds files.
This is an alternate application written in C by murf which will check the
sounds files to make sure they exist in the *-sounds-*.txt files and will
also perform the reverse by checking that the sounds files exist in the
file which lists them.
(closes issue ASTERISK-16214)
Reported by: murf
check_sounds.c uploaded by murf (license 722)
Tested by: lmadsen, murf