|
This Page is Glorious History! |
|
The content of this page either is bit-rotted, or has lost its reason to exist due to some new features having been implemented in MusicBrainz, or maybe just described something that never made it in (or made it in a different way), or possibly is meant to store information and memories about our Glorious Past. |
|
We still keep this page to honor the brave editors who, during the prehistoric times (prehistoric for you, newcomer!), struggled hard to build a better present and dreamed of an even better future. We also keep it for archival purposes because possibly it still contains crazy thoughts and ideas that may be reused someday. If you're not into looking at either the past or the future, you should just disregard entirely this page content and look for an up to date documentation page elsewhere. |
For a long time, this very helpful script was the only way to add batch ARs to tracks. Nowadays though, the server natively supports adding ARs to a selection of tracks in a release. While this script may still be of interest for people interested in the mechanics (and while it still is somewhat more flexible than what the site proposes), most editors probably don't have a need for it anymore, and newcomers are strongly discouraged to try using it!
Batch Add Relationships
A script to perform batched adds of AdvancedRelationships.
This is to be run client-side; for each relationship which is to be added, it opens the user's web browser with ServerAccessEditingURLs at the appropriate page so they can (ideally) just click "submit" to enter the mod.
Tentative File-format
Entity Selection
Two lines, each of the following format:
Track: TrackID, TrackID, ...
Release: ReleaseID, ReleaseID, ...
Artist: ArtistID, ArtistID, ...
Relationship Parameters
Type: -- mandatory, valid values depend on entity-type0, and entity-type1...
Note: EditNote -- optional, default is blank
AdvancedRelationshipAttribute``s
Guest -- boolean, default no, present yes
Additional --boolean, default no, present yes
Minor -- boolean, default no, present yes
Vocal -- set, small number of possibilities
Instrument -- set, large number of possibilities, need large lookup-table...
BeginDate/EndDate -- dates
Orchestra -- set, small number of possibilites
Example
# John Denver artist 1121 # Orchestra del Teatro Comunale di Bologna artist 353645 type does/did vocal support for baritone guest note: do not submit this! enddate 2005-01-02 # Disney, John Denver artist 104 1121 # Only To Be With You, Find Me, When Will You Fall For Me track 5739302 5739308 5739311 type dj-mixed note hah! yeah right... additional # Die Schöne und das Biest (disc 1), La Belle et la Bête release 38306 325615 # Marilyn Manson (group) artist 187 guest type produced material that was sampled in note like that'd happen
Invocation
batchaddars files...
opens add relationship edits in new browser tabs.
Operation
Break files into stanzas
Foreach stanza
Parse first and second lines, extract type of entities, read entity ids
parse relationship parameters
Foreach (Entity1, Entity2) pair
queue an edit to add a relationship between Entity1 and Entity2 with specified parameters
Foeach edit
open new tab to for the edit
Delay a few seconds to reduce server load.
Files
batchaddars-4.pl -- the script 2006-05-06
ChangeLog
Prototype
First working release
Complete tables, inline tables into script
Fix bug with only one stanza
ToDo
Allow specifying track n of release y, rather than requiring the rowid of the track
Allow specifying entities by uuid in addition to rowid
Think about URLs
Probably need to be a seprate script, given it's a seprate form...
CategoryDevelopment CategoryDiscussion CategoryHistory







