Coder Social home page Coder Social logo

offlickr2's People

Contributors

dmd avatar hugoh avatar mend-bolt-for-github[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

offlickr2's Issues

Not working as intended?

Hello,

First time I am trying this program (I've been using Oflickr.py for a while, but it just stopped working). It works fine when I download a specific photo (-p PHOTO_ID). But when I try to download all my photos (I have 315 photos in my Flickr account), using this command

php ./Offlickr2.php -i MY_ID -d ... -P -v 2

the program never stops running, producing messages like this:

  • Total so far: 555345 photo(s)
  • Setting photos list page 1764
  • Total so far: 555660 photo(s)
  • Setting photos list page 1765

Am I doing something wrong? Is "-P" option meant to download all my photos? Because it looks like it is trying to download all Flick photos.

Thanks!

crashes when I try to back up a set

So far I haven't been able to make offlickr2 do anything except crash with these error messages:

PHP Notice: unserialize(): Error at offset 0 of 347 bytes in /home/steve/src/offlickr2/phpflickr-3.0/phpFlickr.php on line 301
PHP Fatal error: Class 'DOMDocument' not found in /home/steve/src/offlickr2/Offlickr2.php on line 151

API change causes endless loop?

According to
https://www.flickr.com/services/api/explore/flickr.photos.search
if I set a page number greater than the number of pages, then it still returns results. Hence this now never finishes (it did when I last ran my backup a few months ago):

   if (count($photos['photo']) == 0) {

Fix appears to be (I'm not a php coder by a long stretch):

diff --git a/Offlickr2.php b/Offlickr2.php
index 6a97958..2d00451 100755
--- a/Offlickr2.php
+++ b/Offlickr2.php
@@ -396,8 +396,13 @@ class Offlickr2 {
if (count($photos['photo']) == 0) {
break;
}

  •  if ($page > $photos['pages']) {
    
  •    printf ("debug: past the end of pages? $page > %s\n", $photos['pages']);
    
  •    break;
    
  •  }
    
    foreach ($photos['photo'] as $photo) {
    array_push($this->photo_list, $photo['id']);
  •    printf ("debug: %s %d\n", $photo['id'], $page);
    
    }
    $retrieved = count($this->photo_list);
    $this->dialog->info(2, "Total so far: " . $retrieved . " photo(s)");

P.S. why do I need this in my local version to stave off php warnings?
diff --git a/LocalStorage.php b/LocalStorage.php
index 0eb009c..4e8b221 100644
--- a/LocalStorage.php
+++ b/LocalStorage.php
@@ -18,6 +18,8 @@ abstract class LocalItem {
}

function setup_temporary_dir() {

  • $path="/tmp";
  • $prefix="offlickr2.";
    // FIXME: Not atomic
    $tempname = tempnam($path,$prefix);
    if (!$tempname) {
    @@ -329,4 +331,4 @@ class LocalStorage {

}

-?>
\ No newline at end of file
+?>

target folders only as dates

When run for sets backup of photos, all the photos are placed in folder format folders like /2011/08/03, etc which isn't good at all for organization! I need the ability to back up to the set idenitication # so everything is the same as it is on flickr sets. Sets should be called the full # like "57627351269986" like older versions of offickr!

Installation instructions fail

dmd@pico ~/build/Offlickr2
$ git submodule update --init --recursive
Submodule 'phpflickr' ([email protected]:dan-coulter/phpflickr.git) registered for path 'phpflickr'
Cloning into 'phpflickr'...
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
Clone of '[email protected]:dan-coulter/phpflickr.git' into submodule path 'phpflickr' failed

"Could not find source URL"

Thanks for your work on Offlickr2. It installed fine, but doesn't seem to like any of our photos:

% php ./Offlickr2.php -P -S -i '61686668@N08' -d ~/backups/images/zendo/
Getting photo list
Found: 42 photo(s)
Backing up photo 5609390165 [1/42]
ERROR: Could not find source URL
Backing up photo 5609968782 [2/42]
ERROR: Could not find source URL
Backing up photo 5609389281 [3/42]
ERROR: Could not find source URL
Backing up photo 5609967516 [4/42]
ERROR: Could not find source URL
Backing up photo 5609388021 [5/42]
^C

Any ideas?

Thanks,
Jeff

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.