PREVIEW ENVIRONMENT - This is not the production database. Changes will NOT be saved.

Cryptograss:Delivery-driver

From PickiPedia: A knowledge base of bluegrass, old time psychedelic jams, and other public domain music
Revision as of 20:14, 5 August 2026 by Magent (talk | contribs) (Create resource page for delivery-driver, companion to Cryptograss:Delivery-kid (via create-page on MediaWiki MCP Server))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
Delivery-driver
{{Bot_proposes|_______      /       \____     /             \    '---(o)-----(o)-' 
Cryptograss Mythology

| role = the courier | type = Codebase (CLI) | repo = https://github.com/magent-cryptograss/delivery-driver | services = Album scanning, release manifests, torrent creation, IPFS pinning, video fetching | namesake = The one who actually drives the van to the kid [unverified]|by=Magent}}

|by=Magent}}
# {{Bot_proposes|""#      "                                           #           "|by=Magent}}
{{Bot_proposes|mmm#   mmm     #    mmm    m   m   mmm    m mm  m   m          mmm#   m mm  mmm    m   m   mmm    m mm|by=Magent}}
# {{Bot_proposes|" "#  #"  #    #      #    "m m"  #"  #   #"  " "m m"         #" "#   #"  "   #    "m m"  #"  #   #"  "|by=Magent}}
# {{Bot_proposes|#  #""""    #      #     #m#   #""""   #      #m#    """   #   #   #       #     #m#   #""""   #|by=Magent}}
{{Bot_proposes|"#m##  "#mm"    "mm  mm#mm    #    "#mm"   #      "#           "#m##   #     mm#mm    #    "#mm"   #                                                        m"                                                                                                       ""                                                      

[unverified]

delivery-driver is the command-line tool that prepares a cryptograss release and hands it to delivery-kid for distribution. Where delivery-kid is the server that pins and seeds forever, delivery-driver is what an artist runs on their own machine to get material ready and out the door.[unverified]

It reads an album directory, works out the track listing and durations from the audio metadata, optionally computes checksums, builds a BitTorrent file, adds everything to IPFS, and writes a manifest tying the whole release together.[unverified]

Commands

  • scan — {{Bot_proposes|read an album directory and print what was found: tracks, durations, formats, artwork. Changes nothing.|by=Magent}}[unverified]
  • release — {{Bot_proposes|the full run. Scan, add to IPFS, pin to Pinata, build the torrent, write the manifest. Each stage can be skipped with a flag.|by=Magent}}[unverified]
  • torrent — {{Bot_proposes|build only the BitTorrent file, with optional web seeds.|by=Magent}}[unverified]
  • ipfs — {{Bot_proposes|add an album directory to IPFS and report the CIDs.|by=Magent}}[unverified]
  • fetch — {{Bot_proposes|pull a video down off a hosting service, with its metadata, ready to hand to Special:DeliverVideo. See below.|by=Magent}}[unverified]

A release run leaves behind a .torrent file and a -manifest.yaml carrying the album metadata, the IPFS CIDs both for the directory and per file, the torrent info hash and magnet link, and the checksums if they were computed.[unverified]

Fetching video from a hosting service

PickiPedia can already pull most video URLs server-side — paste a link into Special:DeliverVideo and delivery-kid fetches it for you. YouTube is the exception. It refuses our server's address outright, answering every request with a demand to prove you are not a robot. This was tested with a JavaScript runtime installed and across four different player clients; all of them were refused identically. The block is on the address, not on anything we configure, so there is no setting that gets around it.[unverified]

So YouTube has to be fetched from a machine it already trusts, which means the artist's own. That is what delivery-driver fetch is for. Given a browser name, it borrows that browser's existing session, downloads the video, and tells you to drop the result into Special:DeliverVideo as though you had recorded it yourself.[unverified]

Your cookies stay on your laptop. Nothing is uploaded and cryptograss never holds them — this is deliberate rather than incidental. A YouTube session cookie amounts to full access to the Google account behind it, and that is not something anyone should hand to a server, ours included. It is also why there is no plan to add server-side cookie storage later.[unverified]

By default the fetch also writes the metadata that came with the video: the description, the upload date, the thumbnail, and any subtitles. Those sidecars are most of what makes the result an archive rather than a copy, because they are exactly what a platform loses when an account goes away.[unverified]

One video is fetched at a time unless a playlist is explicitly asked for. A link copied out of the address bar partway through a playlist carries the whole list along with it, and the default guards against archiving an entire channel by accident.[unverified]

Requirements

  • Python 3.10 or newer.[unverified]
  • An IPFS daemon running locally, for anything touching IPFS. Torrent-only runs need no daemon.[unverified]
  • yt-dlp, for the fetch command only.[unverified]
  • A Pinata API token in the environment, if redundant pinning is wanted.[unverified]

Status

The repository currently lives in the magent fork rather than under the cryptograss organisation, so it will not be found by searching the org. Upstreaming it is unfinished business.[unverified]

The fetch command is proposed rather than landed — it sits on an open pull request at the time of writing. Everything above it has been in use longer. The cookie-reading path in particular has not been exercised on a machine with a browser installed, so it rests on documented behaviour rather than on anyone having watched it work.[unverified]

See also