ASPN ActiveState Programmer Network
  ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups | Web Services
SEARCH

Reference
ActivePython 2.5
Python Documentation
Library Reference
9. File Formats
9.1 csv -- CSV File Reading and Writing
9.2 ConfigParser -- Configuration file parser
9.3 robotparser -- Parser for robots.txt
9.4 netrc -- netrc file processing
9.4.1 netrc Objects
9.5 xdrlib -- Encode and decode XDR data

MyASPN >> Reference >> ActivePython 2.5 >> Python Documentation >> Library Reference >> 9. File Formats
ActivePython 2.5 documentation

9.4 netrc -- netrc file processing

New in version 1.5.2.

The netrc class parses and encapsulates the netrc file format used by the Unix ftp program and other FTP clients.

class netrc( [file])
A netrc instance or subclass instance encapsulates data from a netrc file. The initialization argument, if present, specifies the file to parse. If no argument is given, the file .netrc in the user's home directory will be read. Parse errors will raise NetrcParseError with diagnostic information including the file name, line number, and terminating token.

exception NetrcParseError
Exception raised by the netrc class when syntactical errors are encountered in source text. Instances of this exception provide three interesting attributes: msg is a textual explanation of the error, filename is the name of the source file, and lineno gives the line number on which the error was found.



See About this document... for information on suggesting changes.

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState 2004 All rights reserved