Earliest Release Date v4.4.0 (2016-02-19)

Download and get help for different MediaMonkey Addons.

Moderators: Peke, Gurus

Earliest Release Date v4.4.0 (2016-02-19)

Postby wxdude » Tue Jul 03, 2012 5:35 pm

Description:

This script is an update from the original earliest release date from discogs script written by yhsiugs. With his permission I have updated the script and started a new thread. Would like to thank Hagar and Cotto for their comments and testing in version 2.0, and to others for suggestions for the current version....
Would also like to thank crap_inhuman for his input into the PHP server side code

Download:

http://earliestrelease.com/ERDVersions/EarliestDate4.4.0.206.mmip

What's New:

Version 4.4.0.206 - February 19, 2016

-Add option to clear Discogs Keys on main UI
-Add option to switch API service on Main Page
-switch searches changed API on previously selected/playing song
-options greyed out when both services have been checked
-Minor UI Changes - don't hide choices just disabled
-Change rate limit for Discogs to 3/s
-Use only first artist if multi-artist
-Change Discogs API calls to HTTPS

Version 4.3.2.195 - August 14, 2014
- Changed Discogs Oauth date requirement to October 14, 2014
- Fix object required if oAuth process cancelled by user choice
- Fixed error in install.ini file

Version 4.3.1.194 - August 13, 2014
- removed from memory - built from wrong source

Version 4.3.0.193 - August 8, 2014
- Add support for oAuth and the search endpoint for Discogs
- Add checks for artist and track tags
- Changed installation directory constant to {gsf} to work around MM {lsf} bug and portable mode
- Moved location of MMIP file to a server that supports PHP

Version 4.2.0.191 - July 17, 2014
- Add option to exclude bracketed text in search
- Add checks for valid JSON, this included a fix to a logic error and increase in wait time for API responses
- Cleaned up the UI a bit more. Buttons now hidden instead of disabled if not applicable
- Force users to Musicbrainz on August 15th, 2014 due to Discogs requirement for oAuth for the database/search endpoint after that date

Version 4.1.0.185 - February 9, 2014
- Fix bug where web searches would fail if main panel in MM was not a music node (eg. web node)
- Updated option page

Version 4.0.1.184

- Fix bug due to malformed API calls with double quote in search string

Version 4.0.0.183 - January 13, 2014
- Uses JSON endpoints for all Discogs API calls
* Special thanks to eepman for supplying the working JSON parser for vbscript. His work based on http://demon.tw/my-work/vbs-json.html#code
- Fixed lookup fail for artists with trailing ", The"
- Add web search option for 45cat.com as per fizzjob
- Add options to apply the earliest date found album name to Original Title, or if one desires Album
- Cleaned up the UI and code some more....

Version 3.0.1.164 - January 29, 2013
- Bug fixes
- Fixed object required bug due to malformed URL requests
- Fixed rate limits for Discogs and MusicBrainz not respected if no results found

Version 3.0.0.163 - January 24, 2013

- Added option to search MusicBrainz (MB searches are extremely fast and is the default on install)
- Added option to search by selected song(s)
- Added options to control displayed results
- Added option to use specific year (e.g. 9999) for searches with no results
- Added Play Next/Start Search button to UI
- Apply to album option moved to UI
- Searches Master releases from Discogs for results (allows for wider search)
- Added option to select number of Discogs Masters to search
  • Each Master searched requires a call to the Discogs API, each call is seperated by 1 second to respect Discogs API terms.
- Added progress bar for Discogs searches (allows user to terminate)
- Added progress bar for multiple selection searches
- Results are sorted automatically (earliest to latest)
- Search performed only on music
- Added timing to respect API terms for Discogs and MB
- Various minor bug fixes


Version 2.0.0.123 - July 3, 2012

- Update panel look and feel
- New Option Sheet
- Added option to use 'Date' field instead of default 'Original Date'
- Added option to update entire album/series
- Added option to use Month/Day if available
- Added option to search only if selected date field is empty - can force search by clicking results dialog
- Added logic so automatic DB updates occur only if the selected date field is blank, and only for single songs
- Fixed bug where the previously searched song results were presented when panel made visible, not the currently playing song
- Fixed bug where auto-updates would not be applied if search date = earliest date found
- Fixed bug where artists with leading "The" would return zero results
- Use UpdateAll method to update DB, and tags as per user selection
- Results dialog shows name of album as well as artist and title and date
- Results header displays the number of results found and the total number of possible Discogs results. Will give some indication of usefulness.
- Current search info can be clicked to open a web page to your favourite music web service, using default web browser.

Usage

  • Back-up your database!
  • Install Earliest Release Date
  • Play A Song or Select Song(s) using MM
  • Script will present a list of release dates for the currently playing song (user selectable up to 50)
  • If panel is not visible after install click on View, then Earliest Date

Options:
Tools-->Options-->Library-->Earliest Date

- Search Earliest Date Using:
Self Explanatory. Can select either MusicBrainz or Discogs. Default on install is MusicBrainz.

- Maximum number of discogs masters to search
User selectable from 1 - 100 only if Discogs search enabled. Default on install is 15. The initial Discogs search searches for Master releases. For each master release the script will make another call to the API to search for the earliest date in the releases for that master. Each call to Discogs takes 1 second.

- Exclude Bracketed Text
Removes the brackets and any text in between to perform the seach for the earliest release date. Helps to find dates for those songs tag with (Live) (12") (Feat...) etc.
Regular parenthesis, square brackets, and curly braces are removed.

- Use 'Date' Field
Self explanatory. Script will update the "Date" Field instead of the "Original Date" field with the earliest date found from Discogs. (Default is OFF for 'Original Date')

- Include the Release Month/Day (if available)
If the month and/or day of the release is available from Discogs the script will display those values and use them for updates to the database. If this option is selected then a release date with a day and or month of release is more significant than one without. For example a release date of Dec 31, 2011 has priority over Dec 2011 and this has priority over a release date of 2011. (Default is ON)

- Search Discogs only if preferred date field is empty
Self Explanatory. Discogs search will only occur if the date field one chooses to use is empty. If this option is selected users can force a search by clicking on the results dialog that is presented in the panel. (Default is OFF)

- Search by selected song(s)
Allows user to search by selected songs in the main window. By turning this option on Automatic DB updates will be forced on too. (Default is OFF)

- Automatically update DB with earliest date found
If checked the database (and tags if the option is set) are updated automatically without user intervention. The script will pick the earliest date available for you. Automatic updates are forced if searching by selected songs.

- Automatically update only if preferred date found is earlier
If selected will only update DB if the preferred date found is earlier than any existing value. (Default is OFF)

- Use specified value for the preferred date if no results found
Allows user to select a value between 1000 and 9999 to use as a year if a search for the earliest date finds no results. Can be because there are no dates for that song, tags are incorrect, or internet connection is down. Default is OFF and "9999".

- Result Display Settings
Controls how the results are shown. Because the dates found are now automatically sorted from earliest to latest the number of radio buttons displayed can be kept to a minimum. User is allowed to select between 1 and 50 results displayed. Default is 5.
User is also allowed to choose what information is displayed. Default is Artist - Album - Song along with earliest date. Artist, Album and Song can be turned off if so desired. Minimum test displayed is the Earliest Date.
Last edited by wxdude on Fri Feb 19, 2016 11:28 pm, edited 18 times in total.
wxdude
 
Posts: 95
Joined: Fri Mar 12, 2010 4:02 pm
Location: Canada

Re: Earliest Release Date from Discogs v2.0

Postby Vyper » Wed Jul 04, 2012 7:26 am

Looks good!

This is going to be a REALLY dumb question but why does the song have to be playing and not just selected? It wouldn't be possible to do this if it weren't?

If it's a long or really technical answer, don't bother, I'll take your word for it. :lol:
Stop Button Freak
Vyper
 
Posts: 845
Joined: Tue May 23, 2006 5:53 pm

Re: Earliest Release Date from Discogs v2.0

Postby wxdude » Wed Jul 04, 2012 8:54 am

Only real reason is that is how the original script worked.

Should be able to search on selected song as well. Will look at adding that to the next version.
wxdude
 
Posts: 95
Joined: Fri Mar 12, 2010 4:02 pm
Location: Canada

Re: Earliest Release Date from Discogs v2.0

Postby Vyper » Wed Jul 04, 2012 2:14 pm

That would be way cool. :D
Stop Button Freak
Vyper
 
Posts: 845
Joined: Tue May 23, 2006 5:53 pm

Re: Earliest Release Date from Discogs v2.0

Postby richiefinger » Thu Jul 05, 2012 1:56 am

I have just used the new version and left it running over night and no cint overflow messages. Excellent.

Excellent work. Thanks so much for taking this script on and improving it.

Would it be possible to add something to the chosen field if nothing is found. I use 9999 in my original date field if I have searched but found nothing?

Would it be very hard to use alternative sites to discogs to find earliest date ?
richiefinger
 
Posts: 152
Joined: Sat Oct 24, 2009 7:58 am

Re: Earliest Release Date from Discogs v2.0

Postby wxdude » Thu Jul 05, 2012 12:35 pm

richiefinger wrote:Would it be possible to add something to the chosen field if nothing is found. I use 9999 in my original date field if I have searched but found nothing?

Should be able to add an option to do that for you.

richiefinger wrote:Would it be very hard to use alternative sites to discogs to find earliest date ?

Looking at using the MusicBrainz API as well. Either as an option or as a new script based on this one.
wxdude
 
Posts: 95
Joined: Fri Mar 12, 2010 4:02 pm
Location: Canada

Re: Earliest Release Date from Discogs v2.0

Postby richiefinger » Thu Jul 12, 2012 2:21 am

OK Thanks. Much appreciated, I hope what I've asked for is something that will appeal to more than just myself.

I've been playing with the script using "previews" of tracks. I noticed this was mentioned in the previous thread but I thought I would update what I have found here.

I have tried using various length previews. 5,10 and 15 seconds. 15 seconds is normally enough length of time for the script to complete it's search and enter data for the tracks that I've been using.
I have had the following results:
When the script finds no date for the playing preview, it plays to the end of the preview and moves on to the next preview in the list. NO PROBLEMS.
When the script finds a date, It enters the data OK but then does 1 of 2 things:
1. It enters the data and then stops. It does not go the next track on the list. OR
2. It starts to play the preview at a super slowed down speed, effectively stopping. If you forward to the next track it will start to work OK again until it enters a new date.
Sometimes an error appears "Y script out of range"

I'm not fussed about using previews. I'm just using them to calculate the dates automatically whilst I'm not at the PC and at a quicker speed than playing in real time.

Would it be possible to have an "auto" mode where the track skips to the next track when data is found/not found? I don't know if that is even possible?
richiefinger
 
Posts: 152
Joined: Sat Oct 24, 2009 7:58 am

Re: Earliest Release Date from Discogs v2.0

Postby Blutarsky » Sat Jul 21, 2012 11:27 am

Wonderful script mate have been waiting for a while to get such a script.

How do you apply the new date? I get a checkbox list, however I can't "apply" the change..... thanks
Blutarsky
 
Posts: 194
Joined: Wed Mar 03, 2010 12:53 pm

Re: Earliest Release Date from Discogs v2.0

Postby Blutarsky » Sat Jul 21, 2012 11:35 am

Ok I wasn't using the date field in place of the original date! Perfect!!!!

A few suggestions:
- you could offer a maximum number of results
- would it be possible to query at once multiple tracks?
Blutarsky
 
Posts: 194
Joined: Wed Mar 03, 2010 12:53 pm

Re: Earliest Release Date from Discogs v2.0

Postby Blutarsky » Sat Jul 21, 2012 11:39 am

- add an option to halt discogs querying? Maybe you could halt on user selection; this would need parsing user input between each result....
Blutarsky
 
Posts: 194
Joined: Wed Mar 03, 2010 12:53 pm

Re: Earliest Release Date from Discogs v2.0

Postby wxdude » Sat Jul 21, 2012 2:17 pm

Blutarsky wrote:A few suggestions:
1 - you could offer a maximum number of results
2 - would it be possible to query at once multiple tracks?


First off glad you like the script, as for your suggestions...

1. Yes and no. The maximum number of results I can return is 20. This is a function of the XML endpoints used in Discogs. On my to-do list is to actually query to the maximum number of 20 and present the 10 earliest dates found. To get the maximum number of results I would need to re-write the script to use the JSON endpoints. I don't know much about JSON parsing, and JScript in general. This one is on my to learn list.

2. It is possible to do multiple queries, but you would overwhelm the API and would most likely result in Discogs blocking your IP for some period of time. Would also have to modify the script to search on selection rather then the currently playing song. Searching by selection is on my to-do list.

The way the script works is it searches for all releases of a Song by Artist. With those results it then searches each release for a date, and then determines the earliest date found. The current script accesses the API at least once (no results) to a maximum of 11 times. With some artists having songs on literally hundreds of releases, to present the maximum number would quickly surpass the stated API request limit of 1 per second (60 per minute). The same principle applies for multiple queries.

The current Discogs API has limited search options which is why it has to be done this way. Would be nice if one could sort the results by release date but this has not been implemented in the Discogs API (yet).

Blutarsky wrote:- add an option to halt discogs querying? Maybe you could halt on user selection; this would need parsing user input between each result....


You can halt Discogs querying by closing the Earliest Date panel. To reopen the panel go to View --> Earliest Date, and the script will start to run on the currently playing song, or at least the last song played. I could add an option button in the panel to pause/start, which I'll add to the to-do list also.
wxdude
 
Posts: 95
Joined: Fri Mar 12, 2010 4:02 pm
Location: Canada

Re: Earliest Release Date from Discogs v2.0

Postby Blutarsky » Sat Jul 21, 2012 3:09 pm

Thanks again.

For example on an 8 results list, you may accept the thirs result, no need to wait the tenth. Clicking on the third result, should apply the new date and halt query. Faster :D
Blutarsky
 
Posts: 194
Joined: Wed Mar 03, 2010 12:53 pm

Re: Earliest Release Date from Discogs v2.0

Postby Blutarsky » Sat Jul 21, 2012 3:55 pm

Do you plan any Muscibrainz querying?
Blutarsky
 
Posts: 194
Joined: Wed Mar 03, 2010 12:53 pm

Re: Earliest Release Date from Discogs v2.0

Postby wxdude » Sat Jul 21, 2012 4:41 pm

Blutarsky wrote:Do you plan any Muscibrainz querying?


The MusicBrainz API appears to have more search option and sorting options and it is on list. Not sure yet whether it will be an option or new script....
wxdude
 
Posts: 95
Joined: Fri Mar 12, 2010 4:02 pm
Location: Canada

Re: Earliest Release Date from Discogs v2.0

Postby Blutarsky » Sat Jul 21, 2012 4:44 pm

MusicBrainz has a far superior accuracy in earliest date.
Blutarsky
 
Posts: 194
Joined: Wed Mar 03, 2010 12:53 pm

Next

Return to Need Help with Addons?

Who is online

Users browsing this forum: Exabot [Bot] and 12 guests