Step though fetch and others

Ryan Schmidt ryandesign at macports.org
Thu Feb 5 19:00:43 PST 2009


On Feb 5, 2009, at 20:47, Bradley Giesbrecht wrote:

>> You can enable debug mode with the -d switch:
>>
>> cd path/to/dbmail
>> sudo port clean
>> sudo port -d fetch
>
> Which is what I was doing and debug does not print the protocol or  
> url.
>
> Maybe it should?

It does print download progress including the URL (well, sort of) if  
it needs to download something, but not if it thinks it already has  
the file.

Try cleaning the distfiles too.

cd path/to/dbmail
sudo port clean --all
sudo port -d fetch


>> You can also get the full URLs MacPorts wants to download from by  
>> using
>>
>> port distfiles
>
> This does what I was looking for and has me puzzled.
>
> If I copy and paste the first url from the (port distfiles) list  
> into my browser I get the file I want downloaded.
>
> If I md5 the file the checksums match.
>
> If I do:
> file dbmail-2.2.11.tar.gz
> dbmail-2.2.11.tar.gz: gzip compressed data, from Unix, last  
> modified: Mon Feb  2 06:26:11 2009
>
> But if I do:
> file /opt/local/var/macports/distfiles/dbmail/dbmail-2.2.11.tar.gz
> /opt/local/var/macports/distfiles/dbmail/dbmail-2.2.11.tar.gz: HTML  
> document text
>
> I'm at a lose without stepping through fetch. And I am not familiar  
> with tcl but probably will be someday:)

It works for me using your portfile. Maybe their server had a  
momentary difficulty.

Or maybe your ISP's DNS server returns incorrect results (i.e. a  
search page) when a hostname is not found. What is in the HTML file  
you downloaded?


$ port -d fetch
DEBUG: Changing to port directory: /private/tmp/dbmail
DEBUG: setting option os.universal_supported to yes
DEBUG: org.macports.load registered provides 'load', a pre-existing  
procedure. Target override will not be provided
DEBUG: org.macports.distfiles registered provides 'distfiles', a pre- 
existing procedure. Target override will not be provided
DEBUG: adding the default universal variant
DEBUG: Requested variant darwin is not provided by port dbmail.
DEBUG: Requested variant i386 is not provided by port dbmail.
DEBUG: Requested variant macosx is not provided by port dbmail.
DEBUG: Changing to port directory: /private/tmp/dbmail
DEBUG: setting option os.universal_supported to yes
DEBUG: org.macports.load registered provides 'load', a pre-existing  
procedure. Target override will not be provided
DEBUG: org.macports.distfiles registered provides 'distfiles', a pre- 
existing procedure. Target override will not be provided
DEBUG: adding the default universal variant
DEBUG: Requested variant darwin is not provided by port dbmail.
DEBUG: Requested variant i386 is not provided by port dbmail.
DEBUG: Requested variant macosx is not provided by port dbmail.
DEBUG: Executing org.macports.main (dbmail)
--->  Fetching dbmail
DEBUG: Executing org.macports.fetch (dbmail)
--->  dbmail-2.2.11.tar.gz doesn't seem to exist in /mp/var/macports/ 
distfiles/dbmail
DEBUG: Pinging www.dbmail.org...
DEBUG: Pinging distfiles.macports.org...
DEBUG: Pinging trd.no.distfiles.macports.org...
DEBUG: Pinging arn.se.distfiles.macports.org...
DEBUG: www.dbmail.org ping time is 170.158
DEBUG: distfiles.macports.org ping time is 64.357
DEBUG: trd.no.distfiles.macports.org ping time is 185.161
DEBUG: arn.se.distfiles.macports.org ping time is 154.452
--->  Attempting to fetch dbmail-2.2.11.tar.gz from http:// 
distfiles.macports.org/dbmail
   % Total    % Received % Xferd  Average Speed   Time    Time      
Time  Current
                                  Dload  Upload   Total   Spent     
Left  Speed
   0     0    0     0    0     0      0      0 --:--:-- --:--:--  
--:--:--     0
DEBUG: Fetching failed:: HTTP response code said error
--->  Attempting to fetch dbmail-2.2.11.tar.gz from http:// 
arn.se.distfiles.macports.org/dbmail
   % Total    % Received % Xferd  Average Speed   Time    Time      
Time  Current
                                  Dload  Upload   Total   Spent     
Left  Speed
   0     0    0     0    0     0      0      0 --:--:-- --:--:--  
--:--:--     0
DEBUG: Fetching failed:: HTTP response code said error
--->  Attempting to fetch dbmail-2.2.11.tar.gz from http:// 
www.dbmail.org/download/2.2/
   % Total    % Received % Xferd  Average Speed   Time    Time      
Time  Current
                                  Dload  Upload   Total   Spent     
Left  Speed
100  880k  100  880k    0     0  44495      0  0:00:20  0:00:20  
--:--:-- 56464
$ port checksum
--->  Verifying checksum(s) for dbmail
$




More information about the macports-dev mailing list