@@ -62,26 +62,24 @@ protected function fetchWithPrestissimo($version, $destination, $override) {
62
62
63
63
$ multi = new CurlMulti ();
64
64
$ multi ->setRequests ($ requests );
65
- do {
66
- $ multi ->setupEventLoop ();
67
- $ multi ->wait ();
68
- $ result = $ multi ->getFinishedResults ();
69
- $ successCnt += $ result ['successCnt ' ];
70
- $ failureCnt += $ result ['failureCnt ' ];
71
- if (isset ($ result ['errors ' ])) {
72
- $ errors += $ result ['errors ' ];
73
- }
74
- if ($ this ->progress ) {
75
- foreach ($ result ['urls ' ] as $ url ) {
76
- $ this ->io ->writeError (" - Downloading <comment> $ successCnt</comment>/<comment> $ totalCnt</comment>: <info> $ url</info> " , TRUE );
77
- }
78
- }
79
- } while ($ multi ->remain ());
80
-
81
- $ urls = array_keys ($ errors );
82
- if ($ urls ) {
83
- throw new \Exception ('Failed to download ' . implode (", " , $ urls ));
84
- }
65
+ try {
66
+ do {
67
+ $ multi ->setupEventLoop ();
68
+ $ multi ->wait ();
69
+ $ result = $ multi ->getFinishedResults ();
70
+ $ successCnt += $ result ['successCnt ' ];
71
+ $ failureCnt += $ result ['failureCnt ' ];
72
+ foreach ($ result ['urls ' ] as $ url ) {
73
+ if (isset ($ result ['errors ' ][$ url ])) {
74
+ $ this ->io ->writeError (" - Downloading <warning> $ successCnt</warning>/<warning> $ totalCnt</warning>: <warning> $ url</warning> " , TRUE );
75
+ } else {
76
+ $ this ->io ->writeError (" - Downloading <comment> $ successCnt</comment>/<comment> $ totalCnt</comment>: <info> $ url</info> " , TRUE );
77
+ }
78
+ }
79
+ } while ($ multi ->remain ());
80
+ } catch (FetchException $ e ) {
81
+ // do nothing
82
+ }
85
83
}
86
84
87
85
}
0 commit comments