This list is closed, nobody may subscribe to it.
2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2015 |
Jan
(40) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(14) |
Dec
|
From: <ma...@us...> - 2015-11-25 16:23:16
|
Revision: 744 http://sourceforge.net/p/pywbem/code/744 Author: maiera Date: 2015-11-25 16:23:14 +0000 (Wed, 25 Nov 2015) Log Message: ----------- Added sitemap.xml to web project; The old web pages now redirect to their specific counterpart pages on the new web site. Modified Paths: -------------- web/apiref.shtml web/books.shtml web/development.shtml web/documentation.shtml web/examples.shtml web/installation.shtml web/roadmap.shtml web/robots.txt web/tutorial.shtml Added Paths: ----------- web/sitemap.xml Modified: web/apiref.shtml =================================================================== --- web/apiref.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/apiref.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/doc/latest/index.html" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/doc/latest/index.html">click here</a>.</p> </body> </html> Modified: web/books.shtml =================================================================== --- web/books.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/books.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/documentation.html" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/documentation.html">click here</a>.</p> </body> </html> Modified: web/development.shtml =================================================================== --- web/development.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/development.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/contributing.html" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/contributing.html">click here</a>.</p> </body> </html> Modified: web/documentation.shtml =================================================================== --- web/documentation.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/documentation.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/documentation.html" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/documentation.html">click here</a>.</p> </body> </html> Modified: web/examples.shtml =================================================================== --- web/examples.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/examples.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/tutorial.html" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/tutorial.html">click here</a>.</p> </body> </html> Modified: web/installation.shtml =================================================================== --- web/installation.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/installation.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/installation.html" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/installation.html">click here</a>.</p> </body> </html> Modified: web/roadmap.shtml =================================================================== --- web/roadmap.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/roadmap.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/contributing.html"< /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/contributing.html">click here</a>.</p> </body> </html> Modified: web/robots.txt =================================================================== --- web/robots.txt 2015-11-18 10:27:21 UTC (rev 743) +++ web/robots.txt 2015-11-25 16:23:14 UTC (rev 744) @@ -1,3 +1,2 @@ User-agent: * -Allow: /index.shtml -Disallow: / +Allow: / Added: web/sitemap.xml =================================================================== --- web/sitemap.xml (rev 0) +++ web/sitemap.xml 2015-11-25 16:23:14 UTC (rev 744) @@ -0,0 +1,192 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- This file has been generated by sitemapgen.py on 2015-11-25 --> +<urlset + xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd"> + <url> + <loc>http://pywbem.sourceforge.net/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/footer.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/roadmap.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/documentation.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/header.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/books.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/logo-hp.gif/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/style.css/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/logo-ibm.gif/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/screenshot-1.png/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/apiref.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/HOWTO.md/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/development.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/navbar.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/examples.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/screenshots.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/index.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/tutorial.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/RSS.gif/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/installation.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/old-news.shtml/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/MDC_2008_Python_Providers.odp/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/MDC_2007_Python_Providers.pdf/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/MDC_2008_Python_Providers.pdf/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/MDC_2007_Python_Providers.odp/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/04-createinstance.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/05-modifyinstance.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/02-getinstance.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/06-invokemethod.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/03-deleteinstance.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/01-enumerate-instances.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/00-connect.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/MDC2005/README/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/MDC2005/instance-checker.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/MDC2005/MDC2005.ppt/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/MDC2005/schema-browser.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> + <url> + <loc>http://pywbem.sourceforge.net/docs/examples/MDC2005/mini-cimom.py/</loc> + <lastmod>2015-11-25</lastmod> + <changefreq>weekly</changefreq> + </url> +</urlset> Modified: web/tutorial.shtml =================================================================== --- web/tutorial.shtml 2015-11-18 10:27:21 UTC (rev 743) +++ web/tutorial.shtml 2015-11-25 16:23:14 UTC (rev 744) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/pywbem/tutorial.html" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> @@ -12,7 +12,7 @@ to the new project page.</p> <p>If that does not happen within a few seconds, -<a href="http://pywbem.github.io/">click here</a>.</p> +<a href="http://pywbem.github.io/pywbem/tutorial.html">click here</a>.</p> </body> </html> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-18 10:27:24
|
Revision: 743 http://sourceforge.net/p/pywbem/code/743 Author: maiera Date: 2015-11-18 10:27:21 +0000 (Wed, 18 Nov 2015) Log Message: ----------- Updated README files in the distribution subtree with pointers to new site at GitHub. Modified Paths: -------------- pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst Added Paths: ----------- pywbem/dist/README.md Added: pywbem/dist/README.md =================================================================== --- pywbem/dist/README.md (rev 0) +++ pywbem/dist/README.md 2015-11-18 10:27:21 UTC (rev 743) @@ -0,0 +1,6 @@ +The PyWBEM project has been moved to GitHub +------------------------------------------- + +Its web site is now at +[http://pywbem.github.io](http://pywbem.github.io). + Modified: pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst =================================================================== --- pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst 2015-11-18 10:07:34 UTC (rev 742) +++ pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst 2015-11-18 10:27:21 UTC (rev 743) @@ -1,7 +1,8 @@ PyWBEM v0.8.0 ------------- -**Because the PyWBEM project has been moved to GitHub, you need to go there -for downloading the latest 0.8.0 version: -<a href="http://pywbem.github.io">http://pywbem.github.io</a>.** +The PyWBEM project has been moved to GitHub, and the list of 0.8.0 development +versions you find here is not the latest. +For downloading the latest 0.8.0 version, go to +`pywbem.github.io <http://pywbem.github.io/>`_ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-18 10:07:36
|
Revision: 742 http://sourceforge.net/p/pywbem/code/742 Author: maiera Date: 2015-11-18 10:07:34 +0000 (Wed, 18 Nov 2015) Log Message: ----------- Fixed link in README file for 0.8.0 distribution. Modified Paths: -------------- pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst Modified: pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst =================================================================== --- pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst 2015-11-18 10:03:31 UTC (rev 741) +++ pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst 2015-11-18 10:07:34 UTC (rev 742) @@ -1,7 +1,7 @@ PyWBEM v0.8.0 ------------- -**Attention: This project has been moved to -[http://pywbem.github.io](http://pywbem.github.io). -You can download the latest version from there.** +**Because the PyWBEM project has been moved to GitHub, you need to go there +for downloading the latest 0.8.0 version: +<a href="http://pywbem.github.io">http://pywbem.github.io</a>.** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-18 10:03:33
|
Revision: 741 http://sourceforge.net/p/pywbem/code/741 Author: maiera Date: 2015-11-18 10:03:31 +0000 (Wed, 18 Nov 2015) Log Message: ----------- Updated README file for 0.8.0 distribution to point to GitHub. Modified Paths: -------------- pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst Modified: pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst =================================================================== --- pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst 2015-11-18 09:58:22 UTC (rev 740) +++ pywbem/dist/pywbem-0.8.0/README-0.8.0-dev.rst 2015-11-18 10:03:31 UTC (rev 741) @@ -1,9 +1,7 @@ -PyWBEM v0.8.0-dev ------------------ +PyWBEM v0.8.0 +------------- -**Attention:** This version of PyWBEM is still in development (as indicated by -the "-dev" suffix in the version string). +**Attention: This project has been moved to +[http://pywbem.github.io](http://pywbem.github.io). +You can download the latest version from there.** -The NEWS file in the download archive describes the changes up to now. - -Please report any issues using the PyWBEM bug tracker on SourceForge. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-18 09:58:24
|
Revision: 740 http://sourceforge.net/p/pywbem/code/740 Author: maiera Date: 2015-11-18 09:58:22 +0000 (Wed, 18 Nov 2015) Log Message: ----------- Re-enabled index.shtml for search engine scanning, and updated it to reference the new project site. Modified Paths: -------------- web/index.shtml web/robots.txt Modified: web/index.shtml =================================================================== --- web/index.shtml 2015-11-16 14:05:23 UTC (rev 739) +++ web/index.shtml 2015-11-18 09:58:22 UTC (rev 740) @@ -8,10 +8,11 @@ </head> <body> -<p>The PyWBEM project has moved. You will be automatically redirected -to the new project page.</p> +<p>The PyWBEM project has moved to +<a href="http://pywbem.github.io/">http://pywbem.github.io</a>.</p> -<p>If that does not happen within a few seconds, +<p>You will be automatically redirected to the new project page. +If that does not happen within a few seconds, <a href="http://pywbem.github.io/">click here</a>.</p> </body> Modified: web/robots.txt =================================================================== --- web/robots.txt 2015-11-16 14:05:23 UTC (rev 739) +++ web/robots.txt 2015-11-18 09:58:22 UTC (rev 740) @@ -1,2 +1,3 @@ User-agent: * +Allow: /index.shtml Disallow: / This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-16 14:05:25
|
Revision: 739 http://sourceforge.net/p/pywbem/code/739 Author: maiera Date: 2015-11-16 14:05:23 +0000 (Mon, 16 Nov 2015) Log Message: ----------- Added README file to root directory of code repository, that points to the new project location at GitHub. Added Paths: ----------- README.md Added: README.md =================================================================== --- README.md (rev 0) +++ README.md 2015-11-16 14:05:23 UTC (rev 739) @@ -0,0 +1,3 @@ +**Attention: This project has been moved to GitHub. Its source code +repositories are now in the pywbem GitHub organisation: +[https://github.com/pywbem](https://github.com/pywbem) ** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-16 13:55:53
|
Revision: 738 http://sourceforge.net/p/pywbem/code/738 Author: maiera Date: 2015-11-16 13:55:50 +0000 (Mon, 16 Nov 2015) Log Message: ----------- Described new publish script in HOWTO.md; Minor changes in publish script. Modified Paths: -------------- web/HOWTO.md web/publish Modified: web/HOWTO.md =================================================================== --- web/HOWTO.md 2015-11-16 13:47:44 UTC (rev 737) +++ web/HOWTO.md 2015-11-16 13:55:50 UTC (rev 738) @@ -1,13 +1,17 @@ -How to update the PyWBEM project web site on SourceForge -======================================================== +How to publish to the PyWBEM project web site on SourceForge +============================================================ -That web site is not automatically updated when files are committed to the -`web` subdirectory of the code repository. They need to be manually -updated, by transferring the files to +That web site (http://pywbem.sourceforge.net) is not automatically updated when +files are committed to the `web` subdirectory of the code repository. They need +to be updated separately, by transferring the files to `US...@we.../home/project-web/pywbem/htdocs` where `USERID` is the userid of a PyWBEM admin. You can use any of these protocols: SFTP, SCP, or rsync (for example, FileZilla). -For details, see +For convenience, there is the `publish` script in this directory that publishes +the entire subtree using rsync. Invoke the script without parameters or with +--help to get a help text. + +For further details about web publishing on SourceForge, see [SourceForge web hosting](https://sourceforge.net/p/forge/documentation/Project%20Web%20Services/). Modified: web/publish =================================================================== --- web/publish 2015-11-16 13:47:44 UTC (rev 737) +++ web/publish 2015-11-16 13:55:50 UTC (rev 738) @@ -8,8 +8,9 @@ if [[ -z $userid || $userid == --help ]] then echo "" - echo "Publish the current directory and any subdirectories to the PyWBEM" - echo "web presence at http:/pywbem.sourceforge.net." + echo "Publish the current directory and its subdirectories to the PyWBEM" + echo "web presence at http:/pywbem.sourceforge.net. Deletions of files will" + echo "also be propagated to the web site." echo "" echo "Usage:" echo " $0 {userid} [{dir}]" @@ -27,6 +28,6 @@ echo "Publishing directory $dir" echo "Use the password for SourceForge userid $userid, below:" -rsync -v -r -l -t --delete $dir $us...@we...:/home/project-web/pywbem/htdocs/ +rsync -v -r -l -t --delete --exclude=HOWTO.md --exclude=publish $dir $us...@we...:/home/project-web/pywbem/htdocs/ rc=$? exit $rc This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-16 13:47:46
|
Revision: 737 http://sourceforge.net/p/pywbem/code/737 Author: maiera Date: 2015-11-16 13:47:44 +0000 (Mon, 16 Nov 2015) Log Message: ----------- Exchanged publish-as with publish script which publishes the entire subtree. Added Paths: ----------- web/publish Removed Paths: ------------- web/publish-as Added: web/publish =================================================================== --- web/publish (rev 0) +++ web/publish 2015-11-16 13:47:44 UTC (rev 737) @@ -0,0 +1,32 @@ +#!/bin/bash +# See help message, below. + +default_dir="." +userid=$1 +dir=${2:-$default_dir} + +if [[ -z $userid || $userid == --help ]] +then + echo "" + echo "Publish the current directory and any subdirectories to the PyWBEM" + echo "web presence at http:/pywbem.sourceforge.net." + echo "" + echo "Usage:" + echo " $0 {userid} [{dir}]" + echo "" + echo "Where:" + echo " {userid} Userid of an administrator for the PyWBEM project at SourceForge." + echo " {dir} Path to the directory that should be published. The files in that" + echo " directory will appear in the root directory of the web site." + echo " Optional, default: $default_dir" + echo "" + echo "The password being prompted is the SourceForge password for {userid}." + echo "" + exit 2 +fi + +echo "Publishing directory $dir" +echo "Use the password for SourceForge userid $userid, below:" +rsync -v -r -l -t --delete $dir $us...@we...:/home/project-web/pywbem/htdocs/ +rc=$? +exit $rc Property changes on: web/publish ___________________________________________________________________ Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Deleted: web/publish-as =================================================================== --- web/publish-as 2015-11-16 13:16:12 UTC (rev 736) +++ web/publish-as 2015-11-16 13:47:44 UTC (rev 737) @@ -1,23 +0,0 @@ -#!/bin/bash -userid=$1 -file=$2 -if [[ -z $file ]] -then - echo "" - echo "Publish one file to the PyWBEM web space at SourceForge." - echo "" - echo "Usage:" - echo " $0 {userid} {file}" - echo "" - echo "Where:" - echo " {userid} is the userid of an administrator for the PyWBEM project at SourceForge." - echo " {file} is the relative file path of the (one) file to be published." - echo "" - echo "The password being asked for is the SourceForge password for {userid}." - echo "" - exit 2 -fi -echo "Publishing (as userid $userid) file: $file" -scp $file $us...@we...:/home/project-web/pywbem/htdocs/$file -rc=$? -exit $rc This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-16 13:16:13
|
Revision: 736 http://sourceforge.net/p/pywbem/code/736 Author: maiera Date: 2015-11-16 13:16:12 +0000 (Mon, 16 Nov 2015) Log Message: ----------- Added identification file for Google search engine. Added Paths: ----------- web/google010a6e7e8b27d104.html Added: web/google010a6e7e8b27d104.html =================================================================== --- web/google010a6e7e8b27d104.html (rev 0) +++ web/google010a6e7e8b27d104.html 2015-11-16 13:16:12 UTC (rev 736) @@ -0,0 +1 @@ +google-site-verification: google010a6e7e8b27d104.html \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-16 13:15:08
|
Revision: 735 http://sourceforge.net/p/pywbem/code/735 Author: maiera Date: 2015-11-16 13:15:06 +0000 (Mon, 16 Nov 2015) Log Message: ----------- Modified all web pages to redirect to the new web presence at pywbem.github.io. Modified Paths: -------------- web/apiref.shtml web/books.shtml web/development.shtml web/documentation.shtml web/examples.shtml web/footer.shtml web/header.shtml web/installation.shtml web/navbar.shtml web/old-news.shtml web/roadmap.shtml web/screenshots.shtml web/tutorial.shtml Modified: web/apiref.shtml =================================================================== --- web/apiref.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/apiref.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,54 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM API Reference</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>API Reference</h2> - -<p>The API reference for the Python WBEM Client is available for the following -versions. Versions marked with "-dev.rNNN" are development snapshots:</p> - -<dl> - <dt>0.8.0-dev.r728</dt> - <dd> - <ul> - <li><a href="docs/apiref/0.8.0-dev.r728/docs/index.html">API reference</a></li> - <li><a href="docs/apiref/0.8.0-dev.r728/NEWS">NEWS file</a></li> - </ul> - </dd> - <dt>0.8.0-dev.r721</dt> - <dd> - <ul> - <li><a href="docs/apiref/0.8.0-dev.r721/docs/index.html">API reference</a></li> - <li><a href="docs/apiref/0.8.0-dev.r721/NEWS">NEWS file</a></li> - </ul> - </dd> -</dl> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Thursday, 22 January 2015 -<!-- hhmts end --> -</p> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/books.shtml =================================================================== --- web/books.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/books.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,43 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Books</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#set var="page" value="books" --> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>Books</h2> - -<p>The following books about WBEM/CIM are available: - -<ul> - <li> <a href="http://www.amazon.com/gp/product/0849323061">A Practical Approach to WBEM/CIM Management</a>, by Chris Hobbs, CRC Press, February 2004.</li> -</ul> - -</p> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Thursday, 1 December 2005 14:28:13 -<!-- hhmts end --> -</p> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/development.shtml =================================================================== --- web/development.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/development.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,74 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Development</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#set var="page" value="development" --> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>Development</h2> - -<p>Development of PyWBEM is a community effort on SourceForge, using this -<a href="https://sourceforge.net/p/pywbem/code/HEAD/tree/">Code Repository</a> -</p> - -<p>The top level directories in the code repository are organized along the -main components of the PyWBEM project:</p> -<ul> - <li><code>pywbem</code> - The Python WBEM Client (the main component).</li> - <li><code>web</code> - Sources for the PyWBEM project web site (this site).</li> - <li><code>yawn</code> - YAWN integration.</li> - <li><code>cimserver</code> - An experimental Python CIM server.</li> - <li><code>pyprovifc</code> - An experimental Python CIM provider interface.</li> -</ul> - -<p>There are two mailing lists:</p> -<ul> - <li><p><a href="https://sourceforge.net/p/pywbem/mailman/pywbem-devel/">pywbem-devel</a> - PyWBEM development related topics</p></li> - <li><p><a href="https://sourceforge.net/p/pywbem/mailman/pywbem-commit/">pywbem-commit</a> - PyWBEM commit messages</p></li> -</ul> - -<p>The <a href="https://sourceforge.net/p/pywbem/bugs/">Bug Tracker</a> is used -for both bugs and features. Anyone can create bugs and features.</p> - -<p>Anyone can provide patches fixing bugs or implementing features. If you do, -please attach the .patch file to the bug tracker entry.</p> - -<p>If you want to get commit rights for the code repository, you need to first -show some engagement in fixing bugs or implementing new features (including -test code) by providing patches. Then, ask one of the project admins.</p> - -<p>How to update the PyWBEM project web site (this site): The web site is not -automatically updated when files are committed to the <code>web</code> -subdirectory of the code repository. They need to be manually updated, by -transferring the files to -<code>US...@we.../home/project-web/pywbem/htdocs</code> -where <code>USERID</code> is the userid of a PyWBEM admin. -You can use any of these protocols: SFTP, SCP, or rsync (for example, -FileZilla). -For details, see -<a href="https://sourceforge.net/p/forge/documentation/Project%20Web%20Services/">SourceForge web hosting</a>. -</p> - -<hr> -<!-- hhmts start --> -Last Modified: Thursday, 22 January 2015 -<!-- hhmts end --> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/documentation.shtml =================================================================== --- web/documentation.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/documentation.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,57 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Documentation</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#set var="page" value="documentation" --> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>Documentation</h2> - -<p>The following documentation is available for the Python WBEM Client:</p> - -<ul> - <li><a href="installation.shtml">Installation</a></li> - <li><a href="tutorial.shtml">Tutorial</a></li> - <li><a href="examples.shtml">Examples</a></li> - <li><a href="apiref.shtml">API Reference</a></li> - <li><a href="docs/examples/MDC2005/MDC2005.ppt">Presentation: Developing WBEM Clients Using Python</a></li> -</ul> - -<p>Presentations about other topics in the overall PyWBEM project:</p> - -<ul> - <li><a href="docs/MDC_2008_Python_Providers.pdf">Presentation: Python CIM Providers with PyWBEM</a></li> -</ul> - -<h3>Other resources</h3> - -<ul> - <li><a href="books.shtml">Books</a></li> -</ul> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Saturday, 11 October 2014 -<!-- hhmts end --> -</p> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/examples.shtml =================================================================== --- web/examples.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/examples.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,56 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Examples</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#set var="page" value="examples" --> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>Examples</h2> - -<p>To help get developers, testers and hackers started with PyWBEM, -there is some example code available to see how the basic functions -operate.</p> - -<ul> - <li>Instance provider API - <ul> - <li><a href="docs/examples/00-connect.py">Making WBEM connections</a> - <li><a href="docs/examples/01-enumerate-instances.py">Enumerate - instances and instance names</a> - <li><a href="docs/examples/02-getinstance.py">Get an instance by name</a> - <li><a href="docs/examples/03-deleteinstance.py">Delete an instance</a> - <li><a href="docs/examples/04-createinstance.py">Create an instance</a> - <li><a href="docs/examples/05-modifyinstance.py">Modify an instance</a> - </ul> - <li> Method provider API - <ul> - <li><a href="docs/examples/06-invokemethod.py">Invoke a method</a> - </ul> -</ul> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Monday, 28 November 2005 15:54:15 -<!-- hhmts end --> -</p> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/footer.shtml =================================================================== --- web/footer.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/footer.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -0,0 +1,18 @@ +<!DOCTYPE html> +<html> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> +<link href="style.css" rel="stylesheet" type="text/css" /> +</head> +<body> + +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> + +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> + +</body> +</html> Modified: web/header.shtml =================================================================== --- web/header.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/header.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1 +1,18 @@ -<h1 align="center">Python WBEM Client</h1> +<!DOCTYPE html> +<html> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> +<link href="style.css" rel="stylesheet" type="text/css" /> +</head> +<body> + +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> + +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> + +</body> +</html> Modified: web/installation.shtml =================================================================== --- web/installation.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/installation.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,86 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Installation</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> -<!--#include virtual="navbar.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<div id="content"> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<h2>Installation</h2> - -<p>PyWBEM can be installed quite easily using the standard Python distutils that -is part of the Python distribution. The source for the installation can be -a copy of the SVN code repository (for example, if you want to get the latest -level of code in development), or a downloaded and unpacked distribution -archive.</p> - -<p>From the pywbem/trunk directory of the copy of the SVN code repository, or -from the unpack directory of the downloaded distribution archive, PyWBEM is -installed with the following shell command. The command syntax is shown for -Linux, but this works the same way on Windows and on other operating systems -supported by Python. This copies the PyWBEM source to the Python -site-packages directory where it can be loaded by the interpreter. On Linux, -you need to have root rights:</p> - -<blockquote><pre> - # python setup.py install - running install - running build - running build_py - running install_lib - copying build/lib/pywbem/cim_xml.py -> /usr/lib/python [...] - [...] -</pre></blockquote> - -<p>If you do not have root access, or would like to install PyWBEM in a -different directory, use the --install-lib option when installing:</p> - -<blockquote><pre> - $ python setup.py install --install-lib $HOME/python/lib - running install - running build - running build_py - running install_lib - creating /home/tpot/python/lib - creating /home/tpot/python/lib/pywbem - copying build/lib/pywbem/cim_xml.py -> /home/tpot/python/lib/pywbem - [...] -</pre></blockquote> - -<p>To test that PyWBEM is sucessfully installed, start up a Python interpreter and -try to import the pywbem module:</p> - -<blockquote><pre> - $ python - Python 2.3.5 (#2, Mar 26 2005, 17:32:32) - [GCC 3.3.5 (Debian 1:3.3.5-12)] on linux2 - Type "help", "copyright", "credits" or "license" for more information. - >>> import pywbem - >>> -</pre></blockquote> - -<p>If you do not see any text after the import command, PyWBEM has been -sucessfully installed.</p> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Saturday, 11 October 2014 -<!-- hhmts end --> -</p> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> </html> Modified: web/navbar.shtml =================================================================== --- web/navbar.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/navbar.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,125 +1,18 @@ -<div id="sidebar"> +<!DOCTYPE html> +<html> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> +<link href="style.css" rel="stylesheet" type="text/css" /> +</head> +<body> -<div style="overflow:auto"> - <div style="width:40px; float:left"> - <img alt="HP logo" src="logo-hp.gif" height="24"> - </div> - <div style="width:10px; float:left"> </div> - <div style="width:40px; float:left"> - <img alt="IBM logo" src="logo-ibm.gif" height="20"> - </div> -</div> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<h4>Project</h4> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<!-- For some reason the space before the closing comment marker is --> -<!-- vitally important on sourceforge.net. It works fine under apache --> -<!-- 2.0 though. --> - -<div class="navitem"> -<!--#if expr="$page = home" --> -Home -<!--#else --> -<a href="index.shtml">Home</a> -<!--#endif --> -</div> - -<div class="navitem"> -<a href="https://sourceforge.net/p/pywbem/news/?source=navbar">Project News</a> -   -<a href="http://sourceforge.net/p/pywbem/news/feed/"><img border="0" alt="RSS" src="RSS.gif"></a> -</div> - -<div class="navitem"> -<a href="http://sourceforge.net/projects/pywbem/files/">Downloads</a> -</div> - -<div class="navitem"> -<!--#if expr="$page = documentation" --> -Documentation -<!--#else --> -<a href="documentation.shtml">Documentation</a> -<!--#endif --> -</div> - -<div class="navitem"> -<a href="https://sourceforge.net/projects/pywbem/support?source=navbar">Support</a> -</div> - -<div class="navitem"> -<a href="https://sourceforge.net/p/pywbem/bugs/?source=navbar">Bugs</a> -</div> - -<div class="navitem"> -<!--#if expr="$page = screenshots" --> -Screenshots -<!--#else --> -<a href="screenshots.shtml">Screenshots</a> -<!--#endif --> -</div> - -<div class="navitem"> -<!--#if expr="$page = roadmap" --> -Roadmap -<!--#else --> -<a href="roadmap.shtml">Roadmap</a> -<!--#endif --> -</div> - -<div class="navitem"> -<!--#if expr="$page = development" --> -Development -<!--#else --> -<a href="development.shtml">Development</a> -<!--#endif --> -</div> - -<p/> - -<h4>Standards</h4> - -<div class="navitem"> -<a href="http://www.dmtf.org/standards/wbem">WBEM</a> -</div> - -<div class="navitem"> -<a href="http://www.dmtf.org/standards/cim">CIM</a> -</div> - -<div class="navitem"> -<a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/wmi_reference.asp">WMI</a> -</div> - -<p/> - -<h4>Related Projects</h4> - -<div class="navitem"> -<a href="http://www.openpegasus.org/">OpenPegasus</a> -</div> - -<div class="navitem"> -<a href="http://sourceforge.net/projects/sblim/files/sblim-sfcb/">SFCB</a> -</div> - -<div class="navitem"> -<a href="http://wbemservices.sourceforge.net/">WBEM Services</a> -</div> - -<div class="navitem"> -<a href="http://openwbem.sourceforge.net/">OpenWBEM</a> -</div> - -<div class="navitem"> -<a href="http://sblim.sourceforge.net/clientapps.html">SBLIM WBEMCLI</a> -</div> - -<p/> - -<h4>Hosted by</h4> - -<div class="navitem"> -<a href="http://sourceforge.net"><img src="http://sourceforge.net/sflogo.php?group_id=133883&type=2" width="125" height="37" border="0" alt="SourceForge.net Logo" /></a> -</div> - -</div> +</body> +</html> Modified: web/old-news.shtml =================================================================== --- web/old-news.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/old-news.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,70 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Old Project News</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>Old Project News</h2> - -<div id="news"> - -<dl> - <dt><b>2005-12-06</b> PyWBEM at Management Developers' Conference 2005. - <dd><p>PyWBEM was the subject of a presentation at the Management Developers' Conference 2005. The presentation and code examples are now available for download at <a href="http://pywbem.sourceforge.net/examples/MDC2005">http://pywbem.sourceforge.net/examples/MDC2005</a>.</p> - - <dt><b>2005-11-30</b> Source code checked in to CVS. - <dd><p>The source for PyWBEM has been checked in to CVS on -SourceForge. Although the code has been available for perusal in the file -releases, it is now more accessible for external development via -SourceForge's anonymous CVS service and CVS web interface.</p> - - <dt><b>2005-11-15</b> PyWBEM 0.4 released - <dd><p>Finally, PyWBEM 0.4 has been released. This release fixes a -couple of bugs found by testers (thanks everyone) as well as a more -usable implementation of the associator provider client functions. -Check the <a -href="https://sourceforge.net/project/shownotes.php?release_id=370987">Release -Notes and ChangeLog</a> information for more details.</p> - - <dt><b>2005-04-28</b> PyWBEM 0.3 released - <dd><p>PyWBEM 0.3 has been released! This is the first public -release of PyWBEM. The main difference between the previous (private) -releases is that PyWBEM now supports extrinsic CIM method calls. Many -small bugfixes have also been made.</p> - - <dt><b>2005-03-14</b> PyWBEM project released as open source - - <dd><p>PyWBEM, a Python library for the Web Based Enterprise -Management protocol, is now available to the general public as a -project on sourceforge.net. Thanks to HP for sponsoring the -development of PyWBEM and allowing it's release under an open source -license, the GNU GPL.</p> - -</dl> - -</div> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Tuesday, 2 January 2007 09:36:33 -<!-- hhmts end --> -</p> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/roadmap.shtml =================================================================== --- web/roadmap.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/roadmap.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,53 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Roadmap</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#set var="page" value="roadmap" --> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>Roadmap</h2> - -<p>The following is a list, in no particular order, of things that -would be nice to be in future versions of PyWBEM:</p> - -<ul> - <li><p>Support for pulled enumeration operations (DSP0200 1.4).</p></li> - <li><p>Improvements on wbemcli command.</p></li> - <li><p>More complete and fully automated test cases, also on Windows - platform(s).</p></li> - <li><p>Better API documentation/reference.</p></li> - <li><p>Update tutorial and add more usage examples.</p></li> - <li><p>WS-Management support.</p></li> - <li><p>Rewrite XML parser to use <tt>xml.sax</tt> instead of <tt>xml.dom</tt> to - avoid resource usage issues when parsing large XML requests and - responses.</p></li> -</ul> - -<p>This list is not regularly maintained. If you have an idea for future -development of PyWBEM, please open a bug in the -<a href="https://sourceforge.net/p/pywbem/bugs/?source=navbar">Bug Tracker</a> -describing the idea.</p> - -<hr> -<!-- hhmts start --> -Last Modified: Thursday, 22 January 2015 -<!-- hhmts end --> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/screenshots.shtml =================================================================== --- web/screenshots.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/screenshots.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,40 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Screenshots</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#set var="page" value="screenshots" --> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>Screenshots</h2> - -<p>Everybody loves screenshots! Here are some great ones of PyWBEM in -action:</p> - -<img alt="screenshot-1" src="screenshot-1.png"> - -</div> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Thursday, 1 December 2005 14:30:48 -<!-- hhmts end --> -</p> - -<!--#include virtual="footer.shtml" --> - </body> - </html> Modified: web/tutorial.shtml =================================================================== --- web/tutorial.shtml 2015-11-12 12:39:46 UTC (rev 734) +++ web/tutorial.shtml 2015-11-16 13:15:06 UTC (rev 735) @@ -1,284 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<title>PyWBEM Tutorial</title> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> +<title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> -<!--#include virtual="navbar.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<div id="content"> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<h2>Tutorial</h2> - -<p>This is a very short tutorial about using PyWBEM until a more -comprehensive one can be written. It is intended to be enough to -get people who know a bit about WBEM and CIM up and going.</p> - -<h3>Making Connections</h3> - -<p>Once PyWBEM has been <a href="installation.shtml">installed</a>, -the next stage is to learn how to -make connections to WBEM servers. Client connection to WBEM servers -are represented by instances of the <tt>WBEMConnection</tt> Python -class.</p> - -<p>Creating a client connection is quite simple. All that is required -is a location URL, a set of credentials. The following code fragment -creates a SSL-encrypted connection to <tt>wbem.example.com</tt> using -a dummy user and dummy password: - -<blockquote><pre>import pywbem -cliconn = pywbem.WBEMConnection('https://wbem.example.com', - ('user', 'password')) -</pre></blockquote> - -</p> - -<p>Note that at the moment there is no persistent TCP connection; the -connectedness is only conceptual. After creating a connection, -various methods may be called on the object, which causes a remote -call to the server. Each method call sets up and tears down a new TCP -connection for every invocation.</p> - -<h3>Python Object and Data Model</h3> - -<p>One of the goals of PyWBEM is to have a understandable, -well-integrated, and easy to use interface to WBEM objects and -operations. This is hopefully achieved by the thoughtful mapping of -CIM objects such as instances, instance names, properties, classes etc -to native Python objects. Ideally there should be no need to worry -about the representation of CIM objects in XML or the wide range of -property types that are defined in the WBEM specifications.</p> - -<h4>CIM Instances and Instance Names</h4> - -<p>The two fundamental objects in PyWBEM are <tt>CIMInstance</tt> and -<tt>CIMInstanceName</tt>. A <tt>CIMInstance</tt> represents a -physical or logcial object that is under management, for example a -disk drive, a temperature sensor or a network card. The most -interesting part of a <tt>CIMInstance</tt> object is the properties -and values those properties take. The properties of a -<tt>CIMInstance</tt> can be accessed by treating the object as a -Python dictionary: - -<blockquote><pre>>>> from pywbem import CIMInstance ->>> i = CIMInstance('CIM_Person') ->>> i['Firstname'] = 'Tim' ->>> i['Lastname'] = 'Potter' ->>> print i.items() -[('Lastname', 'Potter'), ('Firstname', 'Tim')] -</pre></blockquote> - -The keybindings for a <tt>CIMInstanceName</tt> can be treated in a -similar manner.</p> - -<h4>CIM Data Types</h4> - -<p>CIM has a plethora of fixed width integer types that are mapped to -the appropriate Python data types.</p> - -<h3>CIM Instance Commands</h3> - -<p>PyWBEM contains a number of methods to query CIM instance objects. -These methods take Python CIM objects as parameters and return Python -CIM objects as results.</p> - -<p>The following examples are meant to be run, in order, using the -Python interactive interpreter. The interpreter is started up like: - -<blockquote><pre>$ python -Python 2.3.5 (#2, Mar 26 2005, 17:32:32) -[GCC 3.3.5 (Debian 1:3.3.5-12)] on linux2 -Type "help", "copyright", "credits" or "license" for more information. ->>> from pywbem import WBEMConnection ->>> cliconn = pywbem.WBEMConnection('https://wbem.example.com', - ('user', 'password')) -</pre></blockquote> -</p> - -<p>The output of running the various examples has been reformatted for -readability.</p> - -<h4>EnumerateInstances</h4> - -<p>The <tt>EnumerateInstances()</tt> method returns a list of -<tt>CIMNamedInstance</tt> objects which contain the instance name and -instance of for each and every instance of a particular CIM class. The instance name can be accessed using the <tt>name</tt> attribute, and the instance with the <tt>instance</tt> attribute.</p> - -<p>The following script fetches the name of every process running on the -managed node and displays all the details for the first process -returned: - -<blockquote><pre>>>> process_names = cliconn.EnumerateInstances('CIM_Process') ->>> print process_names[0].instance.items() -[(u'Parameters', [u'init']), - (u'CSName', u'nautilus3.asiapacific.cpqcorp.net'), - (u'RealUserID', 0L), - (u'OSName', u'Red Hat Enterprise Linux AS'), - (u'Priority', 15L), - (u'OtherExecutionDescription', None), - (u'ProcessNiceValue', 0L), - (u'Handle', u'1'), - (u'Description', u'init'), - (u'OSCreationClassName', u'CIM_OperatingSystem'), - (u'WorkingSetSize', 0L), - (u'Name', u'init'), - (u'ProcessGroupID', 0L), - (u'ProcessTTY', u'?'), - (u'Caption', u'init'), - (u'ProcessSessionID', 0L), - (u'KernelModeTime', 7651000L), - (u'ParentProcessID', u'0'), - (u'ExecutionState', 6L), - (u'CSCreationClassName', u'CIM_UnitaryComputerSystem'), - (u'UserModeTime', 1000L), - (u'CreationClassName', u'PG_UnixProcess')] -</pre></blockquote> - -<h4>EnumerateInstanceNames</h4> - -<p>The <tt>EnumerateInstanceNames()</tt> method returns a list of -<tt>CIMInstanceName</tt> objects which are the instance names of every -instance of a particular CIM class. We can perform a similar -operation on the list of processes on the managed node as for -<tt>EnumerateInstanceNames()</tt> above: - -<blockquote><pre>>>> processes = cliconn.EnumerateInstanceNames('CIM_Process') ->>> print processes[0].items() -[(u'CSName', u'nautilus3.asiapacific.cpqcorp.net'), - (u'Handle', u'1'), - (u'OSCreationClassName', u'CIM_OperatingSystem'), - (u'CreationClassName', u'PG_UnixProcess'), - (u'CSCreationClassName', u'CIM_UnitaryComputerSystem'), - (u'OSName', u'Red Hat Enterprise Linux AS')] -</blockquote></pre> - -Note that you cannot necessarily assume that the ordering of the -returned results for the <tt>CIM_Process</tt> provider is the same for -enumerating instance names as it is for enumerating instances. We -just happen to be lucky in this case.Also note that the list of -keybindings is a subset of the list of properties displayed above.</p> - -<p>Instance names are required as parameters for most PyWBEM calls as -they uniquely identify a CIM object on the managed node.</p> - -<h4>GetInstance</h4> - -<p>Calling <tt>GetInstance()</tt> returns a <tt>CIMInstance</tt> -object given a <tt>CIMInstanceName</tt>. - -<blockquote><pre>>>> instance = cliconn.GetInstance(process_names[0]) ->>> instance == processes[0] -True -</blockquote></pre> - -(Again we are relying on the fact that the first element of the -<tt>CIM_Process</tt> instance names is the same as the -<tt>CIM_Process</tt> instances).</p> - -<h4>DeleteInstance</h4> - -<p>Some WBEM providers support deletion of managed objects. For -others it makes no sense to do so. The <tt>DeleteInstance()</tt> -method takes a <tt>CIMInstanceName</tt> object and attempts to delete -that object from the repository. - -<blockquote><pre>>>> cliconn.DeleteInstance(process_names[0]) -Traceback (most recent call last): - File "<stdin>", line 1, in ? - File "/data/wbem/python-wbem/trunk/pywbem/cim_operations.py", line 352, in DeleteInstance - InstanceName = instancename, - File "/data/wbem/python-wbem/trunk/pywbem/cim_operations.py", line 198, in imethodcall - raise CIMError(code, tt[1]['DESCRIPTION']) -pywbem.cim_operations.CIMError: (7, u'CIM_ERR_NOT_SUPPORTED: The requested operation is not supported') -</pre></blockquote> -</p> - -<p>Unfortunately the particular <tt>CIM_Process</tt> provider being -queried doesn't support deletion of objects so PyWBEM maps the CIM -error to a Python exception.</p> - -<h4>CreateInstance</h4> - -<p>The creation of a CIM instance on a managed node is acheived by -calling the <tt>CreateInstance()</tt> method. Like -<tt>DeleteInstance</tt> the particular provider being queried may not -support the creation of new objects.</p> - -<p><i>(The <tt>CreateInstance()</tt> method has not been fully implemented -and tested at this stage).</i></p> - -<h4>ModifyInstance</h4> - -<p>Existing CIM instance objects can be modified by having the value -of properties changed. This is achieved using the -<tt>ModifyInstance()</tt> method. It takes a <tt>CIMInstanceName</tt> -parameter which specifies the name of the instance to be modified, and -a <tt>CIMInstance</tt> object which contains only the properties that -are to be changed. Properties not present are not modified. - -<blockquote><pre>>>> i = CIMInstanceName('CIM_Person', {'FirstName': 'Tim', - 'LastName': 'Potter'}) ->>> n = CIMInstance('CIM_Person', {'FirstName': 'Timothy'}) ->>> cliconn.ModifyInstance(i, n) -CIMInstanceName('CIM_Person', {'LastName': 'Potter', 'FirstName': 'Timothy'}) -</pre></blockquote> - -<tt>ModifyInstance()</tt> returns the instance name of the CIM -instance that has been modified.</p> - -<h3>CIM Class Commands</h3> - -<p>PyWBEM contains methods to query CIM class objects, but support for -this has not been fully implemented and tested. For reference, the -relevant method names are: - -<ul> - <li><tt>EnumerateClassNames()</tt></li> - <li><tt>EnumerateClasses()</tt></li> - <li><tt>GetClass()</tt></li> -</ul> - -</p> - -<h3>CIM Method Commands</h3> - -<p>Method invocations are quite easily done. The -<tt>InvokeMethod()</tt> function is called with any parameters required -as Python keyword arguments. - -<h3>CIM Association Commands</h3> - -<p>The support for CIM association commands is basically working, but -not extensively tested. The relevant method names are: - -<ul> - <li><tt>Associators()</tt></li> - <li><tt>AssociatorNames()</tt></li> - <li><tt>References()</tt></li> - <li><tt>ReferenceNames()</tt></li> -</ul> - -</p> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Saturday, 11 October 2014 -<!-- hhmts end --> -</p> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> - </html> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-12 12:39:48
|
Revision: 734 http://sourceforge.net/p/pywbem/code/734 Author: maiera Date: 2015-11-12 12:39:46 +0000 (Thu, 12 Nov 2015) Log Message: ----------- Added publish-as script to remember how to publish. Added Paths: ----------- web/publish-as Added: web/publish-as =================================================================== --- web/publish-as (rev 0) +++ web/publish-as 2015-11-12 12:39:46 UTC (rev 734) @@ -0,0 +1,23 @@ +#!/bin/bash +userid=$1 +file=$2 +if [[ -z $file ]] +then + echo "" + echo "Publish one file to the PyWBEM web space at SourceForge." + echo "" + echo "Usage:" + echo " $0 {userid} {file}" + echo "" + echo "Where:" + echo " {userid} is the userid of an administrator for the PyWBEM project at SourceForge." + echo " {file} is the relative file path of the (one) file to be published." + echo "" + echo "The password being asked for is the SourceForge password for {userid}." + echo "" + exit 2 +fi +echo "Publishing (as userid $userid) file: $file" +scp $file $us...@we...:/home/project-web/pywbem/htdocs/$file +rc=$? +exit $rc Property changes on: web/publish-as ___________________________________________________________________ Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-12 12:39:12
|
Revision: 733 http://sourceforge.net/p/pywbem/code/733 Author: maiera Date: 2015-11-12 12:39:09 +0000 (Thu, 12 Nov 2015) Log Message: ----------- Changed redirection time to 0, making it a permanent redirection for spiders. Modified Paths: -------------- web/index.shtml Modified: web/index.shtml =================================================================== --- web/index.shtml 2015-11-12 12:26:05 UTC (rev 732) +++ web/index.shtml 2015-11-12 12:39:09 UTC (rev 733) @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<meta http-equiv="Refresh" content="5; url=http://pywbem.github.io/" /> +<meta http-equiv="Refresh" content="0; url=http://pywbem.github.io/" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-12 12:26:07
|
Revision: 732 http://sourceforge.net/p/pywbem/code/732 Author: maiera Date: 2015-11-12 12:26:05 +0000 (Thu, 12 Nov 2015) Log Message: ----------- Added robots.txt that disallows any scans. Added Paths: ----------- web/robots.txt Added: web/robots.txt =================================================================== --- web/robots.txt (rev 0) +++ web/robots.txt 2015-11-12 12:26:05 UTC (rev 732) @@ -0,0 +1,2 @@ +User-agent: * +Disallow: / This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-11-12 08:40:16
|
Revision: 731 http://sourceforge.net/p/pywbem/code/731 Author: maiera Date: 2015-11-12 08:40:14 +0000 (Thu, 12 Nov 2015) Log Message: ----------- Redirecting the page to the new location. Modified Paths: -------------- web/index.shtml Added Paths: ----------- web/HOWTO.md Added: web/HOWTO.md =================================================================== --- web/HOWTO.md (rev 0) +++ web/HOWTO.md 2015-11-12 08:40:14 UTC (rev 731) @@ -0,0 +1,13 @@ +How to update the PyWBEM project web site on SourceForge +======================================================== + +That web site is not automatically updated when files are committed to the +`web` subdirectory of the code repository. They need to be manually +updated, by transferring the files to +`US...@we.../home/project-web/pywbem/htdocs` +where `USERID` is the userid of a PyWBEM admin. +You can use any of these protocols: SFTP, SCP, or rsync (for example, +FileZilla). + +For details, see +[SourceForge web hosting](https://sourceforge.net/p/forge/documentation/Project%20Web%20Services/). Modified: web/index.shtml =================================================================== --- web/index.shtml 2015-01-23 00:48:03 UTC (rev 730) +++ web/index.shtml 2015-11-12 08:40:14 UTC (rev 731) @@ -1,63 +1,18 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> - +<!DOCTYPE html> +<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<meta http-equiv="Refresh" content="5; url=http://pywbem.github.io/" /> <title>PyWBEM</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> - <body> -<!--#include virtual="header.shtml" --> +<p>The PyWBEM project has moved. You will be automatically redirected +to the new project page.</p> -<!--#set var="page" value="home" --> -<!--#include virtual="navbar.shtml" --> +<p>If that does not happen within a few seconds, +<a href="http://pywbem.github.io/">click here</a>.</p> -<div id="content"> - -<h2>PyWBEM</h2> - -<p>PyWBEM is a pure-Python library for performing client operations using the -WBEM CIM-XML protocol.</p> - -<h3>Using PyWBEM</h3> - -<ul> - <li><a href="https://sourceforge.net/p/pywbem/news/?source=navbar">Project News</a></li> - <li><a href="https://sourceforge.net/p/pywbem/code/HEAD/tree/pywbem/trunk/pywbem/NEWS">Latest NEWS file in repository</a></li> - <li><a href="http://sourceforge.net/projects/pywbem/files/">Downloads</a></li> - <li><a href="documentation.shtml">Documentation</a></li> - <li><a href="https://sourceforge.net/projects/pywbem/support?source=navbar">Support</a></li> - <li><a href="https://sourceforge.net/p/pywbem/bugs/?source=navbar">Bugs</a></li> - <li><a href="screenshots.shtml">Screenshots</a></li> - <li><a href="roadmap.shtml">Roadmap</a></li> -</ul> - -<h3>Contributing to PyWBEM</h3> - -<ul> - <li><a href="development.shtml">Development</a></li> -</ul> - -<h3>Other resources</h3> - -<ul> - <li><a href="books.shtml">Books</a></li> - <li><a href="old-news.shtml">Old Project News</a></li> -</ul> - -<hr/> - -<p> -<!-- hhmts start --> -Last Modified: Thursday, 22 January 2015 -<!-- hhmts end --> -</p> - -</div> - -<!--#include virtual="footer.shtml" --> - </body> </html> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-23 00:48:11
|
Revision: 730 http://sourceforge.net/p/pywbem/code/730 Author: maiera Date: 2015-01-23 00:48:03 +0000 (Fri, 23 Jan 2015) Log Message: ----------- Updated project web site: Made API reference and NEWS file for preliminary version 0.8.0-dev.r728 available. Revision Links: -------------- http://sourceforge.net/p/pywbem/code/728 Modified Paths: -------------- web/apiref.shtml Modified: web/apiref.shtml =================================================================== --- web/apiref.shtml 2015-01-23 00:24:49 UTC (rev 729) +++ web/apiref.shtml 2015-01-23 00:48:03 UTC (rev 730) @@ -21,6 +21,13 @@ versions. Versions marked with "-dev.rNNN" are development snapshots:</p> <dl> + <dt>0.8.0-dev.r728</dt> + <dd> + <ul> + <li><a href="docs/apiref/0.8.0-dev.r728/docs/index.html">API reference</a></li> + <li><a href="docs/apiref/0.8.0-dev.r728/NEWS">NEWS file</a></li> + </ul> + </dd> <dt>0.8.0-dev.r721</dt> <dd> <ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-23 00:24:57
|
Revision: 729 http://sourceforge.net/p/pywbem/code/729 Author: maiera Date: 2015-01-23 00:24:49 +0000 (Fri, 23 Jan 2015) Log Message: ----------- Released preliminary version 0.8.0-dev.r728 Revision Links: -------------- http://sourceforge.net/p/pywbem/code/728 Added Paths: ----------- pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r728.zip Added: pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r728.zip =================================================================== (Binary files differ) Index: pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r728.zip =================================================================== --- pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r728.zip 2015-01-23 00:22:25 UTC (rev 728) +++ pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r728.zip 2015-01-23 00:24:49 UTC (rev 729) Property changes on: pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r728.zip ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-23 00:22:28
|
Revision: 728 http://sourceforge.net/p/pywbem/code/728 Author: maiera Date: 2015-01-23 00:22:25 +0000 (Fri, 23 Jan 2015) Log Message: ----------- Fixed timeout support added in r727; Added -t TIMEOUT option to test_cim_operations.py; Restructured exceptions raised by WBEMConnections; Added all exceptions that can be raised by WBEMConnections, to the pywbem namespace. Revision Links: -------------- http://sourceforge.net/p/pywbem/code/727 Modified Paths: -------------- pywbem/trunk/pywbem/NEWS pywbem/trunk/pywbem/__init__.py pywbem/trunk/pywbem/cim_http.py pywbem/trunk/pywbem/cim_operations.py pywbem/trunk/testsuite/test_cim_operations.py Modified: pywbem/trunk/pywbem/NEWS =================================================================== --- pywbem/trunk/pywbem/NEWS 2015-01-22 18:21:33 UTC (rev 727) +++ pywbem/trunk/pywbem/NEWS 2015-01-23 00:22:25 UTC (rev 728) @@ -1,4 +1,4 @@ -pywbem-0.8.0-dev.r727 +pywbem-0.8.0-dev.r728 ENHANCEMENTS: @@ -84,7 +84,8 @@ of WBEMConnection class for details. (Andreas Maier) * Added support for timeouts to WBEMConnection, via a new timeout argument, - that defaults to no timeout. (Andreas Maier) + that defaults to no timeout. (This finally increased the minimum version + of Python to 2.6. (Andreas Maier) BUG FIXES: Modified: pywbem/trunk/pywbem/__init__.py =================================================================== --- pywbem/trunk/pywbem/__init__.py 2015-01-22 18:21:33 UTC (rev 727) +++ pywbem/trunk/pywbem/__init__.py 2015-01-23 00:22:25 UTC (rev 728) @@ -133,6 +133,10 @@ PyWBEM has been tested with Python 2.7 on Windows and Linux, and with Python 2.6 on Linux (due to a restriction of the `M2Crypto` package on Windows). +Python 2.6 is the minimum version of Python that is supported. + +Python 3 is not yet supported. + Contributing ------------ @@ -160,8 +164,8 @@ from pywbem.cim_operations import * from pywbem.cim_obj import * from pywbem.tupleparse import ParseError +from pywbem.cim_http import Error, ConnectionError, AuthError, TimeoutError -# TODO: Check if we can bump the minimum Python version to 2.6. import sys -if sys.version_info < (2,3,0): - raise RuntimeError('PyWBEM requires Python 2.3.0 or higher') +if sys.version_info < (2,6,0): + raise RuntimeError('PyWBEM requires Python 2.6.0 or higher') Modified: pywbem/trunk/pywbem/cim_http.py =================================================================== --- pywbem/trunk/pywbem/cim_http.py 2015-01-22 18:21:33 UTC (rev 727) +++ pywbem/trunk/pywbem/cim_http.py 2015-01-23 00:22:25 UTC (rev 728) @@ -49,23 +49,24 @@ from pywbem import cim_obj -__all__ = ['Error', 'AuthError', 'wbem_request', 'get_object_header'] +__all__ = ['Error', 'ConnectionError', 'AuthError', 'TimeoutError', + 'HTTPTimeout', 'wbem_request', 'get_object_header'] class Error(Exception): - """This exception is raised when a transport error occurs.""" + """Exception base class for catching any HTTP transport related errors.""" pass +class ConnectionError(Error): + """This exception is raised when there is a problem with the connection + to the server. A retry may or may not succeed.""" + pass + class AuthError(Error): """This exception is raised when an authentication error (401) occurs.""" pass -class ConnectionError(Error): - """This exception is raised when a connection-related problem occurs, - where a retry might make sense.""" - pass - class TimeoutError(Error): - """This exception is raised when the client timeout is exceeded.""" + """This exception is raised when the client times out.""" pass class HTTPTimeout (object): @@ -97,13 +98,14 @@ self._timeout = timeout self._http_conn = http_conn - self._retrytime = 10 # time in seconds after which a retry of the + self._retrytime = 5 # time in seconds after which a retry of the # socket shutdown is scheduled if the socket # is not yet on the connection when the # timeout expires initially. - self._timer = None - self._ts1 = None - self._expired = None + self._timer = None # the timer object + self._ts1 = None # timestamp when timer was started + self._shutdown = None # flag indicating that the timer handler has + # shut down the socket return def __enter__(self): @@ -112,40 +114,44 @@ HTTPTimeout.timer_expired, [self]) self._timer.start() self._ts1 = datetime.now() - self._expired = False + self._shutdown = False return def __exit__(self, exc_type, exc_value, traceback): if self._timeout != None: self._timer.cancel() - if self._expired: + if self._shutdown: + # If the timer handler has shut down the socket, we + # want to make that known, and override any other + # exceptions that may be pending. ts2 = datetime.now() duration = ts2 - self._ts1 duration_sec = float(duration.microseconds)/1000000 +\ duration.seconds + duration.days*24*3600 - raise TimeoutError("Timeout error: Client timed out after "\ - "%.0fs." % duration_sec) + raise TimeoutError("The client timed out and closed the "\ + "socket after %.0fs." % duration_sec) return False # re-raise any other exceptions def timer_expired(self): """ This method is invoked in context of the timer thread, so we cannot directly throw exceptions (we can, but they would be in the wrong - thread), so instead we cause the socket of the connection to shut down. + thread), so instead we shut down the socket of the connection. + When the timeout happens in early phases of the connection setup, + there is no socket object on the HTTP connection yet, in that case + we retry after the retry duration, indefinitely. + So we do not guarantee in all cases that the overall operation times + out after the specified timeout. """ - self._expired = True if self._http_conn.sock != None: - # Timer expired, shutting down socket of HTTP connection. + self._shutdown = True self._http_conn.sock.shutdown(socket.SHUT_RDWR) else: - # Timer expired, no socket yet on HTTP connection to shut down, - # so we retry. This should only happen with very short timeouts, - # so retrying should not hurt, timewise. + # Retry after the retry duration self._timer.cancel() self._timer = threading.Timer(self._retrytime, HTTPTimeout.timer_expired, [self]) self._timer.start() - return def parse_url(url): """Return a tuple of ``(host, port, ssl)`` from the URL specified in the @@ -302,14 +308,17 @@ A value of ``None`` means there is no timeout. A value of ``0`` means the timeout is very short, and does not really make any sense. + Note that not all situations can be handled within this timeout, so + for some issues, this method may take longer to raise an exception. :Returns: The CIM-XML formatted response data from the WBEM server, as a `unicode` object. :Raises: - :raise Error: :raise AuthError: + :raise ConnectionError: + :raise TimeoutError: """ class HTTPBaseConnection: @@ -329,12 +338,13 @@ self.sock.sendall(str) class HTTPConnection(HTTPBaseConnection, httplib.HTTPConnection): - def __init__(self, host, port=None, strict=None): + def __init__(self, host, port=None, strict=None, timeout=None): httplib.HTTPConnection.__init__(self, host, port, strict, timeout) class HTTPSConnection(HTTPBaseConnection, httplib.HTTPSConnection): def __init__(self, host, port=None, key_file=None, cert_file=None, - strict=None, ca_certs=None, verify_callback=None): + strict=None, ca_certs=None, verify_callback=None, + timeout=None): httplib.HTTPSConnection.__init__(self, host, port, key_file, cert_file, strict, timeout) self.ca_certs = ca_certs @@ -345,14 +355,18 @@ # Calling httplib.HTTPSConnection.connect(self) does not work # because of its ssl.wrap_socket() call. So we copy the code of - # that connect() method modulo the ssl.wrap_socket() call: - if sys.version_info[0:2] == [2, 7]: - self.sock = socket.create_connection((self.host, self.port), - self.timeout, - self.source_address) - else: # 2.6 - self.sock = socket.create_connection((self.host, self.port), - self.timeout) + # that connect() method modulo the ssl.wrap_socket() call. + # + # Another change is that we do not pass the timeout value + # on to the socket call, because that does not work with M2Crypto. + if sys.version_info[0:2] >= (2, 7): + # the source_address argument was added in 2.7 + self.sock = socket.create_connection( + (self.host, self.port), None, self.source_address) + else: + self.sock = socket.create_connection( + (self.host, self.port), None) + if self._tunnel_host: self._tunnel() # End of code from httplib.HTTPSConnection.connect(self). @@ -373,6 +387,20 @@ # Below is a body of SSL.Connection.connect() method # except for the first line (socket connection). We want to # preserve tunneling ability. + + # Setting the timeout on the input socket does not work + # with M2Crypto, with such a timeout set it calls a different + # low level function (nbio instead of bio) that does not work. + # the symptom is that reading the response returns None. + # Therefore, we set the timeout at the level of the outer + # M2Crypto socket object. + if False: # Currently disabled + if self.timeout is not None: + self.sock.set_socket_read_timeout( + SSL.timeout(self.timeout)) + self.sock.set_socket_write_timeout( + SSL.timeout(self.timeout)) + self.sock.addr = (self.host, self.port) self.sock.setup_ssl() self.sock.set_connect_state() @@ -382,12 +410,13 @@ self.sock.clientPostConnectionCheck) if check is not None: if not check(self.sock.get_peer_cert(), self.host): - raise Error('SSL error: post connection check '\ - 'failed') + raise ConnectionError( + 'SSL error: post connection check failed') return ret except (Err.SSLError, SSL.SSLError, SSL.Checker.WrongHost), arg: # This will include SSLTimeoutError (it subclasses SSLError) - raise Error("SSL error %s: %s" % (str(arg.__class__), arg)) + raise ConnectionError( + "SSL error %s: %s" % (str(arg.__class__), arg)) class FileHTTPConnection(HTTPBaseConnection, httplib.HTTPConnection): @@ -399,8 +428,9 @@ try: socket_af = socket.AF_UNIX except AttributeError: - raise Error('file URL not supported on %s platform due '\ - 'to missing AF_UNIX support' % platform.system()) + raise ConnectionError( + 'file URLs not supported on %s platform due '\ + 'to missing AF_UNIX support' % platform.system()) self.sock = socket.socket(socket_af, socket.SOCK_STREAM) self.sock.connect(self.uds_path) @@ -447,16 +477,16 @@ timeout=timeout) else: if url.startswith('file:'): - url = url[5:] + url_ = url[5:] try: - s = os.stat(url) + s = os.stat(url_) if S_ISSOCK(s.st_mode): - h = FileHTTPConnection(url) + h = FileHTTPConnection(url_) local = True else: - raise Error('Invalid URL: %s' % url) - except OSError: - raise Error('Invalid URL: %s' % url) + raise ConnectionError('File URL is not a socket: %s' % url) + except OSError as exc: + raise ConnectionError('Error with file URL %s: %s' % (url, exc)) locallogin = None if host in ('localhost', 'localhost6', '127.0.0.1', '::1'): @@ -505,12 +535,16 @@ # to our fixed HTTPConnection classes, we'll still be able to # retrieve the response so that we can read and respond to the # authentication challenge. - h.endheaders() + try: + # endheaders() is the first method in this sequence that + # actually sends something to the server. + h.endheaders() h.send(data) - except socket.error, arg: - if arg[0] != 104 and arg[0] != 32: - raise + except socket.error as exc: + # TODO: Verify these errno numbers on Windows vs. Linux + if exc[0] != 104 and exc[0] != 32: + raise ConnectionError("Socket error: %s" % exc) response = h.getresponse() @@ -526,10 +560,11 @@ try: uid = os.getuid() except AttributeError: - raise Error("OWLocal authorization for "\ - "openwbem server not supported "\ - "on %s platform due to missing "\ - "os.getuid()" % platform.system()) + raise ConnectionError( + "OWLocal authorization for OpenWbem "\ + "server not supported on %s platform "\ + "due to missing os.getuid()" %\ + platform.system()) localAuthHeader = ('Authorization', 'OWLocal uid="%d"' % uid) continue @@ -570,47 +605,45 @@ continue except ValueError: pass - raise AuthError(response.reason) - if response.getheader('CIMError', None) is not None and \ - response.getheader('PGErrorDetail', None) is not None: - raise Error( - 'CIMError: %s: %s' % - (response.getheader('CIMError'), - urllib.unquote(response.getheader( - 'PGErrorDetail')))) - raise Error('HTTP error: %s' % response.reason) + cimerror_hdr = response.getheader('CIMError', None) + if cimerror_hdr is not None: + exc_str = 'CIMError: %s' % cimerror_hdr + pgerrordetail_hdr = response.getheader('PGErrorDetail', + None) + if pgerrordetail_hdr is not None: + exc_str += ', PGErrorDetail: %s' %\ + urllib.unquote(pgerrordetail_hdr) + raise ConnectionError(exc_str) + + raise ConnectionError('HTTP error: %s' % response.reason) + body = response.read() - except httplib.BadStatusLine, arg: + except httplib.BadStatusLine as exc: # Background: BadStatusLine is documented to be raised only # when strict=True is used (that is not the case here). # However, httplib currently raises BadStatusLine also # independent of strict when a keep-alive connection times out # (e.g. because the server went down). # See http://bugs.python.org/issue8450. - # On how to detect this: A connection timeout definitely causes - # arg==None, but it is not clear whether other situations could - # also cause arg==None. - if arg.line.strip().strip("'") == '': - raise ConnectionError("Connection error: The CIM server "\ - "closed the connection without "\ - "returning any data, or the client "\ - "timed out") + if exc.line is None or exc.line.strip().strip("'") in \ + ('', 'None'): + raise ConnectionError("The server closed the "\ + "connection without returning any data, or the "\ + "client timed out") else: - raise Error("HTTP error: The CIM server returned a bad "\ - "HTTP status line: '%s'" % arg.line) - except httplib.IncompleteRead, arg: - raise ConnectionError("Connection error: HTTP incomplete "\ - "read: %s" % arg) - except httplib.NotConnected, arg: - raise ConnectionError("Connection error: HTTP not "\ - "connected: %s" % arg) - except socket.error, arg: - raise ConnectionError("Connection error: Socket error %s" %arg) - except socket.sslerror, arg: - raise ConnectionError("Connection error: SSL error %s" % arg) + raise ConnectionError("The server returned a bad "\ + "HTTP status line: %r" % exc.line) + except httplib.IncompleteRead as exc: + raise ConnectionError("HTTP incomplete read: %s" % exc) + except httplib.NotConnected as exc: + raise ConnectionError("HTTP not connected: %s" % exc) + except socket.error as exc: + raise ConnectionError("Socket error: %s" % exc) + except socket.sslerror as exc: + raise ConnectionError("SSL error: %s" % exc) break Modified: pywbem/trunk/pywbem/cim_operations.py =================================================================== --- pywbem/trunk/pywbem/cim_operations.py 2015-01-22 18:21:33 UTC (rev 727) +++ pywbem/trunk/pywbem/cim_operations.py 2015-01-23 00:22:25 UTC (rev 728) @@ -191,7 +191,7 @@ cpos1 = max(ic_pos-context_before,0) cpos2 = min(ic_pos+context_after,len(utf8_xml)) exc_txt += ", CIM-XML snippet: %r" % utf8_xml[cpos1:cpos2] - raise tupleparse.ParseError(exc_txt) + raise ParseError(exc_txt) # Check for incorrectly encoded UTF-8 sequences. # @ibm.13@ Simplified logic (removed loop). @@ -213,7 +213,7 @@ cpos1 = max(_p1-context_before,0) cpos2 = min(_p2+context_after,len(utf8_xml)) exc_txt += ", CIM-XML snippet: %r" % utf8_xml[cpos1:cpos2] - raise tupleparse.ParseError(exc_txt) + raise ParseError(exc_txt) # Now we know the Unicode characters are valid. # Check for Unicode characters that cannot legally be represented as XML @@ -233,53 +233,31 @@ cpos2 = min(ic_pos+context_after,len(utf8_xml_u)) exc_txt += "\n At offset %d: U+%04X, CIM-XML snippet: %r" % \ (ic_pos, ord(ic_char), utf8_xml_u[cpos1:cpos2]) - raise tupleparse.ParseError(exc_txt) + raise ParseError(exc_txt) return utf8_xml -class CIMError(Exception): +class CIMError(cim_http.Error): """ - Exception indicating that either the WBEM server has returned an error or - the response from the WBEM server has some issue. + Exception indicating that the WBEM server has returned an error response + with a CIM status code. The exception value is a tuple of ``(error_code, description, exception_obj)``, where: - * ``error_code``: a numeric error code. See below for details. + * ``error_code``: the numeric CIM status code. See `cim_constants` for + constants defining CIM status code values. * ``description``: a string (`unicode` or UTF-8 encoded `str`) - representing a human readable message describing the error. See below - for details. + that is the CIM status description text returned by the server, + representing a human readable message describing the error. * ``exception_obj``: the underlying exception object that caused this - exception to be raised. See below for details. - - An ``error_code`` value other than 0 indicates that the WBEM server has - returned an error response, and ``error_code`` is the CIM status code of - the error response. See `cim_constants` for constants defining CIM status - code values. In this case, ``description`` is the CIM status description - text returned by the server, and ``exception_obj`` is ``None``. - - An ``error_code`` value of 0 indicates an error detected in the PyWBEM - client after receiving the response returned by the WBEM server (for - example, an XML parsing error). In this case, ``exception_obj`` is another - exception object describing the error, and ``description`` is the - string representation of the error message of that other exception object. - The following other exception objects are used: - - * `cim_http.AuthError`: Authentication error (HTTP status 401). - * `cim_http.ConnectionError`: Problem with the connection to the server, - a retry sometimes later would make sense. - * `cim_http.TimeoutError`: Client timeout occurred. - * `tupleparse.ParseError`: CIM-XML parsing issue. - * `cim_http.Error`: Other low level error (e.g. HTTP error, CIMError - HTTP header). This exception is a base class for `cim_http.AuthError`, - `cim_http.ConnectionError`, and `cim_http.TimeoutError` and thus must - be handled at the end. + exception to be raised, or ``None``. Will always be ``None``. """ + pass - class WBEMConnection(object): """ A client's connection to a WBEM server. This is the main class of the @@ -321,44 +299,30 @@ * Exceptions indicating processing errors: - - `pywbem.Error` - HTTP transport error. + - `pywbem.ConnectionError` - A connection with the WBEM server could not + be established or broke down. - `pywbem.AuthError` - Authentication failed with the WBEM server. - - `pywbem.CIMError` - CIM error. + - `pywbem.ParseError` - The response from the WBEM server cannot be + parsed (for example, invalid characters or UTF-8 sequences, ill-formed + XML, or invalid CIM-XML). - With an ``error_code`` value of 0, the reason is one of: + - `pywbem.CIMError` - The WBEM server returned an error response with a + CIM status code. - * Error in the arguments of a method. - * Connection problem with the WBEM server. - * HTTP-level errors reported by the WBEM server (except for HTTP - transport errors and authentication failures). + - `pywbem.TimeoutError` - The WBEM server did not respond in time and the + client timed out. - With other ``error_code`` values, the reason is always that the - operation invoked on the WBEM server failed and returned a CIM error. - For the possible CIM errors that can be returned by each operation, see - DMTF DSP0200. + * Exceptions indicating programming errors: - - `pywbem.ParseError` - CIM-XML parsing problem in the response from - the WBEM server. The exception message provides details. - Possible reasons are: - - * Response contains ill-formed UTF-8 Byte sequences (uses surrogates). - * Response contains incorrectly encoded UTF-8 Byte sequences. - * Response contains invalid XML characters (e.g. ``\\x00`` or - ``�``). - * Response is not well-formed XML. - * Response does not validate against the CIM-XML DTD/schema. - - * Exceptions indicating programming errors in PyWBEM or layers below: - - `TypeError` - `KeyError` - `ValueError` - ... possibly others ... Exceptions indicating programming errors should not happen and should be - reported as bugs. + reported as bugs, unless caused by the code using this class. :Ivariables: @@ -516,10 +480,16 @@ Timeout in seconds, for requests sent to the server. If the server did not respond within the timeout duration, the socket for the connection will be closed, causing a `TimeoutError` to be raised. + A value of ``None`` means there is no timeout. + A value of ``0`` means the timeout is very short, and does not really make any sense. + Note that not all situations can be handled within this timeout, so + for some issues, operations may take longer before raising an + exception. + :Exceptions: See the list of exceptions described in `WBEMConnection`. @@ -621,8 +591,8 @@ no_verification=self.no_verification, timeout=self.timeout) except (cim_http.AuthError, cim_http.ConnectionError, - cim_http.TimeoutError, cim_http.Error) as exc: - raise CIMError(0, str(exc), exc) + cim_http.TimeoutError, cim_http.Error): + raise # Set the raw response before parsing (which can fail) if self.debug: @@ -651,13 +621,13 @@ # we call it also when debug is turned on. try: check_utf8_xml_chars(reply_xml, "CIM-XML response") - except ParseError as exc2: - raise CIMError(0, str(exc2), exc2) + except ParseError: + raise else: if parsing_error: # We did not catch it in the check function, but # minidom.parseString() failed. - raise CIMError(0, msg, exc) # data from previous exception + raise ParseError(msg) # data from previous exception if self.debug: pretty_reply = reply_dom.toprettyxml(indent=' ') @@ -669,29 +639,24 @@ tt = tupleparse.parse_cim(tupletree.dom_to_tupletree(reply_dom)) if tt[0] != 'CIM': - exc = ParseError('Expecting CIM element, got %s' % tt[0]) - raise CIMError(0, str(exc), exc) + raise ParseError('Expecting CIM element, got %s' % tt[0]) tt = tt[2] if tt[0] != 'MESSAGE': - exc = ParseError('Expecting MESSAGE element, got %s' % tt[0]) - raise CIMError(0, str(exc), exc) + raise ParseError('Expecting MESSAGE element, got %s' % tt[0]) tt = tt[2] if len(tt) != 1 or tt[0][0] != 'SIMPLERSP': - exc = ParseError('Expecting one SIMPLERSP element') - raise CIMError(0, str(exc), exc) + raise ParseError('Expecting one SIMPLERSP element') tt = tt[0][2] if tt[0] != 'IMETHODRESPONSE': - exc = ParseError('Expecting IMETHODRESPONSE element, got %s' %\ + raise ParseError('Expecting IMETHODRESPONSE element, got %s' %\ tt[0]) - raise CIMError(0, str(exc), exc) if tt[1]['NAME'] != methodname: - exc = ParseError('Expecting attribute NAME=%s, got %s' %\ + raise ParseError('Expecting attribute NAME=%s, got %s' %\ (methodname, tt[1]['NAME'])) - raise CIMError(0, str(exc), exc) tt = tt[2] # At this point we either have a IRETURNVALUE, ERROR element @@ -708,8 +673,7 @@ raise CIMError(code, 'Error code %s' % tt[1]['CODE']) if tt[0] != 'IRETURNVALUE': - exc = ParseError('Expecting IRETURNVALUE element, got %s' % tt[0]) - raise CIMError(0, str(exc), exc) + raise ParseError('Expecting IRETURNVALUE element, got %s' % tt[0]) return tt @@ -838,8 +802,8 @@ no_verification=self.no_verification, timeout=self.timeout) except (cim_http.AuthError, cim_http.ConnectionError, - cim_http.TimeoutError, cim_http.Error) as exc: - raise CIMError(0, str(exc), exc) + cim_http.TimeoutError, cim_http.Error): + raise # Set the raw response before parsing and checking (which can fail) if self.debug: @@ -868,13 +832,13 @@ # we call it also when debug is turned on. try: check_utf8_xml_chars(reply_xml, "CIM-XML response") - except ParseError as exc2: - raise CIMError(0, str(exc2), exc2) + except ParseError: + raise else: if parsing_error: # We did not catch it in the check function, but # minidom.parseString() failed. - raise CIMError(0, msg, exc) # data from previous exception + raise ParseError(msg) # data from previous exception if self.debug: pretty_reply = reply_dom.toprettyxml(indent=' ') @@ -886,29 +850,24 @@ tt = tupleparse.parse_cim(tupletree.dom_to_tupletree(reply_dom)) if tt[0] != 'CIM': - exc = ParseError('Expecting CIM element, got %s' % tt[0]) - raise CIMError(0, str(exc), exc) + raise ParseError('Expecting CIM element, got %s' % tt[0]) tt = tt[2] if tt[0] != 'MESSAGE': - exc = ParseError('Expecting MESSAGE element, got %s' % tt[0]) - raise CIMError(0, str(exc), exc) + raise ParseError('Expecting MESSAGE element, got %s' % tt[0]) tt = tt[2] if len(tt) != 1 or tt[0][0] != 'SIMPLERSP': - exc = ParseError('Expecting one SIMPLERSP element') - raise CIMError(0, str(exc), exc) + raise ParseError('Expecting one SIMPLERSP element') tt = tt[0][2] if tt[0] != 'METHODRESPONSE': - exc = ParseError('Expecting METHODRESPONSE element, got %s' %\ + raise ParseError('Expecting METHODRESPONSE element, got %s' %\ tt[0]) - raise CIMError(0, str(exc), exc) if tt[1]['NAME'] != methodname: - exc = ParseError('Expecting attribute NAME=%s, got %s' %\ + raise ParseError('Expecting attribute NAME=%s, got %s' %\ (methodname, tt[1]['NAME'])) - raise CIMError(0, str(exc), exc) tt = tt[2] # At this point we have an optional RETURNVALUE and zero or Modified: pywbem/trunk/testsuite/test_cim_operations.py =================================================================== --- pywbem/trunk/testsuite/test_cim_operations.py 2015-01-22 18:21:33 UTC (rev 727) +++ pywbem/trunk/testsuite/test_cim_operations.py 2015-01-23 00:22:25 UTC (rev 728) @@ -32,14 +32,14 @@ def setup(self): """Create a connection.""" + global url, username, password, namespace, timeout - # Use globals url, username and password - self.system_url = url self.conn = WBEMConnection( self.system_url, (username, password), - namespace) + namespace, + timeout=timeout) self.conn.debug = True def cimcall(self, fn, *args, **kw): @@ -791,7 +791,8 @@ if __name__ == '__main__': if len(sys.argv) < 2: - print 'Usage for manual external tests:\n %s [OPTS] URL [USERNAME%%PASSWORD [COMFYOPTS] '\ + print 'Usage for manual external tests:\n'\ + ' %s [OPTS] URL [USERNAME%%PASSWORD [COMFYOPTS] '\ '[COMFYTESTS]]' % sys.argv[0] print 'Invoke with -h or --help for full help text.' print 'Running internal tests...' @@ -821,6 +822,8 @@ print ' --help, -h Display this help text.' print ' -n NAMESPACE Use this CIM namespace instead of '\ 'default: %s' % DEFAULT_NAMESPACE + print ' -t TIMEOUT Use this timeout (in seconds) instead '\ + 'of no timeout' print '' print 'Comfychair help:' print '' @@ -834,6 +837,7 @@ sys.exit(0) namespace = DEFAULT_NAMESPACE + timeout = None while (True): if sys.argv[1][0] != '-': # Stop at first non-option @@ -841,6 +845,9 @@ if sys.argv[1] == '-n': namespace = sys.argv[2] del sys.argv[1:3] + elif sys.argv[1] == '-t': + timeout = int(sys.argv[2]) + del sys.argv[1:3] else: print "Error: Unknown option: %s" % sys.argv[1] sys.exit(1) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-22 18:21:35
|
Revision: 727 http://sourceforge.net/p/pywbem/code/727 Author: maiera Date: 2015-01-22 18:21:33 +0000 (Thu, 22 Jan 2015) Log Message: ----------- Fixed bug 34: Added proper timeout support. Modified Paths: -------------- pywbem/trunk/pywbem/NEWS pywbem/trunk/pywbem/cim_http.py pywbem/trunk/pywbem/cim_operations.py Modified: pywbem/trunk/pywbem/NEWS =================================================================== --- pywbem/trunk/pywbem/NEWS 2015-01-22 13:19:25 UTC (rev 726) +++ pywbem/trunk/pywbem/NEWS 2015-01-22 18:21:33 UTC (rev 727) @@ -1,4 +1,4 @@ -pywbem-0.8.0-dev.r721 +pywbem-0.8.0-dev.r727 ENHANCEMENTS: @@ -83,6 +83,9 @@ and improved the information in the exception messages. See description of WBEMConnection class for details. (Andreas Maier) + * Added support for timeouts to WBEMConnection, via a new timeout argument, + that defaults to no timeout. (Andreas Maier) + BUG FIXES: * Fix syntax error in CIM DTDVERSION error path. Allow KEYVALUE Modified: pywbem/trunk/pywbem/cim_http.py =================================================================== --- pywbem/trunk/pywbem/cim_http.py 2015-01-22 13:19:25 UTC (rev 726) +++ pywbem/trunk/pywbem/cim_http.py 2015-01-22 18:21:33 UTC (rev 727) @@ -42,6 +42,8 @@ import httplib import base64 import urllib +import threading +from datetime import timedelta, datetime from M2Crypto import SSL, Err @@ -66,6 +68,85 @@ """This exception is raised when the client timeout is exceeded.""" pass +class HTTPTimeout (object): + """HTTP timeout class that is a context manager (for use by 'with' + statement). + + Usage: + :: + with HTTPTimeout(timeout, http_conn): + ... operations using http_conn ... + + If the timeout expires, the socket of the HTTP connection is shut down. + Once the http operations return as a result of that or for other reasons, + the exit handler of this class raises a `cim_http.Error` exception in the + thread that executed the ``with`` statement. + """ + + def __init__(self, timeout, http_conn): + """Initialize the HTTPTimeout object. + + :Parameters: + + timeout : number + Timeout in seconds, ``None`` means no timeout. + + http_conn : `httplib.HTTPBaseConnection` (or subclass) + The connection that is to be stopped when the timeout expires. + """ + + self._timeout = timeout + self._http_conn = http_conn + self._retrytime = 10 # time in seconds after which a retry of the + # socket shutdown is scheduled if the socket + # is not yet on the connection when the + # timeout expires initially. + self._timer = None + self._ts1 = None + self._expired = None + return + + def __enter__(self): + if self._timeout != None: + self._timer = threading.Timer(self._timeout, + HTTPTimeout.timer_expired, [self]) + self._timer.start() + self._ts1 = datetime.now() + self._expired = False + return + + def __exit__(self, exc_type, exc_value, traceback): + if self._timeout != None: + self._timer.cancel() + if self._expired: + ts2 = datetime.now() + duration = ts2 - self._ts1 + duration_sec = float(duration.microseconds)/1000000 +\ + duration.seconds + duration.days*24*3600 + raise TimeoutError("Timeout error: Client timed out after "\ + "%.0fs." % duration_sec) + return False # re-raise any other exceptions + + def timer_expired(self): + """ + This method is invoked in context of the timer thread, so we cannot + directly throw exceptions (we can, but they would be in the wrong + thread), so instead we cause the socket of the connection to shut down. + """ + self._expired = True + if self._http_conn.sock != None: + # Timer expired, shutting down socket of HTTP connection. + self._http_conn.sock.shutdown(socket.SHUT_RDWR) + else: + # Timer expired, no socket yet on HTTP connection to shut down, + # so we retry. This should only happen with very short timeouts, + # so retrying should not hurt, timewise. + self._timer.cancel() + self._timer = threading.Timer(self._retrytime, + HTTPTimeout.timer_expired, [self]) + self._timer.start() + return + def parse_url(url): """Return a tuple of ``(host, port, ssl)`` from the URL specified in the ``url`` parameter. @@ -164,7 +245,7 @@ def wbem_request(url, data, creds, headers=[], debug=0, x509=None, verify_callback=None, ca_certs=None, - no_verification=False): + no_verification=False, timeout=None): """ Send an HTTP or HTTPS request to a WBEM server and return the response. @@ -214,6 +295,14 @@ For details, see the ``no_verification`` parameter of `WBEMConnection.__init__`. + timeout : number + Timeout in seconds, for requests sent to the server. If the server did + not respond within the timeout duration, the socket for the connection + will be closed, causing a `TimeoutError` to be raised. + A value of ``None`` means there is no timeout. + A value of ``0`` means the timeout is very short, and does not really + make any sense. + :Returns: The CIM-XML formatted response data from the WBEM server, as a `unicode` object. @@ -241,13 +330,13 @@ class HTTPConnection(HTTPBaseConnection, httplib.HTTPConnection): def __init__(self, host, port=None, strict=None): - httplib.HTTPConnection.__init__(self, host, port, strict) + httplib.HTTPConnection.__init__(self, host, port, strict, timeout) class HTTPSConnection(HTTPBaseConnection, httplib.HTTPSConnection): def __init__(self, host, port=None, key_file=None, cert_file=None, strict=None, ca_certs=None, verify_callback=None): httplib.HTTPSConnection.__init__(self, host, port, key_file, - cert_file, strict) + cert_file, strict, timeout) self.ca_certs = ca_certs self.verify_callback = verify_callback @@ -349,10 +438,13 @@ key_file=key_file, cert_file=cert_file, ca_certs=ca_certs, - verify_callback=verify_callback) + verify_callback=verify_callback, + timeout=timeout) else: if url.startswith('http'): - h = HTTPConnection(host, port=port) + h = HTTPConnection(host, + port=port, + timeout=timeout) else: if url.startswith('file:'): url = url[5:] @@ -374,146 +466,153 @@ locallogin = getpass.getuser() except (KeyError, ImportError): locallogin = None - while numTries < tryLimit: - numTries = numTries + 1 - h.putrequest('POST', '/cimom') + with HTTPTimeout(timeout, h): - h.putheader('Content-type', 'application/xml; charset="utf-8"') - h.putheader('Content-length', str(len(data))) - if localAuthHeader is not None: - h.putheader(*localAuthHeader) - elif creds is not None: - h.putheader('Authorization', 'Basic %s' % - base64.encodestring( - '%s:%s' % - (creds[0], creds[1])).replace('\n', '')) - elif locallogin is not None: - h.putheader('PegasusAuthorization', 'Local "%s"' % locallogin) + while numTries < tryLimit: + numTries = numTries + 1 - for hdr in headers: - if isinstance(hdr, unicode): - hdr = hdr.encode('utf-8') - s = map(lambda x: string.strip(x), string.split(hdr, ":", 1)) - h.putheader(urllib.quote(s[0]), urllib.quote(s[1])) + h.putrequest('POST', '/cimom') - try: - # See RFC 2616 section 8.2.2 - # An http server is allowed to send back an error (presumably - # a 401), and close the connection without reading the entire - # request. A server may do this to protect itself from a DoS - # attack. - # - # If the server closes the connection during our h.send(), we - # will either get a socket exception 104 (TCP RESET), or a - # socket exception 32 (broken pipe). In either case, thanks - # to our fixed HTTPConnection classes, we'll still be able to - # retrieve the response so that we can read and respond to the - # authentication challenge. - h.endheaders() + h.putheader('Content-type', 'application/xml; charset="utf-8"') + h.putheader('Content-length', str(len(data))) + if localAuthHeader is not None: + h.putheader(*localAuthHeader) + elif creds is not None: + h.putheader('Authorization', 'Basic %s' % + base64.encodestring( + '%s:%s' % + (creds[0], creds[1])).replace('\n', '')) + elif locallogin is not None: + h.putheader('PegasusAuthorization', 'Local "%s"' % locallogin) + + for hdr in headers: + if isinstance(hdr, unicode): + hdr = hdr.encode('utf-8') + s = map(lambda x: string.strip(x), string.split(hdr, ":", 1)) + h.putheader(urllib.quote(s[0]), urllib.quote(s[1])) + try: - h.send(data) - except socket.error, arg: - if arg[0] != 104 and arg[0] != 32: - raise + # See RFC 2616 section 8.2.2 + # An http server is allowed to send back an error (presumably + # a 401), and close the connection without reading the entire + # request. A server may do this to protect itself from a DoS + # attack. + # + # If the server closes the connection during our h.send(), we + # will either get a socket exception 104 (TCP RESET), or a + # socket exception 32 (broken pipe). In either case, thanks + # to our fixed HTTPConnection classes, we'll still be able to + # retrieve the response so that we can read and respond to the + # authentication challenge. + h.endheaders() + try: + h.send(data) + except socket.error, arg: + if arg[0] != 104 and arg[0] != 32: + raise - response = h.getresponse() + response = h.getresponse() - if response.status != 200: - if response.status == 401: - if numTries >= tryLimit: - raise AuthError(response.reason) - if not local: - raise AuthError(response.reason) - authChal = response.getheader('WWW-Authenticate', '') - if 'openwbem' in response.getheader('Server', ''): - if 'OWLocal' not in authChal: + if response.status != 200: + if response.status == 401: + if numTries >= tryLimit: + raise AuthError(response.reason) + if not local: + raise AuthError(response.reason) + authChal = response.getheader('WWW-Authenticate', '') + if 'openwbem' in response.getheader('Server', ''): + if 'OWLocal' not in authChal: + try: + uid = os.getuid() + except AttributeError: + raise Error("OWLocal authorization for "\ + "openwbem server not supported "\ + "on %s platform due to missing "\ + "os.getuid()" % platform.system()) + localAuthHeader = ('Authorization', + 'OWLocal uid="%d"' % uid) + continue + else: + try: + nonceIdx = authChal.index('nonce=') + nonceBegin = authChal.index('"', nonceIdx) + nonceEnd = authChal.index('"', nonceBegin+1) + nonce = authChal[nonceBegin+1:nonceEnd] + cookieIdx = authChal.index('cookiefile=') + cookieBegin = authChal.index('"', cookieIdx) + cookieEnd = authChal.index('"', cookieBegin+1) + cookieFile = authChal[cookieBegin+1:cookieEnd] + f = open(cookieFile, 'r') + cookie = f.read().strip() + f.close() + localAuthHeader = ( + 'Authorization', + 'OWLocal nonce="%s", cookie="%s"' % \ + (nonce, cookie)) + continue + except: + localAuthHeader = None + continue + elif 'Local' in authChal: try: - uid = os.getuid() - except AttributeError: - raise Error("OWLocal authorization for "\ - "openwbem server not supported on %s "\ - "platform due to missing os.getuid()"%\ - platform.system()) - localAuthHeader = ('Authorization', - 'OWLocal uid="%d"' % uid) - continue - else: - try: - nonceIdx = authChal.index('nonce=') - nonceBegin = authChal.index('"', nonceIdx) - nonceEnd = authChal.index('"', nonceBegin+1) - nonce = authChal[nonceBegin+1:nonceEnd] - cookieIdx = authChal.index('cookiefile=') - cookieBegin = authChal.index('"', cookieIdx) - cookieEnd = authChal.index('"', cookieBegin+1) - cookieFile = authChal[cookieBegin+1:cookieEnd] - f = open(cookieFile, 'r') - cookie = f.read().strip() - f.close() - localAuthHeader = ( - 'Authorization', - 'OWLocal nonce="%s", cookie="%s"' % \ - (nonce, cookie)) - continue - except: - localAuthHeader = None - continue - elif 'Local' in authChal: - try: - beg = authChal.index('"') + 1 - end = authChal.rindex('"') - if end > beg: - file = authChal[beg:end] - fo = open(file, 'r') - cookie = fo.read().strip() - fo.close() - localAuthHeader = ( - 'PegasusAuthorization', - 'Local "%s:%s:%s"' % \ - (locallogin, file, cookie)) - continue - except ValueError: - pass + beg = authChal.index('"') + 1 + end = authChal.rindex('"') + if end > beg: + file = authChal[beg:end] + fo = open(file, 'r') + cookie = fo.read().strip() + fo.close() + localAuthHeader = ( + 'PegasusAuthorization', + 'Local "%s:%s:%s"' % \ + (locallogin, file, cookie)) + continue + except ValueError: + pass - raise AuthError(response.reason) - if response.getheader('CIMError', None) is not None and \ - response.getheader('PGErrorDetail', None) is not None: - raise Error( - 'CIMError: %s: %s' % - (response.getheader('CIMError'), - urllib.unquote(response.getheader('PGErrorDetail')))) - raise Error('HTTP error: %s' % response.reason) + raise AuthError(response.reason) + if response.getheader('CIMError', None) is not None and \ + response.getheader('PGErrorDetail', None) is not None: + raise Error( + 'CIMError: %s: %s' % + (response.getheader('CIMError'), + urllib.unquote(response.getheader( + 'PGErrorDetail')))) + raise Error('HTTP error: %s' % response.reason) - body = response.read() + body = response.read() - except httplib.BadStatusLine, arg: - # Background: BadStatusLine is documented to be raised only when - # strict=True is used (that is not the case here). However, httplib - # currently raises BadStatusLine also independent of strict when a - # keep-alive connection times out (e.g. because the server went - # down). See http://bugs.python.org/issue8450. - # On how to detect this: A connection timeout definitely causes - # arg==None, but it is not clear whether other situations could - # also cause arg==None. - if arg.line.strip().strip("'") == '': - raise ConnectionError("Connection error: The CIM server "\ - "closed the connection without "\ - "returning any data, or the client "\ - "timed out") - else: - raise Error("HTTP error: The CIM server returned a bad HTTP "\ - "status line: '%s'" % arg.line) - except httplib.IncompleteRead, arg: - raise ConnectionError("Connection error: HTTP incomplete read: %s" % arg) - except httplib.NotConnected, arg: - raise ConnectionError("Connection error: HTTP not connected: %s" % arg) - except socket.error, arg: - raise ConnectionError("Connection error: Socket error %s" % arg) - except socket.sslerror, arg: - raise ConnectionError("Connection error: SSL error %s" % arg) + except httplib.BadStatusLine, arg: + # Background: BadStatusLine is documented to be raised only + # when strict=True is used (that is not the case here). + # However, httplib currently raises BadStatusLine also + # independent of strict when a keep-alive connection times out + # (e.g. because the server went down). + # See http://bugs.python.org/issue8450. + # On how to detect this: A connection timeout definitely causes + # arg==None, but it is not clear whether other situations could + # also cause arg==None. + if arg.line.strip().strip("'") == '': + raise ConnectionError("Connection error: The CIM server "\ + "closed the connection without "\ + "returning any data, or the client "\ + "timed out") + else: + raise Error("HTTP error: The CIM server returned a bad "\ + "HTTP status line: '%s'" % arg.line) + except httplib.IncompleteRead, arg: + raise ConnectionError("Connection error: HTTP incomplete "\ + "read: %s" % arg) + except httplib.NotConnected, arg: + raise ConnectionError("Connection error: HTTP not "\ + "connected: %s" % arg) + except socket.error, arg: + raise ConnectionError("Connection error: Socket error %s" %arg) + except socket.sslerror, arg: + raise ConnectionError("Connection error: SSL error %s" % arg) - break + break return body Modified: pywbem/trunk/pywbem/cim_operations.py =================================================================== --- pywbem/trunk/pywbem/cim_operations.py 2015-01-22 13:19:25 UTC (rev 726) +++ pywbem/trunk/pywbem/cim_operations.py 2015-01-22 18:21:33 UTC (rev 727) @@ -398,7 +398,7 @@ def __init__(self, url, creds=None, default_namespace=DEFAULT_NAMESPACE, x509=None, verify_callback=None, ca_certs=None, - no_verification=False): + no_verification=False, timeout=None): """ Initialize the `WBEMConnection` object. @@ -512,6 +512,14 @@ Default: `False`. + timeout : number + Timeout in seconds, for requests sent to the server. If the server + did not respond within the timeout duration, the socket for the + connection will be closed, causing a `TimeoutError` to be raised. + A value of ``None`` means there is no timeout. + A value of ``0`` means the timeout is very short, and does not + really make any sense. + :Exceptions: See the list of exceptions described in `WBEMConnection`. @@ -524,6 +532,7 @@ self.ca_certs = ca_certs self.no_verification = no_verification self.default_namespace = default_namespace + self.timeout = timeout self.debug = False self.last_raw_request = None @@ -609,7 +618,8 @@ x509=self.x509, verify_callback=self.verify_callback, ca_certs=self.ca_certs, - no_verification=self.no_verification) + no_verification=self.no_verification, + timeout=self.timeout) except (cim_http.AuthError, cim_http.ConnectionError, cim_http.TimeoutError, cim_http.Error) as exc: raise CIMError(0, str(exc), exc) @@ -825,7 +835,8 @@ x509=self.x509, verify_callback=self.verify_callback, ca_certs=self.ca_certs, - no_verification=self.no_verification) + no_verification=self.no_verification, + timeout=self.timeout) except (cim_http.AuthError, cim_http.ConnectionError, cim_http.TimeoutError, cim_http.Error) as exc: raise CIMError(0, str(exc), exc) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-22 13:19:32
|
Revision: 726 http://sourceforge.net/p/pywbem/code/726 Author: maiera Date: 2015-01-22 13:19:25 +0000 (Thu, 22 Jan 2015) Log Message: ----------- Project web page: Adjusted logos in nav bar. Modified Paths: -------------- web/navbar.shtml Modified: web/navbar.shtml =================================================================== --- web/navbar.shtml 2015-01-22 12:54:09 UTC (rev 725) +++ web/navbar.shtml 2015-01-22 13:19:25 UTC (rev 726) @@ -1,12 +1,12 @@ <div id="sidebar"> <div style="overflow:auto"> - <div style="width:80px; float:left"> - <img alt="hp logo" src="logo-hp.gif"> + <div style="width:40px; float:left"> + <img alt="HP logo" src="logo-hp.gif" height="24"> </div> - <div style="width:20px; float:left"> </div> - <div style="width:100px; float:left"> - <img alt="IBM logo" src="logo-ibm.gif" height="40"> + <div style="width:10px; float:left"> </div> + <div style="width:40px; float:left"> + <img alt="IBM logo" src="logo-ibm.gif" height="20"> </div> </div> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-22 12:54:16
|
Revision: 725 http://sourceforge.net/p/pywbem/code/725 Author: maiera Date: 2015-01-22 12:54:09 +0000 (Thu, 22 Jan 2015) Log Message: ----------- Updated project web page: Added description how to upload project web files, to development page. Modified Paths: -------------- web/development.shtml Modified: web/development.shtml =================================================================== --- web/development.shtml 2015-01-22 12:31:01 UTC (rev 724) +++ web/development.shtml 2015-01-22 12:54:09 UTC (rev 725) @@ -25,11 +25,11 @@ <p>The top level directories in the code repository are organized along the main components of the PyWBEM project:</p> <ul> - <li><code>cimserver</code> - An experimental CIM server.</li> - <li><code>pyprovifc</code> - An experimental CIM provider interface.</li> - <li><code>pywbem</code> - The CIM-XML client library (the main component).</li> - <li><code>web</code> - Sources for the PyWBEM project web page.</li> + <li><code>pywbem</code> - The Python WBEM Client (the main component).</li> + <li><code>web</code> - Sources for the PyWBEM project web site (this site).</li> <li><code>yawn</code> - YAWN integration.</li> + <li><code>cimserver</code> - An experimental Python CIM server.</li> + <li><code>pyprovifc</code> - An experimental Python CIM provider interface.</li> </ul> <p>There are two mailing lists:</p> @@ -39,10 +39,8 @@ </ul> <p>The <a href="https://sourceforge.net/p/pywbem/bugs/">Bug Tracker</a> is used -for both bugs and features.</p> +for both bugs and features. Anyone can create bugs and features.</p> -<p>Anyone can create bugs and features.</p> - <p>Anyone can provide patches fixing bugs or implementing features. If you do, please attach the .patch file to the bug tracker entry.</p> @@ -50,6 +48,18 @@ show some engagement in fixing bugs or implementing new features (including test code) by providing patches. Then, ask one of the project admins.</p> +<p>How to update the PyWBEM project web site (this site): The web site is not +automatically updated when files are committed to the <code>web</code> +subdirectory of the code repository. They need to be manually updated, by +transferring the files to +<code>US...@we.../home/project-web/pywbem/htdocs</code> +where <code>USERID</code> is the userid of a PyWBEM admin. +You can use any of these protocols: SFTP, SCP, or rsync (for example, +FileZilla). +For details, see +<a href="https://sourceforge.net/p/forge/documentation/Project%20Web%20Services/">SourceForge web hosting</a>. +</p> + <hr> <!-- hhmts start --> Last Modified: Thursday, 22 January 2015 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-22 12:31:04
|
Revision: 724 http://sourceforge.net/p/pywbem/code/724 Author: maiera Date: 2015-01-22 12:31:01 +0000 (Thu, 22 Jan 2015) Log Message: ----------- Updated the project web pages: Some fixes, and updated the API reference to version 0.8.0_dev.r721. Revision Links: -------------- http://sourceforge.net/p/pywbem/code/721 Modified Paths: -------------- web/apiref.shtml web/documentation.shtml web/index.shtml web/navbar.shtml Modified: web/apiref.shtml =================================================================== --- web/apiref.shtml 2015-01-22 11:51:12 UTC (rev 723) +++ web/apiref.shtml 2015-01-22 12:31:01 UTC (rev 724) @@ -17,21 +17,24 @@ <h2>API Reference</h2> -<p>The API reference for PyWBEM is available for the following versions:</p> +<p>The API reference for the Python WBEM Client is available for the following +versions. Versions marked with "-dev.rNNN" are development snapshots:</p> -<ul> - <li><a href="docs/apiref/v0.8.0~dev/index.html">v0.8.0~dev (development snapshot)</a></li> -</ul> +<dl> + <dt>0.8.0-dev.r721</dt> + <dd> + <ul> + <li><a href="docs/apiref/0.8.0-dev.r721/docs/index.html">API reference</a></li> + <li><a href="docs/apiref/0.8.0-dev.r721/NEWS">NEWS file</a></li> + </ul> + </dd> +</dl> -<ul> - <li><a href="docs/apiref/NEWS">Change Log</a></li> -</ul> - <hr/> <p> <!-- hhmts start --> -Last Modified: Saturday, 11 October 2014 +Last Modified: Thursday, 22 January 2015 <!-- hhmts end --> </p> Modified: web/documentation.shtml =================================================================== --- web/documentation.shtml 2015-01-22 11:51:12 UTC (rev 723) +++ web/documentation.shtml 2015-01-22 12:31:01 UTC (rev 724) @@ -18,14 +18,13 @@ <h2>Documentation</h2> -<p>The following documentation is available for PyWBEM (the WBEM client):</p> +<p>The following documentation is available for the Python WBEM Client:</p> <ul> <li><a href="installation.shtml">Installation</a></li> <li><a href="tutorial.shtml">Tutorial</a></li> <li><a href="examples.shtml">Examples</a></li> <li><a href="apiref.shtml">API Reference</a></li> - <li><a href="docs/apiref/NEWS">Change Log</a></li> <li><a href="docs/examples/MDC2005/MDC2005.ppt">Presentation: Developing WBEM Clients Using Python</a></li> </ul> Modified: web/index.shtml =================================================================== --- web/index.shtml 2015-01-22 11:51:12 UTC (rev 723) +++ web/index.shtml 2015-01-22 12:31:01 UTC (rev 724) @@ -25,6 +25,7 @@ <ul> <li><a href="https://sourceforge.net/p/pywbem/news/?source=navbar">Project News</a></li> + <li><a href="https://sourceforge.net/p/pywbem/code/HEAD/tree/pywbem/trunk/pywbem/NEWS">Latest NEWS file in repository</a></li> <li><a href="http://sourceforge.net/projects/pywbem/files/">Downloads</a></li> <li><a href="documentation.shtml">Documentation</a></li> <li><a href="https://sourceforge.net/projects/pywbem/support?source=navbar">Support</a></li> Modified: web/navbar.shtml =================================================================== --- web/navbar.shtml 2015-01-22 11:51:12 UTC (rev 723) +++ web/navbar.shtml 2015-01-22 12:31:01 UTC (rev 724) @@ -25,7 +25,8 @@ </div> <div class="navitem"> -<a href="https://sourceforge.net/p/pywbem/news/?source=navbar">Project News</a>   +<a href="https://sourceforge.net/p/pywbem/news/?source=navbar">Project News</a> +   <a href="http://sourceforge.net/p/pywbem/news/feed/"><img border="0" alt="RSS" src="RSS.gif"></a> </div> @@ -46,7 +47,7 @@ </div> <div class="navitem"> -<a href="http://sourceforge.net/projects/pywbem/">Bugs</a> +<a href="https://sourceforge.net/p/pywbem/bugs/?source=navbar">Bugs</a> </div> <div class="navitem"> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-22 11:51:18
|
Revision: 723 http://sourceforge.net/p/pywbem/code/723 Author: maiera Date: 2015-01-22 11:51:12 +0000 (Thu, 22 Jan 2015) Log Message: ----------- Updated project web page: Improved navigation bar and home page; Added page for development; updated roadmap page. Modified Paths: -------------- web/index.shtml web/navbar.shtml web/roadmap.shtml Added Paths: ----------- web/development.shtml web/logo-hp.gif web/logo-ibm.gif Removed Paths: ------------- web/logostandard-cropped.gif Added: web/development.shtml =================================================================== --- web/development.shtml (rev 0) +++ web/development.shtml 2015-01-22 11:51:12 UTC (rev 723) @@ -0,0 +1,64 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + +<head> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<title>PyWBEM Development</title> +<link href="style.css" rel="stylesheet" type="text/css" /> +</head> + +<body> + +<!--#include virtual="header.shtml" --> + +<!--#set var="page" value="development" --> +<!--#include virtual="navbar.shtml" --> + +<div id="content"> + +<h2>Development</h2> + +<p>Development of PyWBEM is a community effort on SourceForge, using this +<a href="https://sourceforge.net/p/pywbem/code/HEAD/tree/">Code Repository</a> +</p> + +<p>The top level directories in the code repository are organized along the +main components of the PyWBEM project:</p> +<ul> + <li><code>cimserver</code> - An experimental CIM server.</li> + <li><code>pyprovifc</code> - An experimental CIM provider interface.</li> + <li><code>pywbem</code> - The CIM-XML client library (the main component).</li> + <li><code>web</code> - Sources for the PyWBEM project web page.</li> + <li><code>yawn</code> - YAWN integration.</li> +</ul> + +<p>There are two mailing lists:</p> +<ul> + <li><p><a href="https://sourceforge.net/p/pywbem/mailman/pywbem-devel/">pywbem-devel</a> - PyWBEM development related topics</p></li> + <li><p><a href="https://sourceforge.net/p/pywbem/mailman/pywbem-commit/">pywbem-commit</a> - PyWBEM commit messages</p></li> +</ul> + +<p>The <a href="https://sourceforge.net/p/pywbem/bugs/">Bug Tracker</a> is used +for both bugs and features.</p> + +<p>Anyone can create bugs and features.</p> + +<p>Anyone can provide patches fixing bugs or implementing features. If you do, +please attach the .patch file to the bug tracker entry.</p> + +<p>If you want to get commit rights for the code repository, you need to first +show some engagement in fixing bugs or implementing new features (including +test code) by providing patches. Then, ask one of the project admins.</p> + +<hr> +<!-- hhmts start --> +Last Modified: Thursday, 22 January 2015 +<!-- hhmts end --> + +</div> + +<!--#include virtual="footer.shtml" --> + +</body> + +</html> Modified: web/index.shtml =================================================================== --- web/index.shtml 2015-01-21 20:10:38 UTC (rev 722) +++ web/index.shtml 2015-01-22 11:51:12 UTC (rev 723) @@ -24,24 +24,33 @@ <h3>Using PyWBEM</h3> <ul> + <li><a href="https://sourceforge.net/p/pywbem/news/?source=navbar">Project News</a></li> <li><a href="http://sourceforge.net/projects/pywbem/files/">Downloads</a></li> <li><a href="documentation.shtml">Documentation</a></li> + <li><a href="https://sourceforge.net/projects/pywbem/support?source=navbar">Support</a></li> + <li><a href="https://sourceforge.net/p/pywbem/bugs/?source=navbar">Bugs</a></li> <li><a href="screenshots.shtml">Screenshots</a></li> <li><a href="roadmap.shtml">Roadmap</a></li> - <li><a href="old-news.shtml">Old Project News</a></li> </ul> +<h3>Contributing to PyWBEM</h3> + +<ul> + <li><a href="development.shtml">Development</a></li> +</ul> + <h3>Other resources</h3> <ul> <li><a href="books.shtml">Books</a></li> + <li><a href="old-news.shtml">Old Project News</a></li> </ul> <hr/> <p> <!-- hhmts start --> -Last Modified: Saturday, 11 October 2014 +Last Modified: Thursday, 22 January 2015 <!-- hhmts end --> </p> Copied: web/logo-hp.gif (from rev 722, web/logostandard-cropped.gif) =================================================================== (Binary files differ) Added: web/logo-ibm.gif =================================================================== (Binary files differ) Index: web/logo-ibm.gif =================================================================== --- web/logo-ibm.gif 2015-01-21 20:10:38 UTC (rev 722) +++ web/logo-ibm.gif 2015-01-22 11:51:12 UTC (rev 723) Property changes on: web/logo-ibm.gif ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Deleted: web/logostandard-cropped.gif =================================================================== (Binary files differ) Modified: web/navbar.shtml =================================================================== --- web/navbar.shtml 2015-01-21 20:10:38 UTC (rev 722) +++ web/navbar.shtml 2015-01-22 11:51:12 UTC (rev 723) @@ -1,6 +1,14 @@ <div id="sidebar"> -<img alt="hp logo" src="logostandard-cropped.gif"> +<div style="overflow:auto"> + <div style="width:80px; float:left"> + <img alt="hp logo" src="logo-hp.gif"> + </div> + <div style="width:20px; float:left"> </div> + <div style="width:100px; float:left"> + <img alt="IBM logo" src="logo-ibm.gif" height="40"> + </div> +</div> <h4>Project</h4> @@ -17,6 +25,11 @@ </div> <div class="navitem"> +<a href="https://sourceforge.net/p/pywbem/news/?source=navbar">Project News</a>   +<a href="http://sourceforge.net/p/pywbem/news/feed/"><img border="0" alt="RSS" src="RSS.gif"></a> +</div> + +<div class="navitem"> <a href="http://sourceforge.net/projects/pywbem/files/">Downloads</a> </div> @@ -29,6 +42,14 @@ </div> <div class="navitem"> +<a href="https://sourceforge.net/projects/pywbem/support?source=navbar">Support</a> +</div> + +<div class="navitem"> +<a href="http://sourceforge.net/projects/pywbem/">Bugs</a> +</div> + +<div class="navitem"> <!--#if expr="$page = screenshots" --> Screenshots <!--#else --> @@ -45,15 +66,15 @@ </div> <div class="navitem"> -<a href="http://sourceforge.net/projects/pywbem/">SourceForge</a> +<!--#if expr="$page = development" --> +Development +<!--#else --> +<a href="development.shtml">Development</a> +<!--#endif --> </div> <p/> -<div class="navitem"> -<a href="http://sourceforge.net/p/pywbem/news/feed/"><img border="0" alt="RSS" src="RSS.gif"></a> -</div> - <h4>Standards</h4> <div class="navitem"> @@ -68,6 +89,8 @@ <a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/wmi_reference.asp">WMI</a> </div> +<p/> + <h4>Related Projects</h4> <div class="navitem"> @@ -90,6 +113,8 @@ <a href="http://sblim.sourceforge.net/clientapps.html">SBLIM WBEMCLI</a> </div> +<p/> + <h4>Hosted by</h4> <div class="navitem"> Modified: web/roadmap.shtml =================================================================== --- web/roadmap.shtml 2015-01-21 20:10:38 UTC (rev 722) +++ web/roadmap.shtml 2015-01-22 11:51:12 UTC (rev 723) @@ -19,21 +19,29 @@ <h2>Roadmap</h2> <p>The following is a list, in no particular order, of things that -would be nice to be in future versions of PyWBEM: +would be nice to be in future versions of PyWBEM:</p> <ul> - <li> <p>WS-Management support.</p> - <li> <p>Rewrite XML parser to use <tt>xml.sax</tt> instead of <tt>xml.dom</tt> to avoid resource usage issues when parsing large XML requests and responses.</p> - <li> <p>Better testing on Windows platform(s).</p> - <li> <p>Better API documentation/reference.</p> - <li> <p>Update tutorial and add more usage examples.</p> + <li><p>Support for pulled enumeration operations (DSP0200 1.4).</p></li> + <li><p>Improvements on wbemcli command.</p></li> + <li><p>More complete and fully automated test cases, also on Windows + platform(s).</p></li> + <li><p>Better API documentation/reference.</p></li> + <li><p>Update tutorial and add more usage examples.</p></li> + <li><p>WS-Management support.</p></li> + <li><p>Rewrite XML parser to use <tt>xml.sax</tt> instead of <tt>xml.dom</tt> to + avoid resource usage issues when parsing large XML requests and + responses.</p></li> </ul> -</p> +<p>This list is not regularly maintained. If you have an idea for future +development of PyWBEM, please open a bug in the +<a href="https://sourceforge.net/p/pywbem/bugs/?source=navbar">Bug Tracker</a> +describing the idea.</p> -<p><hr> +<hr> <!-- hhmts start --> -Last Modified: Friday, 8 December 2006 06:50:15 +Last Modified: Thursday, 22 January 2015 <!-- hhmts end --> </div> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-21 20:10:45
|
Revision: 722 http://sourceforge.net/p/pywbem/code/722 Author: maiera Date: 2015-01-21 20:10:38 +0000 (Wed, 21 Jan 2015) Log Message: ----------- Released preliminary version 0.8.0-dev.r721 Revision Links: -------------- http://sourceforge.net/p/pywbem/code/721 Added Paths: ----------- pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r721.zip Added: pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r721.zip =================================================================== (Binary files differ) Index: pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r721.zip =================================================================== --- pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r721.zip 2015-01-21 20:07:57 UTC (rev 721) +++ pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r721.zip 2015-01-21 20:10:38 UTC (rev 722) Property changes on: pywbem/dist/pywbem-0.8.0/pywbem-0.8.0-dev.r721.zip ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-21 20:08:05
|
Revision: 721 http://sourceforge.net/p/pywbem/code/721 Author: maiera Date: 2015-01-21 20:07:57 +0000 (Wed, 21 Jan 2015) Log Message: ----------- Fixed bugs 31, 32, 36: Improved exception handling and simplified the exceptions that can be seen by a user of clas WBEMConnection. See there for details. Modified Paths: -------------- pywbem/trunk/pywbem/NEWS pywbem/trunk/pywbem/cim_http.py pywbem/trunk/pywbem/cim_operations.py pywbem/trunk/pywbem/tupleparse.py Modified: pywbem/trunk/pywbem/NEWS =================================================================== --- pywbem/trunk/pywbem/NEWS 2015-01-21 18:31:17 UTC (rev 720) +++ pywbem/trunk/pywbem/NEWS 2015-01-21 20:07:57 UTC (rev 721) @@ -1,4 +1,4 @@ -pywbem-0.8.0-dev.r715 +pywbem-0.8.0-dev.r721 ENHANCEMENTS: @@ -79,6 +79,10 @@ _CDATA_ESCAPING accordingly, which is a global variable in the cim_xml module. (Andreas Maier) + * Simplified the exceptions that can be raised by WBEMConnection methods, + and improved the information in the exception messages. See description + of WBEMConnection class for details. (Andreas Maier) + BUG FIXES: * Fix syntax error in CIM DTDVERSION error path. Allow KEYVALUE Modified: pywbem/trunk/pywbem/cim_http.py =================================================================== --- pywbem/trunk/pywbem/cim_http.py 2015-01-21 18:31:17 UTC (rev 720) +++ pywbem/trunk/pywbem/cim_http.py 2015-01-21 20:07:57 UTC (rev 721) @@ -57,6 +57,15 @@ """This exception is raised when an authentication error (401) occurs.""" pass +class ConnectionError(Error): + """This exception is raised when a connection-related problem occurs, + where a retry might make sense.""" + pass + +class TimeoutError(Error): + """This exception is raised when the client timeout is exceeded.""" + pass + def parse_url(url): """Return a tuple of ``(host, port, ssl)`` from the URL specified in the ``url`` parameter. @@ -353,9 +362,9 @@ h = FileHTTPConnection(url) local = True else: - raise Error('Invalid URL') + raise Error('Invalid URL: %s' % url) except OSError: - raise Error('Invalid URL') + raise Error('Invalid URL: %s' % url) locallogin = None if host in ('localhost', 'localhost6', '127.0.0.1', '::1'): @@ -479,11 +488,30 @@ body = response.read() except httplib.BadStatusLine, arg: - raise Error("The web server returned a bad status line: '%s'" % arg) + # Background: BadStatusLine is documented to be raised only when + # strict=True is used (that is not the case here). However, httplib + # currently raises BadStatusLine also independent of strict when a + # keep-alive connection times out (e.g. because the server went + # down). See http://bugs.python.org/issue8450. + # On how to detect this: A connection timeout definitely causes + # arg==None, but it is not clear whether other situations could + # also cause arg==None. + if arg.line.strip().strip("'") == '': + raise ConnectionError("Connection error: The CIM server "\ + "closed the connection without "\ + "returning any data, or the client "\ + "timed out") + else: + raise Error("HTTP error: The CIM server returned a bad HTTP "\ + "status line: '%s'" % arg.line) + except httplib.IncompleteRead, arg: + raise ConnectionError("Connection error: HTTP incomplete read: %s" % arg) + except httplib.NotConnected, arg: + raise ConnectionError("Connection error: HTTP not connected: %s" % arg) except socket.error, arg: - raise Error("Socket error: %s" % (arg,)) + raise ConnectionError("Connection error: Socket error %s" % arg) except socket.sslerror, arg: - raise Error("SSL error: %s" % (arg,)) + raise ConnectionError("Connection error: SSL error %s" % arg) break Modified: pywbem/trunk/pywbem/cim_operations.py =================================================================== --- pywbem/trunk/pywbem/cim_operations.py 2015-01-21 18:31:17 UTC (rev 720) +++ pywbem/trunk/pywbem/cim_operations.py 2015-01-21 20:07:57 UTC (rev 721) @@ -41,6 +41,7 @@ from pywbem import cim_obj, cim_xml, cim_http, cim_types, tupletree, tupleparse from pywbem.cim_obj import CIMInstance, CIMInstanceName, CIMClass, \ CIMClassName, NocaseDict +from pywbem.tupleparse import ParseError __all__ = ['DEFAULT_NAMESPACE', 'check_utf8_xml_chars', 'CIMError', 'WBEMConnection', 'is_subclass', @@ -239,24 +240,43 @@ class CIMError(Exception): """ - Exception indicating that a CIM error has happened. + Exception indicating that either the WBEM server has returned an error or + the response from the WBEM server has some issue. - The exception value is a tuple of ``(error_code, description)``, where: + The exception value is a tuple of + ``(error_code, description, exception_obj)``, where: - * ``error_code``: a numeric error code. + * ``error_code``: a numeric error code. See below for details. - A value of 0 indicates an error detected by the PyWBEM client, or a - connection error, or an HTTP error reported by the WBEM server. + * ``description``: a string (`unicode` or UTF-8 encoded `str`) + representing a human readable message describing the error. See below + for details. - Values other than 0 indicate that the WBEM server has returned an error - response, and the value is the CIM status code of the error response. - See `cim_constants` for constants defining CIM status code values. + * ``exception_obj``: the underlying exception object that caused this + exception to be raised. See below for details. - * ``description``: a string (`unicode` or UTF-8 encoded `str`) - representing a human readable message describing the error. If - `error_code` is not 0, this string is the CIM status description of the - error response returned by the WBEM server. Otherwise, this is a - message issued by the PyWBEM client. + An ``error_code`` value other than 0 indicates that the WBEM server has + returned an error response, and ``error_code`` is the CIM status code of + the error response. See `cim_constants` for constants defining CIM status + code values. In this case, ``description`` is the CIM status description + text returned by the server, and ``exception_obj`` is ``None``. + + An ``error_code`` value of 0 indicates an error detected in the PyWBEM + client after receiving the response returned by the WBEM server (for + example, an XML parsing error). In this case, ``exception_obj`` is another + exception object describing the error, and ``description`` is the + string representation of the error message of that other exception object. + The following other exception objects are used: + + * `cim_http.AuthError`: Authentication error (HTTP status 401). + * `cim_http.ConnectionError`: Problem with the connection to the server, + a retry sometimes later would make sense. + * `cim_http.TimeoutError`: Client timeout occurred. + * `tupleparse.ParseError`: CIM-XML parsing issue. + * `cim_http.Error`: Other low level error (e.g. HTTP error, CIMError + HTTP header). This exception is a base class for `cim_http.AuthError`, + `cim_http.ConnectionError`, and `cim_http.TimeoutError` and thus must + be handled at the end. """ @@ -581,7 +601,7 @@ self.last_raw_reply = None self.last_reply = None - # Get XML response + # Send request and receive response try: reply_xml = cim_http.wbem_request( @@ -590,23 +610,27 @@ verify_callback=self.verify_callback, ca_certs=self.ca_certs, no_verification=self.no_verification) - except cim_http.AuthError: - raise - except cim_http.Error, arg: - # Convert cim_http exceptions to CIMError exceptions - raise CIMError(0, str(arg)) + except (cim_http.AuthError, cim_http.ConnectionError, + cim_http.TimeoutError, cim_http.Error) as exc: + raise CIMError(0, str(exc), exc) - ## TODO: Perhaps only compute this if it's required? Should not be - ## all that expensive. - # Set the raw response before parsing (which can fail) if self.debug: self.last_raw_reply = reply_xml try: reply_dom = minidom.parseString(reply_xml) - except ExpatError: + except ParseError as exc: + msg = str(exc) parsing_error = True + except ExpatError as exc: + # This is raised e.g. when XML numeric entity references of invalid + # XML characters are used (e.g. '�'). + # str(exc) is: "{message}, line {X}, offset {Y}" + parsed_line = str(reply_xml).splitlines()[exc.lineno-1] + msg = "ExpatError %s: %s: %r" % (str(exc.code), str(exc), + parsed_line) + parsing_error = True else: parsing_error = False @@ -615,7 +639,15 @@ # so we do this only if it already has failed. Because the check # function we invoke catches more errors than minidom.parseString, # we call it also when debug is turned on. - check_utf8_xml_chars(reply_xml, "CIM-XML response") + try: + check_utf8_xml_chars(reply_xml, "CIM-XML response") + except ParseError as exc2: + raise CIMError(0, str(exc2), exc2) + else: + if parsing_error: + # We did not catch it in the check function, but + # minidom.parseString() failed. + raise CIMError(0, msg, exc) # data from previous exception if self.debug: pretty_reply = reply_dom.toprettyxml(indent=' ') @@ -627,24 +659,29 @@ tt = tupleparse.parse_cim(tupletree.dom_to_tupletree(reply_dom)) if tt[0] != 'CIM': - raise CIMError(0, 'Expecting CIM element, got %s' % tt[0]) + exc = ParseError('Expecting CIM element, got %s' % tt[0]) + raise CIMError(0, str(exc), exc) tt = tt[2] if tt[0] != 'MESSAGE': - raise CIMError(0, 'Expecting MESSAGE element, got %s' % tt[0]) + exc = ParseError('Expecting MESSAGE element, got %s' % tt[0]) + raise CIMError(0, str(exc), exc) tt = tt[2] if len(tt) != 1 or tt[0][0] != 'SIMPLERSP': - raise CIMError(0, 'Expecting one SIMPLERSP element') + exc = ParseError('Expecting one SIMPLERSP element') + raise CIMError(0, str(exc), exc) tt = tt[0][2] if tt[0] != 'IMETHODRESPONSE': - raise CIMError( - 0, 'Expecting IMETHODRESPONSE element, got %s' % tt[0]) + exc = ParseError('Expecting IMETHODRESPONSE element, got %s' %\ + tt[0]) + raise CIMError(0, str(exc), exc) if tt[1]['NAME'] != methodname: - raise CIMError(0, 'Expecting attribute NAME=%s, got %s' % - (methodname, tt[1]['NAME'])) + exc = ParseError('Expecting attribute NAME=%s, got %s' %\ + (methodname, tt[1]['NAME'])) + raise CIMError(0, str(exc), exc) tt = tt[2] # At this point we either have a IRETURNVALUE, ERROR element @@ -661,7 +698,8 @@ raise CIMError(code, 'Error code %s' % tt[1]['CODE']) if tt[0] != 'IRETURNVALUE': - raise CIMError(0, 'Expecting IRETURNVALUE element, got %s' % tt[0]) + exc = ParseError('Expecting IRETURNVALUE element, got %s' % tt[0]) + raise CIMError(0, str(exc), exc) return tt @@ -779,7 +817,7 @@ self.last_raw_reply = None self.last_reply = None - # Get XML response + # Send request and receive response try: reply_xml = cim_http.wbem_request( @@ -788,9 +826,9 @@ verify_callback=self.verify_callback, ca_certs=self.ca_certs, no_verification=self.no_verification) - except cim_http.Error, arg: - # Convert cim_http exceptions to CIMError exceptions - raise CIMError(0, str(arg)) + except (cim_http.AuthError, cim_http.ConnectionError, + cim_http.TimeoutError, cim_http.Error) as exc: + raise CIMError(0, str(exc), exc) # Set the raw response before parsing and checking (which can fail) if self.debug: @@ -798,8 +836,17 @@ try: reply_dom = minidom.parseString(reply_xml) - except ExpatError: + except ParseError as exc: + msg = str(exc) parsing_error = True + except ExpatError as exc: + # This is raised e.g. when XML numeric entity references of invalid + # XML characters are used (e.g. '�'). + # str(exc) is: "{message}, line {X}, offset {Y}" + parsed_line = str(reply_xml).splitlines()[exc.lineno-1] + msg = "ExpatError %s: %s: %r" % (str(exc.code), str(exc), + parsed_line) + parsing_error = True else: parsing_error = False @@ -808,7 +855,15 @@ # so we do this only if it already has failed. Because the check # function we invoke catches more errors than minidom.parseString, # we call it also when debug is turned on. - check_utf8_xml_chars(reply_xml, "CIM-XML response") + try: + check_utf8_xml_chars(reply_xml, "CIM-XML response") + except ParseError as exc2: + raise CIMError(0, str(exc2), exc2) + else: + if parsing_error: + # We did not catch it in the check function, but + # minidom.parseString() failed. + raise CIMError(0, msg, exc) # data from previous exception if self.debug: pretty_reply = reply_dom.toprettyxml(indent=' ') @@ -820,24 +875,29 @@ tt = tupleparse.parse_cim(tupletree.dom_to_tupletree(reply_dom)) if tt[0] != 'CIM': - raise CIMError(0, 'Expecting CIM element, got %s' % tt[0]) + exc = ParseError('Expecting CIM element, got %s' % tt[0]) + raise CIMError(0, str(exc), exc) tt = tt[2] if tt[0] != 'MESSAGE': - raise CIMError(0, 'Expecting MESSAGE element, got %s' % tt[0]) + exc = ParseError('Expecting MESSAGE element, got %s' % tt[0]) + raise CIMError(0, str(exc), exc) tt = tt[2] if len(tt) != 1 or tt[0][0] != 'SIMPLERSP': - raise CIMError(0, 'Expecting one SIMPLERSP element') + exc = ParseError('Expecting one SIMPLERSP element') + raise CIMError(0, str(exc), exc) tt = tt[0][2] if tt[0] != 'METHODRESPONSE': - raise CIMError( - 0, 'Expecting METHODRESPONSE element, got %s' % tt[0]) + exc = ParseError('Expecting METHODRESPONSE element, got %s' %\ + tt[0]) + raise CIMError(0, str(exc), exc) if tt[1]['NAME'] != methodname: - raise CIMError(0, 'Expecting attribute NAME=%s, got %s' % - (methodname, tt[1]['NAME'])) + exc = ParseError('Expecting attribute NAME=%s, got %s' %\ + (methodname, tt[1]['NAME'])) + raise CIMError(0, str(exc), exc) tt = tt[2] # At this point we have an optional RETURNVALUE and zero or Modified: pywbem/trunk/pywbem/tupleparse.py =================================================================== --- pywbem/trunk/pywbem/tupleparse.py 2015-01-21 18:31:17 UTC (rev 720) +++ pywbem/trunk/pywbem/tupleparse.py 2015-01-21 20:07:57 UTC (rev 721) @@ -918,8 +918,14 @@ for q in list_of_matching(tt, ['QUALIFIER']): quals[q.name] = q - val = unpack_value(tt) a = attrs(tt) + try: + val = unpack_value(tt) + except ValueError as exc: + msg = str(exc) + raise ParseError('Cannot parse value for property "%s": %s' %\ + (a['NAME'], msg)) + embedded_object = None if 'EmbeddedObject' in a or 'EMBEDDEDOBJECT' in a: try: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ma...@us...> - 2015-01-21 18:31:20
|
Revision: 720 http://sourceforge.net/p/pywbem/code/720 Author: maiera Date: 2015-01-21 18:31:17 +0000 (Wed, 21 Jan 2015) Log Message: ----------- Prettified the CIM-XML in WBEMConnection.last_reply by removing unnecessary empty lines created by the Python xml.dom.minidom prettifier. Modified Paths: -------------- pywbem/trunk/pywbem/cim_operations.py Modified: pywbem/trunk/pywbem/cim_operations.py =================================================================== --- pywbem/trunk/pywbem/cim_operations.py 2015-01-21 18:29:01 UTC (rev 719) +++ pywbem/trunk/pywbem/cim_operations.py 2015-01-21 18:31:17 UTC (rev 720) @@ -618,7 +618,9 @@ check_utf8_xml_chars(reply_xml, "CIM-XML response") if self.debug: - self.last_reply = reply_dom.toprettyxml(indent=' ') + pretty_reply = reply_dom.toprettyxml(indent=' ') + self.last_reply = re.sub(r'>( *[\r\n]+)+( *)<', r'>\n\2<', + pretty_reply) # remove extra empty lines # Parse response @@ -809,7 +811,9 @@ check_utf8_xml_chars(reply_xml, "CIM-XML response") if self.debug: - self.last_reply = reply_dom.toprettyxml(indent=' ') + pretty_reply = reply_dom.toprettyxml(indent=' ') + self.last_reply = re.sub(r'>( *[\r\n]+)+( *)<', r'>\n\2<', + pretty_reply) # remove extra empty lines # Parse response This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |