Comments
-
JJ Guillemaud
Created an attachment (id=112) Examples of wrong covers got by Synergy 3.1.2
-
JJ Guillemaud
Created an attachment (id=113) Examples of wrong covers got by Synergy 3.1.2
-
JJ Guillemaud
Created an attachment (id=114) Examples of wrong covers got by Synergy 3.1.2
-
JJ Guillemaud
Created an attachment (id=115) Artist-Supertramp,Album-Live'88.jpg
-
JJ Guillemaud
Created an attachment (id=116) Artist-TheAlanParsonsProject,Album-Freudiana.jpg
-
JJ Guillemaud
Created an attachment (id=117) Artist-RoxyMusic,Album-Flesh&Blood.jpg
-
JJ Guillemaud
Created an attachment (id=118) Artist-RickieLeeJones,Album-RickieLeeJones.jpg
-
JJ Guillemaud
Created an attachment (id=119) Artist-Queen,Album-TheGame.jpg
-
JJ Guillemaud
Created an attachment (id=120) Artist-Queen,Album-Jazz.jpg
-
JJ Guillemaud
Created an attachment (id=121) Artist-PatBenatar,Album-Tropico.jpg
-
JJ Guillemaud
Created an attachment (id=122) Artist-PatBenatar,Album-SevenTheHardWay.jpg
-
JJ Guillemaud
Created an attachment (id=123) Artist-ThePretenders,Album-Pretenders.jpg
-
JJ Guillemaud
Created an attachment (id=124) Artist-PatBenatar,Album-LiveFromEarth.jpg
-
JJ Guillemaud
Created an attachment (id=125) Artist-MariahCarey,Album-MariahCarey.jpg
-
JJ Guillemaud
Created an attachment (id=126) Artist-LauraBranigan,Album-LauraBranigan.jpg
-
JJ Guillemaud
Created an attachment (id=127) Artist-LauraBranigan,Album-Branigan.jpg
-
Greg Hurrell
Thanks for attaching the example images, JJ.
First, to explain how it *should* work in the case of an album like Queen/Jazz: Synergy first asks iTunes if the art is embedded and if it is not asks Amazon with a search string like "Queen Jazz". It makes the assumption that the first result returned by Amazon is likely to be correct.
So there are a number of ways this can go wrong:
1. The first result might not be one you want -- perhaps the second or third result is actually a better match -- but Synergy has no way to know this so has to settle for the first one.
2. If your ID3 tags have inaccurate or little information then the wrong album might be returned.
So you should be able to go to Amazon and do a manual search for things strings like "Pat Benatar live from earth" in the "Music" section and see if Amazon returns the right result.
Some of the error examples you've provided could possibly be explained by Amazon returning similar but not-quite-right titles, but some of them are completely out of the park and I am not sure why that might be.
Can you do a little test to see if this is reproducible for one of those albums?
As an example:
1. Quit iTunes and Synergy 2. Delete a cover like "Artist-PatBenatar,Album-LiveFromEarth.jpg" 3. Launch iTunes and Synergy 4. Play a track from the Pat Benatar "Live from Earth" album and see if Synergy downloads the wrong track (be aware that the download may not appear immediately because Synergy maintains a queue of covers-to-be-searched-for and only fires them off one at a time after a delay required by Amazon Web Services).
This may just be some kind of temporary issue with Amazon returning the wrong cover. If it downloads the wrong cover again we'll have to dig a bit deeper.
-
JJ Guillemaud
(In reply to comment #17)
Can you do a little test to see if this is reproducible for one of those albums?
As an example:
1. Quit iTunes and Synergy 2. Delete a cover like "Artist-PatBenatar,Album-LiveFromEarth.jpg" 3. Launch iTunes and Synergy 4. Play a track from the Pat Benatar "Live from Earth" album and see if Synergy downloads the wrong track (be aware that the download may not appear immediately because Synergy maintains a queue of covers-to-be-searched-for and only fires them off one at a time after a delay required by Amazon Web Services).
This may just be some kind of temporary issue with Amazon returning the wrong cover. If it downloads the wrong cover again we'll have to dig a bit deeper.
I did just what you requested, except I used Artist-RoxyMusic,Album-Flesh&Blood.jpg which was even more outrageous (returns Battlestar Galactica Season One). The behavior after deleting the original file from the Album Covers folder, and letting Synergy reload a new one, was exactly the same, with the same Battlestar cover I attached previously. I then went to Amazon.com, used "Roxy Music Flesh" as search string in "Music" and I got correctly the right Roxy Music CDs. Also,all my iTunes songs are MP3 converted from CDs, for which I got the song titles and Album titles thru iTunes, and since iTunes never had a problem getting them (at least for those with the wrong cover), I suppose the ID tag for the Album was right; but may be Synergy does not use this ID tag when accessing Amazon ?
-
JJ Guillemaud
Set the wrong status by error. Thought "WONTFIX" meant fix does not work...
-
Greg Hurrell
Ok, so I've done some more testing. The URLs that Synergy uses to perform the Amazon searches look like this:
That's the example of "Pat Benatar", "Live From Earth". Note how the words are just mashed together, separated by a single space (which when encoded for the URL appears as "%20"), and tacked onto the end of the URL as the "KeywordSearch" parameter.
So you can actually run the same searches that Synergy runs and compare the results. For example, from the commandline, all on a single line:
Synergy will pick the top search result and prefer "ImageUrlLarge" if it is available. In this case Amazon returns:
http://images.amazon.com/images/P/B000008DDD.01.LZZZZZZZ.jpg
Which, as far as I can tell (seeing I don't have the album) is correct.
Likewise for "Roxy Music", "Flesh & Blood" the search URL is:
And the top search result seems to be correct:
http://images.amazon.com/images/P/B0000256VN.01.LZZZZZZZ.jpg
Note that that search URL actually has a minor bug: note how the "&" character, which has special meaning in URLs, is not escaped but is just passed through literally. I think I should probably filter out such characters. But despite the error, the search result still seems correct.
So the question now is, why is Synergy downloading the wrong thing for you? We can confirm that Synergy is sending the right query, and we can also check that Amazon is returning the right result; finally, we can check that the downloaded data is what we expect it to be (and that no upstream proxy is getting in the way).
You can use the tcpdump tool to monitor network traffic using a line like:
sudo tcpdump -A -s 32768 host xml.amazon.com
You may need to consult the tcpdump man page (man tcpdump) in order to get this working on your system, as the settings are highly network-dependent. Notes on the example line above:
- "sudo" makes the command run with root privileges; without this you'll probably get a "no suitable device found" error
- the "-A" switch tells tcpdump to print output in ASCII so you can see the actual contents of the packets
- "-s" raises the packet dump limit above the default of 68 bytes so that you can see all of the traffic; 1500 is probably enough if you are connecting via ethernet but I've shown a higher value of 32768 just in case your network uses an even larger size
- "host xml.amazon.com" indicates that all traffic to and from xml.amazon.com will be dumped
Now, Synergy maintains these searches in a queue and fires them off periodically. So the way to capture the output of exactly one query is to quit Synergy, prepare iTunes to play the track you want to test, and then start Synergy. Now start tcpdump and *then* switch to the track you want to test. In this way Synergy will fire off the query immediately because there is guaranteed to be nothing ahead of it in the queue.
The output from tcpdump should show both the query sent to Amazon, and the data returned. In this way we can confirm that Synergy is sending the right query, and Amazon is sending the right response.
-
Greg Hurrell
(In reply to comment #20)
Note that that search URL actually has a minor bug: note how the "&" character, which has special meaning in URLs, is not escaped but is just passed through literally. I think I should probably filter out such characters. But despite the error, the search result still seems correct.
I've just fixed the encoding issue (https://wincent.dev/a/about/wincent/weblog/svn-log/archives/2007/05/synergy_r356_1_item_changed.php).
-
JJ Guillemaud
Created an attachment (id=130) tcpdump log
-
JJ Guillemaud
(In reply to comment #22)
Created an attachment (id=130) [details] tcpdump log
I used tcpdump as required, and searched for Roxy Music Flesh & Blood. The tcpdump log is attached above
Hope this helps
-
Greg Hurrell
Thanks a lot for capturing the output, JJ. It is very informative... here we can see that Synergy is sending the right request string:
GET /onca/xml2?t=synerformacos-20&devt=D31GYSP62C9C55&type=lite&mode=music&page=1&f=xml&KeywordSearch=Flesh%20&%20Blood%20Roxy%20Music
It has the bug I mentioned earlier in comment #20 that the "&" between "Flesh" and "Blood" is not correctly escaped, but that shouldn't make any difference as the search string is still close enough to produce the right result. You can upgrade to 3.1.3b (now on the servers) which addresses that issue, if you want, but it shouldn't really make much of a difference.
Especially interesting in the output is the confirmation that Amazon is "Battlestar Galactica: Season One" as the top result, with the corresponding art:
http://ec1.images-amazon.com/images/I/61NCPTQFNVL.jpg
So I tested the same URL from here using curl, all of this should be on one line, although Bugzilla will most likely wrap it onto multiple lines:
And Amazon returns the wrong result! Just to rule out all possible causes of error, I substitute the "&" between "Flesh" and "Blood" with the encoded form, "%26" as shown below:
This is the way it should be escaped, and the way Synergy version 3.1.3b escapes it. Again Amazon returns the wrong result.
So at least in the case of that album, it looks like this is Amazon bug. I can go to their website, select "Music" from the pop-up, and enter "Flesh & Blood Roxy Music" as a search string, and it will give me the correct art. But providing a correct search URL to their XML interface gives the wrong art. And we've confirmed that Synergy is indeed supplying a correct search URL.
In a case like this where Amazon is returning the wrong art the only way to override it is to obtain the correct art manually and overwrite the wrong art using one of the following means:
1. Overwriting the downloaded file (the one with the wrong art in it)
2. Manually add the correct art to iTunes, then delete the wrongly downloaded file; the next time you play the track Synergy will pick up the correct art from iTunes
I do plan to develop a UI that users can use to make managing album art easier (things like overriding bad search results etc). For example, see feature request #102 ("Hot key to cycle through Amazon search results"); there may be others already in the database too.
We can look at the other albums on your list, but I suspect the results will be the same. So for now I am going to mark this as WORKSFORME.
Add a comment
Comments are now closed for this issue.