Guida Strumenti (Aggiornato) Guida per scaricare con gallery-dl

NikoCast6

Lurker
Iscritto dal
25 Dic 2024
Messaggi
106
Reazioni
1
Originally posted in this thread where few would ever see it. I thought I'd post an update in my profile, but there's a pretty short length limit on profile posts. So here let me welcome you to my:

:HACKERMANS: _______GUIDE TO GALLERY-DL______ :HACKERMANS:
[ free + open source ]

Q: why tf should I use gallery-dl?A:it magically downloads photo albums - social media - file hosts - image hosts

Q: what sites can it download from?A:instagram + twitter + tiktok + reddit + pinterest + imagefap + redgifs + goonbox

Q: is that all?A: fuck no. it also downloads from:bunkr + gofile + pixeldrain + turbo + tube sites + a shitload more

:HACKERMANS: WHAT YOU NEED TO KNOW: :HACKERMANS:




  • The answer to whatever you want to know is on the codeberg page: https://codeberg.org/mikf/gallery-dl
    • this includes supported sites, errors (see Issues), how to install, etc.
    • this was formerly on github (https://github.com/mikf/gallery-dl), which can still be helpful for past issues/discussions
  • Benefits of downloading with gallery-dl
    • it simplifies downloading from any site it supports
    • supported sites include instagram, twitter, tiktok, reddit, imagefap, redgifs, cxxmer/kemono, pictoa, pinterest, goonbox, bunkr, gofile, pixeldrain, turbo, many tube sites, many image hosts, and a ton more
    • it makes downloading photo albums painless (especially for sites not equipped to handle image dumps. read: bunkr!)
    • it maintains a database of completed downloads so you don't unwittingly re-dl files you already saved. This also means you can return to that [instagram/reddit/whatever] profile from time to time and it will dl only the new files since last time
  • It's really fucking easy to use
    • basic usage:
      • to download a bunkr album,
        Codice:
        gallery-dl https://bunkr.cr/a/RE4jsE8Q
        <- test album. try it out!
      • to download a single file from bunkr,
        Codice:
        gallery-dl https://bunkr.cr/f/zGPPQCux9yOYf
      • to download all posts from an instagram profile,
        Codice:
        gallery-dl https://www.instagram.com/rachelrileyrr
      • to download tagged posts,
        Codice:
        gallery-dl https://www.instagram.com/rachelrileyrr/tagged
        • or replace 'tagged' with 'reels', 'stories', etc. makes sense?
        • alternatively, use
          Codice:
          gallery-dl -o include=posts,tagged,reels https://www.instagram.com/rachelrileyrr
    • it's also massively configurable via config file once you learn the ropes (e.g. automatically name files however you want! organize download locations however you want! damn it's so good!)
  • You should install gallery-dl (and any command line tools) using a package manager
    • a package manager keeps all your command line software up to date, including its dependencies, and organizes them all on your system where they can find each other
      • if you're new to the command line, making sure you have needed dependencies, keeping them properly updated, and figuring out how to make the (god damn!) things find each other is the vast majority of headaches you suffer to get any (god. damned.) program working
      • these problems become moot when you use a package manager
      • srsly, especially if you're new to this, don't fuck around with downloading binaries yourself, let the package manager do it for you. And don't come bitching when you can't get it to work because you ignored this advice
    • mac: gallery-dl is available through Homebrew (most popular) & macports
      • macports has better compatibility with more systems, as Homebrew limits support to newer devices/OSes
      • example usage - it is easy:
        • Codice:
          sudo port install gallery-dl
          installs the program and its required dependencies
        • Codice:
          sudo port selfupdate
          keeps macports up to date and downloads latest info about available programs
        • Codice:
          sudo port upgrade outdated
          upgrades all your installed programs to the latest versions
    • windows: supported pkg managers for windows are Chocolatey and Scoop. idk I don't use windows, but same concept
    • linux: linux users already know what package manager they use. shut up
    • super mega bonus tip: if everything is working and you feel comfortable, you can begin updating on your own to the nightly (aka development) version. it can take a few days or more for additions and bug fixes to make it to a release, but you're guaranteed the latest when you install the nightly. follow the directions under "Install the latest dev version directly from master" -> https://codeberg.org/mikf/gallery-dl#pip <-
  • If something used to work and now it doesn't, upgrade your software to latest versions
    • stuff breaks all the time. websites make a small change that breaks tools and developers need to make changes to keep everything pointed in the right direction. this is how stuff works
    • even if you just upgraded yesterday, check again today. devs of popular software release new versions frequently
    • if you want fixes before they're even released, check the super mega bonus tip above
  • If something is not working, look to the codeberg issues page
    • i'll even link to it for you: https://codeberg.org/mikf/gallery-dl/issues
    • don't ask about the latest bug here or anywhere else other than the gallery-dl repo - nobody knows or cares. ask about it at the link i gave 1 line above this (search for it first because somebody has probably brought it up already)
    • new bugs and stuff will be in "Open" issues. everything anyone's ever asked about will be in "Closed" issues. make sure you are checking both
  • Go forth and download
    • if you're new to the command line, remember that "new" is not the same as "hard". at one time you didn't know how to pick your nose
    • Codice:
      Ctrl+C
      exits you out of running programs
    • remember to go outside every few days, now that you have this power it can be hard to stop using it

ADDITIONAL Q&A:

Q: are you affiliated with gallery-dl?A:not at all. it's just life-changing software that i've spent a lot of time learning and using, and more people should know about and use it.

Q: now that i'm using gallery-dl, will you also come over and jerk me off?A:if you're reasonably fit, young, and don't have a beard, yeah i'll probably do it.
 
adoro gallery-dl ma quando l'ho usato mi hanno bloccato gli account, che palle, pensano che sia un bot ma sono solo un efficiente collezionista di deliziosi tesori :peepoShy:. non è esclusivo di gallery-dl, ho provato altri tool simili e sono riuscito a farmi bloccare anche con quelli. voglio solo avvisare chiunque segua questa utile guida che quando percorri la via dello scraper, i tuoi account potrebbero essere trattati come quei maledetti CLANKERS e finire bannati :BongoBan:, quindi scrapa con discrezione!!
 
Per chi è preoccupato, se leggete una sola riga di questo post: non è una cosa comune, si può evitare, e se non fai il login di proposito in un account non è nemmeno possibile.

Una cosa da tenere a mente se stai scrapando quantità enormi di contenuti. Io non uso quasi mai account sui siti da cui scarico – scarico regolarmente da Instagram e TikTok, ma credo che l'unica volta in cui ho usato cookie autenticati sia stata per accedere a post con restrizioni d'età su Twitter. E ovviamente sai quando lo stai facendo, e puoi prima controllare le info nei repo. Lo sviluppatore è molto attivo e gli extractor sono progettati per evitare problemi, ma sta anche a noi leggere prima la documentazione per assicurarci di usare gli strumenti in sicurezza.

Sarebbe utile se descrivessi brevemente cos'è successo, quando, e da quali siti stavi scaricando. Certo che può succedere, ma è raro, molto più raro se non scarichi su larga scala, e impossibile se non ti autentichi. Il mio obiettivo qui era aiutare la gente a capire quanto può essere facile, e quello che non voglio è spaventare nessuno per paura di qualcosa che è molto improbabile.
 
sì, quindi parliamo dell'uso di cookie autenticati per scaricare da twitter. dove dovremmo guardare nei repo e quali docs leggere per ridurre il rischio di blocchi/sospensioni? per quanto rari, capitano ad alcuni di noi...
 
Certo, non dubito di te. Comunque il mio post non voleva essere una sfida, è solo che non voglio che qualcuno scappi spaventato da uno strumento che per me ha cambiato la vita in termini di efficienza, organizzazione e meno mal di testa.

Non scarico un sacco da Twitter – di solito singoli post, ma ho scaricato uno o due account interi. È stato negli ultimi 6 mesi e non ho avuto nessun problema.

Il posto migliore per restare aggiornati sulle novità recenti (e sui problemi passati) è l'issue tracker nel repo di gallery-dl. In realtà ora ce ne sono 2 dopo il passaggio a codeberg, perché l'issue tracker su github è ancora aperto e attivo. C'è anche una sezione Discussions sul repo github dove la gente fa domande generiche.

L'uso base è facile, ma una volta presa la mano, il vero potere sta nel costruire il tuo config.json per dire agli extractor come comportarsi. Può esserci un po' di curva di apprendimento mentre scopri cosa c'è e come funziona la sintassi, ma col tempo i pezzi si incastrano ed è troppo bello. Molte opzioni riguardano cosa scaricare, come nominare i file e dove mettere cosa, ma molte dicono anche agli extractor come interagire con il sito. Gli extractor sono fatti su misura per ogni sito con le loro opzioni, ed esplorare cosa fanno può rendere la vita migliore/più facile.

I docs sono nella cartella chiamata, appunto, "docs". gallery-dl-example.conf mostra la struttura base di un file di config. configuration.rst è un file mostruoso che elenca ogni opzione disponibile e cosa fa. Se fai scraping serio, vorrai passare parecchio tempo su questo file. Io ci torno spesso. Qui può volerci un po' per costruire le conoscenze, perché è esaustivo ma non scritto come una serie di istruzioni. Ma inizia ad avere senso man mano che capisci come si incastra tutto. Infine, gallery-dl.conf è semplicemente una lista di ogni singola impostazione col suo valore di default, esattamente nel formato usato nel tuo file di config. È sempre il più aggiornato, viene aggiornato quando si aggiungono nuove opzioni/siti.

A un certo punto vorrei aggiungere qui un how-to base per il tuo file di config con esempi. Il mese scorso c'era un thread sul scaricare post/thread da simpcity con gallery-dl e ci ho fatto un post spiegando come la cosa possa sfuggire di mano in fretta, quindi meglio definire un obiettivo più specifico di "scarica tutto in questo thread". Il thread è stato cancellato comunque, perché non volevano incoraggiare lo scraping del forum. Se un mod legge questo e vuole mandarmi il mio post in PM sarebbe figo, e toglierò qualsiasi istruzione sullo scraping dei thread tranne per spiegare perché è comunque una pessima idea.

Per tutti gli altri, sentitevi liberi di fare domande in questo thread, sono felice di condividere quello che ho imparato.
 
Gallery dl è stato una manna dal cielo per me da quando ho iniziato a usarlo all'inizio dell'anno.

proprio la settimana scorsa mi sono messo a pensare a un downloader automatico di storie tiktok e instagram e ho trovato un git project che usava gallery dl per instagram e yt dlp per tiktok. dopo aver modificato parecchio il progetto, finalmente ho un monitor automatico per storie e post di tiktok, con download automatici e anche controlli successivi per sostituire i post con versioni di qualità migliore dopo un certo tempo, dato che tiktok almeno non dà sempre la risoluzione migliore, soprattutto subito dopo la pubblicazione.

Devo ancora aggiungere la registrazione e il download automatici delle live di tiktok e poi passare alla parte instagram, per catturare automaticamente soprattutto le storie con lo stesso setup, ma finora sembra andare bene.

scusate se è il posto sbagliato, ma visto che è un thread su gallery dl ho pensato che potesse essere rilevante o utile per chi cerca opzioni con questo.
 
Purtroppo non ho fortuna con niente. :Sadge:

Ho provato tutto qui sotto con VPN, Instaloader prende subito un 429. Ho visto una issue che dice che l'endpoint API del profilo che usano è deprecato, qualcuno ha una pull request con una fix, quindi magari riprovo se viene mergiata.

Un tutorial online dice di provare prima gallery-dl con l'opzione simulate, ma mi dice profilo non trovato. Una issue diceva che per rippare account NSFW, anche pubblici, probabilmente bisogna fare il login.

Ho provato a creare un nuovo account per gallery-dl o qualcosa come Gramoire, ma sembra che IG faccia shadow block delle email Protonmail, visto che non accetta il mio codice di verifica. Ho riprovato con una mail da 10 minuti e il codice l'ha preso, ma poi volevano un numero di telefono. Non voglio provare con uno dei miei account veri / rischiare di collegare un usa e getta ai miei account veri.

---

Voi riuscite a scaricare post IG senza fare login/dare i cookie al tool che usate? Oppure fate login rischiando un account vero, o siete riusciti a creare account usa e getta che non vi importano? L'account principale che voglio rippare non è privato, quindi speravo di poter fare qualcosa senza login.
 
La funzione per ig è morta finché il proprietario non la aggiorna, e probabilmente non lo farà per un po'
 
Indietro
Top