Re: [geo] Economic interests and ideologies behind solar geoengineering research in the United States
Hello Everyone, Kevin Surprise and J.P. Sapinski here. Andrew brought this discussion to our attention and we wanted to take a moment to address you all directly. First, thank you for so vigorously engaging with our blog post and longer paper, even if we do come from different perspectives on solar geoengineering research and its potential role in climate policy. Our papers don’t often get this level of attention! We do very much appreciate the additional details provided by many of you. We certainly did our best in assembling that dataset (which is in some ways an update of the 2019 piece by Necheles and colleagues on the HSGRP blog), but as academic researchers, we all understand well that some small mistakes might appear even in the most carefully curated datasets. On some of the points raised: 1. On SilverLining funding GeoMIP, and PNNL funding Cornell - we are going back through our data to see where these connections originally emerged for us. This will take some time, but one thing to note is that GeoMIP has many integral and longstanding connections to RISCI (which SilverLining directly funds), e.g. GeoMIP emerged out of RISCI, is still (according to the website) steered by Alan Robock, and the RISCI website states "In addition of continuing to support GeoMIP, we are now focused on the impacts of SAI climate intervention…” So SilverLining indirectly supports GeoMIP via Rutgers (according to how we’re thinking about connections in the field). We may decide to correct that line in the table to note that SilverLining funds RISCI, which in turn supports GeoMIP, but we note that the main arguments we make in the paper are not at all affected by these individual connections. 2. Similarly, on SilverLining and GLENS, it was our interpretation that GLENS was the basis for NCAR’s new modeling project with Amazon Web Services, with recent publications from NCAR researchers using GLENS (within the SilverLining funding period), and hence our understanding of current NCAR solar geoengineering modeling as based on and using/expanding GLENS - the most well known solar geo research output from NCAR (who are funded by funded by SilverLining). 3. On EDF and Cornell, it’s our understanding that Cornell Climate Engineering is under the umbrella of and supported by the Atkinison Center for Sustainability, which has a significant partnership (financial and otherwise) with EDF. Given that EDF is one of the leading Big Greens advancing solar geoengineering conversations, we find this connection significant. 4. On FICER, is it indeed lumped with its funder Bill Gates in the table, but no line appears between FICER and HSGRP in figure 1. We thus are in agreement with Ken Caldeira that FICER does not fund HSGRP. We had to 1. keep the table simple, 2. find a way to show what Gates has funded and that he is the largest single funder of solar geoengineering research - a significant fact, we think, and 3) note that FICER is a personal fund of Gates to differentiate it from the Gates Foundation, which is how it is phrased on Harvard’s FICER webpage. 5. On C2G, we greatly appreciate Janos’ concerns and engagement - we are in agreement with his specifications of C2G’s funding sources. In the larger paper we define solar geoengineering research as any scientific or governance effort that advances solar geoengineering - initiating high-level governance conversations certainly does that, even if an organization claims neutrality. In the larger paper we discuss funding and C2G clearly (i.e. we only examined funding organizations that have given to two different SG initiatives in recent years, so VKRF is discussed but not, say, Children’s Investment Fund (CFI), though incidentally CFI is founded/run by yet another billionaire hedge fund manager … ). Finally, in case someone would like to engage on the argument we are making: the paper shows that despite the fact that many prominent critics present solar geoengineering as supported by the fossil fuel industry, it is actually funded by individuals and philanthropies from the high-tech and financial sectors (e.g. billionaires, Silicon Valley VC’s, hedge fund people). From this empirical finding,* we argue that solar geoengineering is poised to play a strategic, compromise role among the fossil fuel industry and what we call “climate capitalists.” That is, solar geoengineering can potentially buttress the fossil fuel industry’s interest in a gradual, long-term energy transition (not SRM research but the promise of SRM as a strategy), and it is now being turned to by key segments within liberal** climate politics also interested in/dependent upon a gradual, market driven response to climate change. The unique qualities of solar geoengine
Re: BUS: Removing Duplicate Text
On Tue, Jun 22, 2021 at 4:21 PM Surprise Nomic wrote: > I intend without objection to clean Rule 2531 "Defendant's Rights" by > replacing the text "of of a Finger" in section (7) with the text "of a > Finger". > Having received no objection, I do so.
BUS: Removing Duplicate Text
I intend without objection to clean Rule 2531 "Defendant's Rights" by replacing the text "of of a Finger" in section (7) with the text "of a Finger".
BUS: Registration
I register with the preferred name 'surprise'.
Choisissez le bijou de votre choix
http://api.selection-privee.fr/tracking.api?te=46607701ts=12868ti=205966tz=31tk=9qj40HpCWPi9bw2vCH54pcjHU3LVGb91Rq9B ce lien pour consulter la version en ligne (http://api.selection-privee.fr/tracking.api?te=46607701ts=12868ti=193875tz=32tk=tqTQZW5K7Eae9nuAYby5Ur1JRcfKxxthZmw6 pouvez #224; tout moment d#233;cider de ne plus recevoir nos offres ici Choisissez le bijou de votre choix -- Learn Graph Databases - Download FREE O'Reilly Book Graph Databases is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/13534_NeoTech ___ spi-devel-general mailing list spi-devel-general@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/spi-devel-general
Votre récompense [en attente]
http://www.lktrk7.com/lead.api?ref=xSMgIe10iemail=spi-devel-general@lists.sourceforge.net (http://api./view.html?ve=vs=vk=)Suivez ce lien pour consulter la version en ligne (http://api./unsubscribe.html?ue=us=uk=)Vous pouvez #224; tout moment d#233;cider de ne plus recevoir nos offres ici Votre r#233;compense - Service de livraison - Bonjour {Pr#233;nom}, F#233;licitations! Vous faites partie des personnes s#233;lectionn#233;es. Vous donnez votre avis et nous vous envoyons la r#233;compense de votre choix parmi plus de 1000 articles. Si votre nom fait partie de la liste ci-dessous, confirmez vite vos coordonn#233;es pour assurer la livraison de votre colis*. - C#233;line Moulin - {prenom} {nom} - Martin Duverger * Enqu#234;te-Shopping est le seul organisme d'enqu#234;te consommateur qui, gr#226;ce #224; ses partenariats avec les grandes marques, r#233;compense imm#233;diatement l'ensemble des participants. Seuls les frais de pr#233;paration et d'acheminement restent #224; la charge du participant. -- Rapidly troubleshoot problems before they affect your business. Most IT organizations don't have a clear picture of how application performance affects their revenue. With AppDynamics, you get 100% visibility into your Java,.NET, PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro! http://pubads.g.doubleclick.net/gampad/clk?id=84349831iu=/4140/ostg.clktrk ___ spi-devel-general mailing list spi-devel-general@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/spi-devel-general
[NetBehaviour] Online radical zine library looking for help
Please contact Zinelibrary if you know about Drupal sites, libraries or translation efforts and would like to expand their site (zinelibrary.info). Contact form can be found here: http://zinelibrary.info/contact ___ NetBehaviour mailing list NetBehaviour@netbehaviour.org http://www.netbehaviour.org/mailman/listinfo/netbehaviour
[NetBehaviour] Call for submissions: Internet Memes and Visual Culture
Editors are seeking proposals for a Special Issue of the Journal of Visual Culture on Internet Memes and Visual Culture, to be published December 2014. This special issue of the Journal of Visual Culture will organize a conversation among cultural scholars, artists, activists, journalists and Internet content producers regarding the social, historical, and aesthetic significance of Internet memes. Proposed contributions may take the form of scholarly articles (5000-7000 words), but the Editors are particularly interested in shorter essays, graphic essays, and other creative formats. We especially encourage submissions in formats that can be showcased on the Journal of Visual Culture's blog and a Tumblr devoted to this special issue. The deadline for submission of proposals/abstracts is 15 January 2013. The Editors expect to make final decisions about accepted contributions by mid-March 2013. Accepted contributors will be asked to submit their full contributions by January 2014. Details: http://www.lainenooney.com/1/post/2012/11/memesvisualculture.html ___ NetBehaviour mailing list NetBehaviour@netbehaviour.org http://www.netbehaviour.org/mailman/listinfo/netbehaviour
Download Sex Movies
Download Sex Movies http://tiny.cc/Nnq9D WATCH tube sex http://tiny.cc/Nnq9D See More 20 Sex Movies Now Free http://tiny.cc/Nnq9D Click Here to download And see The New Sex Movies http://tiny.cc/Nnq9D See Mana Sex Now http://tiny.cc/Nnq9D Download Sex Movies http://tiny.cc/Nnq9D --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups JAVA-experts group. To post to this group, send email to java-experts@googlegroups.com To unsubscribe from this group, send email to java-experts+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/java-experts?hl=ab -~--~~~~--~~--~--~---
Download Sex Movies
Download Sex Movies http://tiny.cc/Nnq9D WATCH tube sex http://tiny.cc/Nnq9D See More 20 Sex Movies Now Free http://tiny.cc/Nnq9D Click Here to download And see The New Sex Movies http://tiny.cc/Nnq9D See Mana Sex Now http://tiny.cc/Nnq9D Download Sex Movies http://tiny.cc/Nnq9D --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups JAVA-experts group. To post to this group, send email to java-experts@googlegroups.com To unsubscribe from this group, send email to java-experts+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/java-experts?hl=ab -~--~~~~--~~--~--~---
Download Sex Movies
Download Sex Movies http://tiny.cc/Nnq9D WATCH tube sex http://tiny.cc/Nnq9D See More 20 Sex Movies Now Free http://tiny.cc/Nnq9D Click Here to download And see The New Sex Movies http://tiny.cc/Nnq9D See Mana Sex Now http://tiny.cc/Nnq9D Download Sex Movies http://tiny.cc/Nnq9D --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups JAVA-experts group. To post to this group, send email to java-experts@googlegroups.com To unsubscribe from this group, send email to java-experts+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/java-experts?hl=ab -~--~~~~--~~--~--~---
£1,000.000.00 GBP
You have just been awarded,£1,000.000.00 GBP Names: Address:.. Country:.. Sex/Tel... ___ pkg-java-maintainers mailing list pkg-java-maintainers@lists.alioth.debian.org http://lists.alioth.debian.org/mailman/listinfo/pkg-java-maintainers
Bug#526613: £1,000,000.00 GBP
£1,000,000.00 GBP has been award to you in the Global online,send us your Names: Address:.. Country:.. Sex/Tel... -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#526613: £1,000,000.00 GBP
£1,000,000.00 GBP has been award to you in the Global online,send us your Names: Address:.. Country:.. Sex/Tel... -- To UNSUBSCRIBE, email to debian-www-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
[cari-kawan] £1,000.000.00 GBP
You have just been awarded,£1,000.000.00 GBP in the Tobacco Online,send us your Names: Address:.. Country:.. Sex/Tel...
[Bug 214133] Re: Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info
Exactly the same problem in kernel 2.6.24-16 (x64). -- Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info https://bugs.launchpad.net/bugs/214133 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 214133] Re: Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info
Here is lspci if you are interested in my hardware. Tell me if you want something more. ** Attachment added: lspci output http://launchpadlibrarian.net/13260941/lspci_2.6.24-15-generic.log -- Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info https://bugs.launchpad.net/bugs/214133 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 214133] Re: Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info
** Attachment added: Kernel Messages http://launchpadlibrarian.net/13260924/kernel_messages_2.6.24-15-generic.log -- Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info https://bugs.launchpad.net/bugs/214133 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 214133] [NEW] Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info
Public bug reported: Binary package hint: linux-image After upgrade to Kernel 2.6.24-15 (x64), my computer will not come up. It hangs with the following kernel message: [ 116.903572] Call Trace: [ 116.903662] [882e43eb] :snd_pcm:snd_pcm_proc_info_read+0x3b/0x170 [ 116.903720] [882068c7] :snd:snd_info_entry_open+0x147/0x2e0 [ 116.903776] [802eecd0] proc_reg_open+0x0/0xa0 [ 116.903824] [802eed2e] proc_reg_open+0x5e/0xa0 [ 116.903876] [802ab56b] __dentry_open+0xdb/0x200 [ 116.903928] [802ab79a] do_filp_open+0x3a/0x50 [ 116.903983] [802ab3d7] get_unused_fd_flags+0x77/0x120 [ 116.904036] [802ab80a] do_sys_open+0x5a/0xf0 [ 116.904088] [8020c37e] system_call+0x7e/0x83 [ 116.904143] [ 116.904185] [ 116.904185] Code: 8b 00 89 45 0c 8b 43 18 89 45 00 41 8b 45 3c 89 45 08 41 8b [ 116.904889] RIP [882e7ac4] :snd_pcm:snd_pcm_info+0x44/0x110 [ 116.904971] RSP 81012aadbda8 [ 116.905016] CR2: 0002 [ 116.905066] ---[ end trace 8ec89009b84c3f99 ]--- To continue, I have to press ctrl+alt+delete and X will not come up. / is mounted read-only and I have no ip (have to launch dhclient myself). ** Affects: linux-meta (Ubuntu) Importance: Undecided Status: New -- Kernel 2.6.24-15-generic hangs in startup with snd_pcm:snd_pcm_info https://bugs.launchpad.net/bugs/214133 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 202244] Re: [fglrx] System lockups when starting gdm with fglrx
Sorry, I have bought new motherboard+cpu+memory+graphics card and I'm not longer using Ati Radeon 3850 AGP. I had a lot of other problems by the way with devices on the motherboard disappearing when the graphics card was inserted. Anyone else having an ATI 3850 AGP to try with? -- [fglrx] System lockups when starting gdm with fglrx https://bugs.launchpad.net/bugs/202244 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
Bug#165244: Quit talking and start shagging
Watch her fondle your toy with pleasure and joy. http://www.Pretextis.com/ Stripping for pleasure -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
[Bug 195308] Re: unable to resolve host
gksu nano /etc/hosts did not work for me. I had to boot into recovery mode and edit /etc/hosts. Then it worked. -- unable to resolve host https://bugs.launchpad.net/bugs/195308 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 202244] [NEW] System lockups when starting gdm with fglrx
Public bug reported: When I try to boot my system, Hardy Alpha x64, with fglrx enabled, my system locks up with the following kernel messages: [...] [ OK ]rting GNOME Display Manager... [ OK ]rting OpenBSD Secure Shell server sshd [ OK ]rting Avahi mDNS/DNS-SD Daemon avahi-daemon [ OK ]rting Common Unix Printing System: cupsd [ OK ]rting MySQL database server mysqld * Checking for corrupt, not cleanly closed and upgrade needing tables. [ OK ]rting atieventsd /etc/rc2.d/S20dkms_autoinstaller: line 82: /var/lib/dkms/fglrx/8.455.2/source/dy fglrx (8.455.2): AUTOINSTALL not set in its dkms.conf. lirc (0.8.3~pre1): Already installed on this kernel. Starting inputlirc [ OK ]rting powernowd... * CPU frequency scaling not supported... * Starting Samba daemons[ 78.621621] BUG: soft lockup - CPU#0 stuck ] [ 90.410270] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 102.194929] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 113.983580] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 125.768239] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 137.556891] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 149.345543] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 161.130201] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 172.918853] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] [ 184.703512] BUG: soft lockup - CPU#0 stuck for 11s! [Xorg:5469] And nothing more happens, it is locked up! I am using the latest fglrx driver in repository. My graphics card is a Powercolor Radeon HD3850 with 512mb ram and AGP. It is not officially supported by fglrx, but have a look in my Xorg.0.log file. It looks quite good there. Note: I have tried this both in Gutsy (x64) and when it didn't work, I upgraded to Hardy Alpha (x64). The problem is the same. ** Affects: ubuntu Importance: Undecided Status: New -- System lockups when starting gdm with fglrx https://bugs.launchpad.net/bugs/202244 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 202244] Re: System lockups when starting gdm with fglrx
** Attachment added: Xorg.0.log_fglrx_hang http://launchpadlibrarian.net/12673022/Xorg.0.log_fglrx_hang -- System lockups when starting gdm with fglrx https://bugs.launchpad.net/bugs/202244 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 202244] Re: System lockups when starting gdm with fglrx
By the way: My system is a AMD64 3200+ with 2GB of ram and 2x160 gb hdd (raid) + 1x160 gb. A Powercolor Radeon HD3850 512mb AGP is serving for graphics. -- System lockups when starting gdm with fglrx https://bugs.launchpad.net/bugs/202244 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 202244] Re: System lockups when starting gdm with fglrx
In kernel boot, fglrx says this: [ 43.970529] fglrx: module license 'Proprietary. (C) 2002 - ATI Technologies,. [ 44.122004] [fglrx] Maximum main memory to use for locked dma buffers: 1887 . [ 44.129757] [fglrx] ASYNCIO init succeed! [ 44.134040] [fglrx] PAT is enabled successfully! [ 44.199020] [fglrx] module loaded - fglrx 8.47.3 [Feb 25 2008] on minor 0 -- System lockups when starting gdm with fglrx https://bugs.launchpad.net/bugs/202244 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 180936] Re: exaile.py crashed with SIGSEGV in IA__gtk_tree_view_remove_column()
After some updates some days ago, there is no sound in exaile, and even it seems to be playing, the timer stand still. There is a stream in Pulseaudio Volume control as well but no sound. -- exaile.py crashed with SIGSEGV in IA__gtk_tree_view_remove_column() https://bugs.launchpad.net/bugs/180936 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 195308] Re: unable to resolve host
After upgrade from Gutsy (x64) to Hardy, I also have exactly this problem. I can see that my computers hostname is pointing on 127.0.1.1 in /etc/hosts. I will try to modify this and se if it solves the problem. -- unable to resolve host https://bugs.launchpad.net/bugs/195308 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
Html parser
Could you recommend an html parser that works with python (jython 2.2)? HTMLParser does not seem to be in this library. To test some of our browser based (mailnly php) code I seek for field names and values associated with them. Thanks, jh -- http://mail.python.org/mailman/listinfo/python-list
MySQL - Jython2.2
I thought I had a winner mySql-python but it require2 python 2.3-5 and the tool I am using (maxq) is based on jython 2.2. Is there another way that I could perform queries from python? thanx, jh -- http://mail.python.org/mailman/listinfo/python-list
Re printing on same line.
I want to print a count down timer on the same line. I tried print '\r', timeLeft, which just appends to the same line. thanx, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Html parser
Thanks, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Re printing on same line.
... ruining the output? ? None. -- http://mail.python.org/mailman/listinfo/python-list
Re: MySQL - Jython2.2
Thanks, everyone. I will give it a try. Don't know a lot about mySQL (or any flavor SQL) but from some minute exposure to the ODBC connector I am guessing that jdbc provides a connector. Wish me luck jh -- http://mail.python.org/mailman/listinfo/python-list
Moving items from list to list
Just wondered if there was some python idiom for moving a few items from one list to another. I often need to delete 2 or 3 items from one list and put them in another. Delete doesn't seem to have a return value. I don't care which items I get so now I just use a couple of pops or a for loop for more than two. Thanks jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Moving items from list to list
Thanks. That will work. The 2nd, smaller lst starts out empty but this is easily adapted. jh -- http://mail.python.org/mailman/listinfo/python-list
Goto
How does one effect a goto in python? I only want to use it for debug. I dasn't slap an if clause around the portion to dummy out, the indentation police will nab me. Thanx, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Goto
Thanks folks! jh -- http://mail.python.org/mailman/listinfo/python-list
Forgetting an import
I imported a set of functions from a file I wrote to interpreter shell: from myFile import * Now if I change functions in this file how can I make python forget it so I can force a fresh import? thanx, jh -- http://mail.python.org/mailman/listinfo/python-list
List sequential initialization
I thought if I could do this: a = b = '' a = 'a' a 'a' b '' then this would behave similarly: la = lb = [] la.append('a') la ['a'] lb ['a'] I thought wrong! But don't know why. Inquiring minds want to know. thanx, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Forgetting an import
Thanks for the reloads folks. This is a big help as I am running a jython based tool (maxq) and re-starting takes awhile. Can't seem to make reload work using the form from dvTime import So I am prefacing my calls with the module name now. thanx, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: List sequential initialization
Thanks for the explaination. It didn't seem natural and from the tutorial I read: A value can be assigned to several variables simultaneously: x = y = z = 0 # Zero x, y and z Maybe I infer too much thanks again, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Repository - file scanner
Why not use grep? With Windows XP? jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Repository - file scanner
Thank you all. jh -- http://mail.python.org/mailman/listinfo/python-list
Repository - file scanner
Greetings, Could someone point my muddled head at a/the python repository. I know that one exists but cannot find it again. In particular I am looking for a standalone search tool that given a path searches files for a text string. Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
Scope - import and globals
In the file snippet below the value for the global hostName is determined at runtime. Functions imported from the parent baseClass file such as logon also need access to this variable but cannot see it the with the implementation I have attempted here. Also, functions in this file and in the imported parent class need PyHttpTestCase. Does there need to be an import statement in both files? Thanks, jh #~~~ from PyHttpTestCase import PyHttpTestCase from baseClass import baseClass # definition of test class class temp(baseClass): def runTest(self): global hostName hostName = getHostNameFromUser() self.logon() -- http://mail.python.org/mailman/listinfo/python-list
Inheritance
I am trying to understand the 'if' statement and the exec statement in the code below. I would like to add several common routines to this class and then inherit it into a class in another file. This other class would need to access these common functions as well as inherit the PyHttpTestCase class. In particular what is the purpose of the surrounding plus signs? May I assume the if statement overrides an imported assignment statement. Thanks, jh from PyHttpTestCase import PyHttpTestCase from com.bitmechanic.maxq import Config global validatorPkg if __name__ == 'main': validatorPkg = Config.getValidatorPkgName() # Determine the validator for this testcase. exec 'from '+validatorPkg+' import Validator' # definition of test class class baseClass(PyHttpTestCase): def logon() print 'logon()' def runTest(self): print 'runTest()' def myFn(self): print 'myFn()' # Code to load and run the test if __name__ == 'main': test = baseClass(bClass) test.runTest() -- http://mail.python.org/mailman/listinfo/python-list
Re: Declaring variables
On May 16, 6:48 pm, Matimus [EMAIL PROTECTED] wrote: On May 16, 9:57 am, HMS Surprise [EMAIL PROTECTED] wrote: I looked in the language but did not find a switch for requiring variables to be declared before use. Is such an option available? Thanks, jvh You do have to declare a variable before use. You do so by assigning it a value. You can't use a variable before it has been assigned. Yes this is where the problem arises. This is a gross oversimplification , but is where I typically find problems. jh #~~ createdIncidentId = 0 . . . #attempt to change varialbe createdIncidentID = 1 . . . if createdIncidentId == 1: ... -- http://mail.python.org/mailman/listinfo/python-list
Re: Declaring variables
On May 17, 9:34 am, Grant Edwards [EMAIL PROTECTED] wrote: On 2007-05-16, HMS Surprise [EMAIL PROTECTED] wrote: No haven't had to endure Pascal. Mostly C/C++, Tcl, and assembler. I must have you mixed up with somebody else who recently mentioned having Pascal as their first real language. -- Grant Edwards grante Yow! It's OKAY -- I'm an at INTELLECTUAL, too. visi.com That's OK. I am easily mixed up. -- http://mail.python.org/mailman/listinfo/python-list
Re: try
On May 17, 7:51 am, Dustan [EMAIL PROTECTED] wrote: On May 16, 4:22 pm, Robert Kern [EMAIL PROTECTED] wrote: HMS Surprise wrote: I read in the ref man that try-except-finally did not work in earlier versions, I am using jython 2.2. Does this imply that try-except without finally does not work either? I get a syntax error on the else below. Some of the functions embedded in the try section try to convert strings to ints, etc and may fail on bad data, thus try seemed like a good start for a workaround. Thanks, jh #~~ def restoreDevice(self, deviceId, closeTime = time()): self.logon() try: lst = self.getLastUpdatedDevice(deviceId) lastUpdated = lst[0] incidentId = lst[1] print 'L', lastUpdated, 'I', incidentId self.restore(incidentId, lastUpdated) except: else: print couldn't find incident The except: block still needs something in it, even if it is just pass. For sake of demonstration: def restoreDevice(self, deviceId, closeTime = time()): self.logon() try: lst = self.getLastUpdatedDevice(deviceId) lastUpdated = lst[0] incidentId = lst[1] print 'L', lastUpdated, 'I', incidentId self.restore(incidentId, lastUpdated) except: pass else: print couldn't find incident -- Robert Kern I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth. -- Umberto Eco Thanks folks. Found my error but I didn't know of pass option. Wanted to get back in earlier and state I found the error but Google groups seemed to be down for half a day jvh -- http://mail.python.org/mailman/listinfo/python-list
Declaring variables
I looked in the language but did not find a switch for requiring variables to be declared before use. Is such an option available? Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
Re: Declaring variables
No haven't had to endure Pascal. Mostly C/C++, Tcl, and assembler. Oh yeah, and a (thankfully) short stint of Ada. But I glad to hear of the proofing tools. Working a lot of data parsed from web pages and the developer there a different naming convention from what I am accustomed so sometimes I introduce a new variable unintentionally. Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
try
I read in the ref man that try-except-finally did not work in earlier versions, I am using jython 2.2. Does this imply that try-except without finally does not work either? I get a syntax error on the else below. Some of the functions embedded in the try section try to convert strings to ints, etc and may fail on bad data, thus try seemed like a good start for a workaround. Thanks, jh #~~ def restoreDevice(self, deviceId, closeTime = time()): self.logon() try: lst = self.getLastUpdatedDevice(deviceId) lastUpdated = lst[0] incidentId = lst[1] print 'L', lastUpdated, 'I', incidentId self.restore(incidentId, lastUpdated) except: else: print couldn't find incident -- http://mail.python.org/mailman/listinfo/python-list
File record separators.
I need to write 2 member lists to a file. For each record the number of these lists can be different. I think a good way to handle that may be to make each record a list of lists. I am restricted to using version 2.2. That being the case what is a good standard record separator to use to ensure that I read in one record (list of lists) at a time, '\n'? I want to try to stay with what is considered standard python idioms. Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
Re: File record separators.
Thanks folks. Was unaware of enumerate , still have a lot to learn about python. Sorry for the poorly phrased request, but you gathered the gist of it. My wonderment is how to write the following 2 lines and make sure they are saved as separate records or lines so that I pull in only one at a time with readline(?). ['a', 'b'], ['c','d']] [['a', 'b'], ['c','d'], ['e','f']] Would like to use pickle but it is apparently unavailable in the package I am using, Jython 2.2. -- http://mail.python.org/mailman/listinfo/python-list
Splitting a string
The string s below has single and double qoutes in it. For testing I surrounded it with triple single quotes. I want to split off the portion before the first \, but my split that works with shorter strings does not seem to work with this one. Ideas? Thanks, jvh s = D132258\',\'\', \'status=no,location=no,width=630,height=550,left=200,top=100\') target=_blank class=dvLink title=Send an Email to selected employee''' t = s.split('\\') -- http://mail.python.org/mailman/listinfo/python-list
Re: File record separators.
Would like to use pickle but it is apparently unavailable in the package I am using, Jython 2.2. I am pretty sure some version of pickle or cPickle is available in Jython 2.1, though. I'd take a second look, to be sure. Many thanks Boris! import cPickle caused no errors! -- http://mail.python.org/mailman/listinfo/python-list
Re: Splitting a string
I found my problem, the backslash isn't really there. It is just the way it was displayed in the shell after being split from a larger string. Printing it yields D132259','','status=no,location=no,width=630,height=550,left=200,top=100') target=_blank class=dvLink title=Send an Email to selected employee As as opposed to what I got by just typing the variable name in the shell. jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Splitting a string
On May 15, 2:04 pm, Nick Vatamaniuc [EMAIL PROTECTED] wrote: On May 15, 2:28 pm, HMS Surprise [EMAIL PROTECTED] wrote: The string s below has single and double qoutes in it. For testing I surrounded it with triple single quotes. I want to split off the portion before the first \, but my split that works with shorter strings does not seem to work with this one. Ideas? Thanks, jvh s = D132258\',\'\', \'status=no,location=no,width=630,height=550,left=200,top=100\') target=_blank class=dvLink title=Send an Email to selected employee''' t = s.split('\\') jvh, For your split operation to work you would need your string to be in raw format (add an 'r' in front of it). That way all your back slashes won't be interpreted. Or you'll just have to split on ',' instead of '\'. The first '\' is not there technically because it just escapes the ( ' ). So when your actual string just has a quote ( ' ) an not '\'. If it were a raw string, then all your backslashes would have been there. (just print s and see what you get!). s=rD132258\',\'\', : \'status=no,location=no,width=630,height=550,left=200,top=100\') : target=_blank class=dvLink title=Send an Email to selected : employee''' s '\'D132258\\\',\\\'\\\',\n\\ \'status=no,location=no,width=630,height=550,left=200,top=100\\ \')\ntarget=_blank class=dvLink title=Send an Email to selected \nemployee' print s 'D132258\',\'\', \'status=no,location=no,width=630,height=550,left=200,top=100\') target=_blank class=dvLink title=Send an Email to selected employee s.split('\\') ['D132258, ',, ', ',\n, 'status=no,location=no,width=630,height=550,left=200,top=100, '\')\ntarget=_blank class=dvLink title=Send an Email to selected \nemployee'] -Nick Vatamaniuc Thanks Nick. However I do not have the option of putting the r in front of the source string as it comes the function as a variable from another source. Unless it would be permissible to evaluate the concantenation some way. But what you have written is instructive and I appreciate your time. jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Splitting a string
Thanks everyone. The shell's display really threw me off. Don't really understand why it looks different typing t vs print t. Now that I can see past that split works just as advertised. Not real clear on triple quotes but I have seen it used and I can see where triple is needed to differentiate from the usage of double quotes. jvh -- http://mail.python.org/mailman/listinfo/python-list
Name of function caller
Is there a way that a function may access the doc string or func_name of the caller? Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
Re: Name of function caller
On May 15, 5:13 pm, Paul McGuire [EMAIL PROTECTED] wrote: On May 15, 4:59 pm, HMS Surprise [EMAIL PROTECTED] wrote: Is there a way that a function may access the doc string or func_name of the caller? Thanks, jvh Yes. The inspect module allows you to look up the call stack for information on the caller, the caller's caller, local vars, etc. -- Paul Thanks Paul. Running jython 2.2. No module named inspect or cInspect drat... -- http://mail.python.org/mailman/listinfo/python-list
Re: Time
Thanks for posting. I sure am sorry that I wasted your time. I should have started the post stating I am using jython 2.2.3 and apparently it has no datetime module. But I will keep datetime in mind for future reference. Since I had no datetime I cobbled out the following. Seems to work thus far. Posted here for the general amusement of the list. Regards, jvh from time import * s = '05/11/2007 1:23 PM' t = s.split() mdy = t[0].split('/') hrMn = t[1].split(':') if t[2] == 'PM': hrMn[0] = int(hrMn[0]) + 12 tuple =(int(mdy[2]), int(mdy[0]), int(mdy[1]), hrMn[0], int(hrMn[1]), 0,0,0,0) print tuple eTime = mktime(tuple) print 'eTime', eTime -- http://mail.python.org/mailman/listinfo/python-list
Re: Time
if t[2] == 'PM': hrMn[0] = int(hrMn[0]) + 12 Oops, should be: hrMn[0] = int(hrMn[0] if t[2] == 'PM': hrMn[0] += 12 -- http://mail.python.org/mailman/listinfo/python-list
Re: Time
On May 14, 9:09 am, [EMAIL PROTECTED] wrote: On May 14, 9:00 am, HMS Surprise [EMAIL PROTECTED] wrote: Thanks for posting. I sure am sorry that I wasted your time. I should have started the post stating I am using jython 2.2.3 and apparently it has no datetime module. But I will keep datetime in mind for future reference. Since I had no datetime I cobbled out the following. Seems to work thus far. Posted here for the general amusement of the list. Regards, jvh from time import * s = '05/11/2007 1:23 PM' t = s.split() mdy = t[0].split('/') hrMn = t[1].split(':') if t[2] == 'PM': hrMn[0] = int(hrMn[0]) + 12 tuple =(int(mdy[2]), int(mdy[0]), int(mdy[1]), hrMn[0], int(hrMn[1]), 0,0,0,0) print tuple eTime = mktime(tuple) print 'eTime', eTime Since jython works with Java, why not use Java's time/datetime modules? Various links abound. Here are a few: http://www.raditha.com/blog/archives/000552.htmlhttp://www.xmission.com/~goodhill/dates/deltaDates.htmlhttp://www.velocityreviews.com/forums/t149657-find-difference-in-date... Maybe those will give you some hints. Mike Excellent idea. Thanks Mike. jvh -- http://mail.python.org/mailman/listinfo/python-list
Re: Time
On May 14, 9:22 am, HMS Surprise [EMAIL PROTECTED] wrote: if t[2] == 'PM': hrMn[0] = int(hrMn[0]) + 12 Oops, should be: hrMn[0] = int(hrMn[0] if t[2] == 'PM': hrMn[0] += 12 Oops +=1, should be: hrMn[0] = int(hrMn[0] if t[2] == 'PM': hrMn[0] += 12 Need more starter fluid, coffee please!!! -- http://mail.python.org/mailman/listinfo/python-list
Re: Time
Do you mean 12 Noon or 12 Midnight? 12AM and 12PM don't exist, do they? t = (2007, 5, 14, 12, 0,0,0,0,0) strftime('%p', t) 'PM' t = (2007, 5, 14, 0,0,0,0,0,0) strftime('%p', t) 'AM' -- http://mail.python.org/mailman/listinfo/python-list
Class name as argument
Snippet 1 below doesn't do much but works (more code is inserted by a generator). In the next to last line the class name is also used as argument. I have seen this construct before and have had error messages tell me that the name is expected. Why is this so? In snippet 2 that I concocted is not required. Is it related to __init__ perhaps? Thanks, jvh # Snippet 1 ~~~ from PyHttpTestCase import PyHttpTestCase # definition of test class class MaxQTest(PyHttpTestCase): def runTest(self): self.msg('Test started') # ^^^ Insert new recordings here. (Do not remove this line.) # Code to load and run the test if __name__ == 'main': test = MaxQTest(MaxQTest) test.Run() # Snippet 2 ~~~ class topClass(): str = 'abc' def tcMsg(self): print 'topClass tcMsg' class one(topClass): strOne = 'class one' def classOneFun(self): print 'this is classOneFun' self.tcMsg() if __name__ == 'main': test = one() test.classOneFun() -- http://mail.python.org/mailman/listinfo/python-list
Better way to isolate string
Greetings. Given the string s below and using only python built-in capabilities, I am trying to isolate the substring G132153. This string may have any number of digits but the pieces around it will not change. I have accomplished this with split but there must be a more elegant and compact way to do this. s ='a href=../active/Group_Detail.php?GroupID=G132153SvcType=1AType=V class=dvLinkG132153/a' t = s.split('') u = t[-1].split('') v = u[0] v 'G132153' Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
Re: Better way to isolate string
I suppose a one liner would look better, but I am alway leery of these things 'breaking'. t = s.split('')[-1].split('')[0] s ='a href=../active/Group_Detail.php? GroupID=G132153SvcType=1AType=V class=dvLinkG132153/a' jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Better way to isolate string
On May 11, 10:45 am, Tim Golden [EMAIL PROTECTED] wrote: HMS Surprise wrote: I suppose a one liner would look better, but I am alway leery of these things 'breaking'. t = s.split('')[-1].split('')[0] s ='a href=../active/Group_Detail.php? GroupID=G132153SvcType=1AType=V class=dvLinkG132153/a' Only if you're competing in an obscurity competition ;) If you're really confined to built-ins (ie you can't import a single module) then just go with your original solution. Why not? If you can import modules, then you want to look at the urlparser and cgi modules, I suspect. TJG Thanks for replying Tim. Good point. jh -- http://mail.python.org/mailman/listinfo/python-list
Re: File modes
On May 10, 7:11 pm, Jon Pentland [EMAIL PROTECTED] wrote: I don't really see the use for being able to do that. Have you tried Well, I think I found a reason and it probably happens quite a bit. I open the file and read it into a list. I pop some elements from the list for processing and then write the shortened list back to disk to be available for other functions to access later, where later varies from seconds to days. There is no need to keep the file open till after the processing so I wish to write/flush/close right away. jvh -- http://mail.python.org/mailman/listinfo/python-list
File writing success
If file writing has no return value (http://docs.python.org/lib/bltin- file-objects.html), how do you know if the write was successful? Should one assume that if the open was successful then write are also? Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
Time
I need to convert the string below into epoch seconds so that I can perform substractions and additions. I assume I will need to break it up into a time_t struct and use mktime. Two questions if you will please: Is there a way to use multiple separator characters for split similar to awk's [|] style? Could you point to an example of a python time_t struct? 05/11/2007 15:30 Thanks, jvh -- http://mail.python.org/mailman/listinfo/python-list
Re: Time
Could you point to an example of a python time_t struct? Or maybe that should be a tm struct??? -- http://mail.python.org/mailman/listinfo/python-list
Re: Time
Sorry, reading a little closer I see that the time tuple is apparently an ordinary list. jvh -- http://mail.python.org/mailman/listinfo/python-list
append
Trying not to be a whiner but I sure have trouble finding syntax in the reference material. I want to know about list operations such as append. Is there a pop type function? I looked in tutorial, language reference, and lib for list, append, sequence. Is there a place where us doofi ( who may not have our heads out in the sunlight) may find all related syntax grouped together? thanx, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: append
Found list popping at http://en.wikibooks.org/wiki/Python_Programming/Lists :) -- http://mail.python.org/mailman/listinfo/python-list
Re: append
Do you really mean syntax? Thought so? A few sources I bookmarked to avoid future google two-steps. http://www.diveintopython.org/native_data_types/lists.html http://en.wikibooks.org/wiki/Python_Programming/Lists http://infohost.nmt.edu/tcc/help/pubs/python22.pdf Thank you all. jh -- http://mail.python.org/mailman/listinfo/python-list
File modes
After reading a file is it possible to write to it without first closing it? I tried opening with 'rw' access and re-winding. This does not seem to work unless comments are removed. Also, does close force a flush? Thanks, jh #~~ f = open('c:\\tempMaxq\\incidents.txt', 'rw') s = f.read() lst = s.split() incId = [] incId.extend([lst.pop(), lst.pop()]) #f.close() #f = open('c:\\tempMaxq\\incidents.txt', 'w') #f.seek(0) for el in lst: f.write(el + ' ') f.close() -- http://mail.python.org/mailman/listinfo/python-list
Re: String parsing
This looks to be simple HTML (and I'm presuming that's a type on that ? ending). A quick glance at the Python library reference (you do have a copy, don't you) reveals at least two HTML parsing modules... No that is not a typo and bears investigation. Thanks for the find. I found HTMLParser but had trouble setting it up. About five minutes work gave me this: My effort has been orders of magnitude greater in time. Thanks all for all the excellent suggestions. jh -- http://mail.python.org/mailman/listinfo/python-list
Re: String parsing
BTW, here's what I used, the other ideas have been squirreled away in my neat tricks and methods folder. for el in data.splitlines(): if el.find('LastUpdated') -1: s = el.split(=)[-1].split('')[1] print 's:', s Thanks again, jh -- http://mail.python.org/mailman/listinfo/python-list
input
Just wanted a input routine that would let me pause my jython program until I press enter. Searched tutorial, lang ref, and lib and found input and raw_input. Both hang the program and it must be killed. s = raw_input('-- ') What has Mr Duh done wrong now? jh -- http://mail.python.org/mailman/listinfo/python-list
File I/O
If one has a list of lists such as lst = [['a','1'],['b','2']] is there a standard python idiom for writing and reading the pairs to/ from a file? Thanks, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: File I/O
[lst.append(list(line.split())) for line in file] Thanks, this is the direction I wanted to go, BUT I must use v2.2 so the line above gives me the error: AttributeError: __getitem__ But the write format will be helpful. Thanks again, jh -- http://mail.python.org/mailman/listinfo/python-list
EOL character
I have two files apparently identical until I open them with winMerge which reports that they use different EOL characters. They are both jython scripts built using the maxq tool. When the one would not work I stripped it down to bare minimums and then duplicated it. The duplicate works, the original gives an error message stating method closeInc not found. Parts of the original file may have been edited in a python shell, notepad, or even openOffice writer. Thought all would use the Windows default. Your thoughts please. Thanks, jh #Works: # Generated by MaxQ [com.bitmechanic.maxq.generator.JythonCodeGenerator] from PyHttpTestCase import PyHttpTestCase from com.bitmechanic.maxq import Config global validatorPkg if __name__ == 'main': validatorPkg = Config.getValidatorPkgName() # Determine the validator for this testcase. exec 'from '+validatorPkg+' import Validator' class closeInc(PyHttpTestCase): print 'closeInc' def runTest(self): print 'runTest' # ^^^ Insert new recordings here. (Do not remove this line.) # Code to load and run the test if __name__ == 'main': test = closeInc(closeInc) test.runTest() # #Doesn't work. # Generated by MaxQ [com.bitmechanic.maxq.generator.JythonCodeGenerator] from PyHttpTestCase import PyHttpTestCase from com.bitmechanic.maxq import Config global validatorPkg if __name__ == 'main': validatorPkg = Config.getValidatorPkgName() # Determine the validator for this testcase. exec 'from '+validatorPkg+' import Validator' class closeInc(PyHttpTestCase): print 'closeInc' def runTest(self): print 'runTest' # ^^^ Insert new recordings here. (Do not remove this line.) # Code to load and run the test if __name__ == 'main': test = closeInc(closeInc) test.runTest() -- http://mail.python.org/mailman/listinfo/python-list
Re: No module named urllib
On May 7, 6:54 pm, Carsten Haese [EMAIL PROTECTED] wrote: On Mon, 2007-05-07 at 16:24 -0700, HMS Surprise wrote: Since sys.path = ['.', 'C:\\maxq\\lib\\Lib', 'C:\\maxq\\jython'] I copied urllib to c:\maxq\lib\Lib. Now I get the error - Traceback (innermost last): File string, line 5, in ? File C:\maxq\lib\Lib\urllib.py, line 1148 _hextochr = dict(('%02x' % i, chr(i)) for i in range(256)) ^ SyntaxError: invalid syntax The urllib.py you're using is not compatible with the Python you're using. The snippet above uses Python 2.4+ syntax, and Jython's syntax is at 2.1 (stable) or 2.2 (beta). -- Carsten Haesehttp://informixdb.sourceforge.net Thanks for posting. How does one ensure (or even detect) that their libraries are compatible? I loaded this library as part of Python 2.5. Thanks, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: No module named urllib
To summarize the summary, are you sure you need to use Jython instead of standard CPython? Thanks for all your help Carsten, you have been more than patient with me. To answer your question I must admit I do not know. I am trying to use a tool called maxq (maxq.tigris.org) that has limited documentation, or limited in the depth needed by a python/jython neophyte such as me. Maxq acts an http proxy and generates jython scripts for playback testing of web apps. So far I have gained a lot of ground referring to python documentation and even testing code snippets in python shells. So lacking the knowledge of what is jython/maxq/python and being of at best moderate intellect I find myself easily overwhelmed and generally not sure what must be used where. Maxq does not have a tool for parsing the web pages, therefore I wanted to add some library calls to pick off some timestamps I must have. Perhaps I should start looking for another tool, such as twill maybe. I will fetch an older python and see if that helps. Thanks again, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: No module named urllib
On May 8, 9:13 am, HMS Surprise [EMAIL PROTECTED] wrote: To summarize the summary, are you sure you need to use Jython instead of standard CPython? Thanks for all your help Carsten, you have been more than patient with me. To answer your question I must admit I do not know. I am trying to use a tool called maxq (maxq.tigris.org) that has limited documentation, or limited in the depth needed by a python/jython neophyte such as me. Maxq acts an http proxy and generates jython scripts for playback testing of web apps. So far I have gained a lot of ground referring to python documentation and even testing code snippets in python shells. So lacking the knowledge of what is jython/maxq/python and being of at best moderate intellect I find myself easily overwhelmed and generally not sure what must be used where. Maxq does not have a tool for parsing the web pages, therefore I wanted to add some library calls to pick off some timestamps I must have. Perhaps I should start looking for another tool, such as twill maybe. I will fetch an older python and see if that helps. Thanks again, jh Thanks again, Carsten. Using v2.2.3 got me past the urllib error. jh -- http://mail.python.org/mailman/listinfo/python-list
sys.path
Is sys.path setup differnently in jython vs python? I have environment variables pythonpath and jythonpath set to include C:\python22 but the initial printout indicates it is being ignored. Also when I used sys.path.extend, the added pathname shows up as a series of single characters. Have I misused .extend? Thanks, jh import sys print sys.path sys.path.extend(c:\python22) print sys.path import urllib ['.', 'C:\\maxq\\lib\\Lib', 'C:\\maxq\\jython'] ['.', 'C:\\maxq\\lib\\Lib', 'C:\\maxq\\jython', 'c', ':', '\\', 'p', 'y', 't', 'h', 'o', 'n', '2', '2'] Traceback (innermost last): File string, line 9, in ? ImportError: no module named urllib -- http://mail.python.org/mailman/listinfo/python-list
Atttribute error
The snippet below causes an attribute error. AttributeError: module 'urllib' has no attribute 'urlopen' I am using python 2.2.3. According to the documentation at C: \Python22\Doc\lib urllib has a function called urlopen. #~~~ import urllib class login(CompactTest): # Recorded test actions. def runTest(self): f = urllib.urlopen(http://www.python.org/;) f.read() -- http://mail.python.org/mailman/listinfo/python-list
Re: sys.path
On May 8, 10:40 am, Klaus Alexander Seistrup [EMAIL PROTECTED] wrote: HMS Surprise wrote: Have I misused .extend? The .extend() method expects an iterable, try .append() instead. Cheers, -- Klaus Alexander Seistruphttp://klaus.seistrup.dk/ Thanks Klaus. That certainly cleaned up sys.path. Now if I can get the system to search there for my lib file. -- http://mail.python.org/mailman/listinfo/python-list
Re: Atttribute error
On May 8, 11:37 am, Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote: In [EMAIL PROTECTED], HMS Surprise wrote: The snippet below causes an attribute error. AttributeError: module 'urllib' has no attribute 'urlopen' I am using python 2.2.3. According to the documentation at C: \Python22\Doc\lib urllib has a function called urlopen. Do you have a file called `urllib.py` in the current directory? Then this gets imported instead of the module in the standard library. Add this directly after the ``import`` to see what's happening: print urllib.__file__ print dir(urllib) Ciao, Marc 'BlackJack' Rintsch Thanks for posting Marc. I do have a file named `urllib.py` in the current directory. I copied it from 'C:\Python22\Lib' as I could not get rid of the 'no module named urllib' error message, even though I appended 'C:\Python22\Lib to sys.path'. This changed the error from module not found to a no attribute msg. The maxq program (IDE?, runtime enviroment? , shell?) apparently uses jython so maybe sys.path is not the problem. This is the reason for my thread 'sys.path'. Thanks again, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: Atttribute error
PS Add this directly after the ``import`` to see what's happening: print urllib.__file__ print dir(urllib) C:\maxq\bin\testScripts\.\urllib.py ['__doc__', '__file__', '__name__', 'string'] -- http://mail.python.org/mailman/listinfo/python-list
Re: No module named urllib
Great idea Dennis, I will look into that. Thanks, jh -- http://mail.python.org/mailman/listinfo/python-list
chdir()
Tried executing os.chdir(c:\twill) from a python Tk shell and got the error message: WindowsError: [Error 123] The filename, directory name, or volume label syntax is incorrect: 'c:\twill'. I have the directory exists as I copied the name from the explorer window that was open to it. What is wrong with the syntax? thanks, jh -- http://mail.python.org/mailman/listinfo/python-list
Re: chdir()
On May 8, 3:06 pm, Carsten Haese [EMAIL PROTECTED] wrote: On Tue, 2007-05-08 at 12:54 -0700, HMS Surprise wrote: Tried executing os.chdir(c:\twill) from a python Tk shell and got the error message: WindowsError: [Error 123] The filename, directory name, or volume label syntax is incorrect: 'c:\twill'. Backslash-t is a tab character, so you're trying to chdir to C:tabwill, which is not a valid path name. Use a forward slash, double up the backslash, or use a raw string literal: os.chdir(c:/twill) os.chdir(c:\\twill) os.chdir(rc:\twill) HTH, -- Carsten Haesehttp://informixdb.sourceforge.net Thanks all. Windows bytes me again. I know better just wasn't thinking. \n -- http://mail.python.org/mailman/listinfo/python-list
Another easy pair of questions
In a python Tk shell in Windows, what is the equivalent of unix's pwd? In a python Tk shell in Windows, is there an easy way to reoeat an earlier command, similar to Tcl/Tk's hist? -- http://mail.python.org/mailman/listinfo/python-list
Re: Another easy pair of questions
Press the cursor-up key. Martin Should have mentioned that I tried that hunting around earlier and it did not work. jh -- http://mail.python.org/mailman/listinfo/python-list
String parsing
The string below is a piece of a longer string of about 2 characters returned from a web page. I need to isolate the number at the end of the line containing 'LastUpdated'. I can find 'LastUpdated' with .find but not sure about how to isolate the number. 'LastUpdated' is guaranteed to occur only once. Would appreciate it if one of you string parsing whizzes would take a stab at it. Thanks, jh input type=hidden name=RFP value=-1/ !--input type=hidden name=EnteredBy value=john/-- input type=hidden name=EnteredBy value=john/ input type=hidden name=ServiceIndexvalue=1/ input type=hidden name=LastUpdated value=1178658863/ input type=hidden name=NextPagevalue=../active/active.php/ input type=hidden name=ExistingStatus value=10 ? table width=98% cellpadding=0 cellspacing=0 border=0 align=center -- http://mail.python.org/mailman/listinfo/python-list