import: pypi: Make downloads silent.
* guix/import/pypi.scm (pypi-fetch): Wrap body in 'call-with-output-file' and 'with-error-to-port'.
This commit is contained in:
		
							parent
							
								
									d1cb7e9562
								
							
						
					
					
						commit
						32728adb95
					
				
					 1 changed files with 8 additions and 1 deletions
				
			
		|  | @ -45,7 +45,14 @@ | |||
| (define (pypi-fetch name) | ||||
|   "Return an alist representation of the PyPI metadata for the package NAME, | ||||
| or #f on failure." | ||||
|   (json-fetch (string-append "https://pypi.python.org/pypi/" name "/json"))) | ||||
|   ;; XXX: We want to silence the download progress report, which is especially | ||||
|   ;; annoying for 'guix refresh', but we have to use a file port. | ||||
|   (call-with-output-file "/dev/null" | ||||
|     (lambda (null) | ||||
|       (with-error-to-port null | ||||
|         (lambda () | ||||
|           (json-fetch (string-append "https://pypi.python.org/pypi/" | ||||
|                                      name "/json"))))))) | ||||
| 
 | ||||
| (define (latest-source-release pypi-package) | ||||
|   "Return the latest source release for PYPI-PACKAGE." | ||||
|  |  | |||
		Reference in a new issue