| Author |
Message |
|
jay (support)
Site Admin
Joined: Mar 19, 2008 Posts: 6659 Location: Austin, Texas
|
 Re: NOAA script timing out again...
HighwayStar wrote:Not as far as I know, I don't remember changing anything. Email notifications are working as is everything else network/internet related. The script's worked since Jul/Aug but my last update is Sun the 8th @ 6:51pm. Nothing since. I restarted the server, reloaded attachments, to no avail. Is there anything specific (network related) I should check ?
Hmmm. Nothing specific off the top of my head. You haven't upgraded or changed any configurations on your machine in that time?
_________________ Jay (Indigo Support)
|
| Mon Mar 16, 2009 9:06 am |
|
 |
|
HighwayStar
Joined: Sep 07, 2005 Posts: 82 Location: NY
|
 Re: NOAA script timing out again...
jay wrote: Hmmm. Nothing specific off the top of my head. You haven't upgraded or changed any configurations on your machine in that time?
I did check my Indigo server preferences for my W800RF32 but don't remember changing anything. I was having trouble with one motion detector. But you're right, something's definitely broken. When I go into the Mac's System Preferences, Network, I get a drop down stating "Your network settings have been changed by another application". I click OK and it just keeps coming back till I have to force quit. Doesn't matter if the Indigo server is up or down. And I definitely haven't installed any new software. Any idea what could be causing this ? Or what to do about it ?
|
| Mon Mar 16, 2009 9:28 am |
|
 |
|
jay (support)
Site Admin
Joined: Mar 19, 2008 Posts: 6659 Location: Austin, Texas
|
 Re: NOAA script timing out again...
HighwayStar wrote:But you're right, something's definitely broken. When I go into the Mac's System Preferences, Network, I get a drop down stating "Your network settings have been changed by another application". I click OK and it just keeps coming back till I have to force quit. Doesn't matter if the Indigo server is up or down. And I definitely haven't installed any new software. Any idea what could be causing this ? Or what to do about it ?
Assuming a reboot doesn't help, I'd run Disk Utility and see if it finds any problems. Sometimes permissions get munged on OS X systems and very odd behavior can result.
_________________ Jay (Indigo Support)
|
| Mon Mar 16, 2009 9:50 am |
|
 |
|
HighwayStar
Joined: Sep 07, 2005 Posts: 82 Location: NY
|
 Re: NOAA script timing out again...
jay wrote: Assuming a reboot doesn't help, I'd run Disk Utility and see if it finds any problems. Sometimes permissions get munged on OS X systems and very odd behavior can result.
Reboots didn't help. Verifying permissions found a slew of errors and I ran a repair. Looked good but didn't make any difference with the System Preferences Network problem. The W800RF32 is working fine, so I doubt I changed anything in the Indigo server preferences. What gets me is I don't run much else on this box aside from Indigo & occasionally Mail. Pretty much it's Indigo 3.01 running on OS X 10.4.11 on a 700mhx G3. The machine's hardly touched. If you have any other ideas I'd really appreciate it.
|
| Mon Mar 16, 2009 10:43 am |
|
 |
|
berkinet
Joined: Nov 18, 2008 Posts: 1721 Location: Berkeley, CA
|
#1. It seems (I pasted the noaa URL into a browser), that the base URL has changed from:
www.nws.noaa.gov/ data/current_obs/
to:
www.nws.noaa.gov/ xml/current_obs/
So, you may need to change that in your script. Or...
I have replaced URL Access Scripting with curl in the latest version of the wunderground script.
For the noaa script, I think (I.e. only quickly tested) you would replace
- Code: Select all
tell application "URL Access Scripting" download "http://www.nws.noaa.gov/data/current_obs/" & stationID & ".xml" to file myFile replacing yes -- work around -31040 error: tell application "URL Access Scripting" to quit end tell
with - Code: Select all
do shell script "/usr/bin/curl -s -S -m " & webQueryTimeout & " http://www.nws.noaa.gov/xml/current_obs/" & stationID & ".xml >" & myFile
Richard
|
| Mon Mar 16, 2009 10:47 am |
|
 |
|
jay (support)
Site Admin
Joined: Mar 19, 2008 Posts: 6659 Location: Austin, Texas
|
 Re: NOAA script timing out again...
HighwayStar wrote:Reboots didn't help. Verifying permissions found a slew of errors and I ran a repair. Looked good but didn't make any difference with the System Preferences Network problem. The W800RF32 is working fine, so I doubt I changed anything in the Indigo server preferences. What gets me is I don't run much else on this box aside from Indigo & occasionally Mail. Pretty much it's Indigo 3.01 running on OS X 10.4.11 on a 700mhx G3. The machine's hardly touched. If you have any other ideas I'd really appreciate it.
Can't think of anything else offhand - the error you're seeing in the Network System Preferences is really puzzling (not sure it has anything to do with the URL Access Scripting issue or not, but it's awful suspicious.
The next obvious thing to try is reinstalling the OS - not sure if the weather script is that important to you... 
_________________ Jay (Indigo Support)
|
| Mon Mar 16, 2009 11:19 am |
|
 |
|
HighwayStar
Joined: Sep 07, 2005 Posts: 82 Location: NY
|
Thank you Richard. But my NOAA script appears to be working now. I think it it might have come back to life when I first encountered the "network settings changed by another application" error. I have no clue what's causing it or why I'm unable to clear it (aside from a force quit). There really aren't any other applications running on this box.
But the script is updating again and I didn't touch it or change the URL.
I just can't go into System Preferences/Network without getting an endless series of the error above and having to force quit System Preferences.
|
| Mon Mar 16, 2009 11:20 am |
|
 |
|
jay (support)
Site Admin
Joined: Mar 19, 2008 Posts: 6659 Location: Austin, Texas
|
berkinet wrote:#1. It seems (I pasted the noaa URL into a browser), that the base URL has changed from: www.nws.noaa.gov/data/current_obs/ to: www.nws.noaa.gov/xml/current_obs/
They've got a redirect in place that makes the old URL work correctly (mine's still pointing to the old data directory).
I've not tried the curl approach, but it certainly might work. You could try it from the command line and if it works then that would point to a problem with the URL Access Scripting Scripting Addition.
_________________ Jay (Indigo Support)
|
| Mon Mar 16, 2009 11:23 am |
|
 |
|
HighwayStar
Joined: Sep 07, 2005 Posts: 82 Location: NY
|
 Re: NOAA script timing out again...
jay wrote:Can't think of anything else offhand - the error you're seeing in the Network System Preferences is really puzzling (not sure it has anything to do with the URL Access Scripting issue or not, but it's awful suspicious. The next obvious thing to try is reinstalling the OS - not sure if the weather script is that important to you... 
LOL, Jay, I'd have to find the disks first... And the script is now working, although I've got a much bigger problem.
I guess if I ever need to change anything in Network, I better find those disks.
Thank you for your time & assistance.
Ken
|
| Mon Mar 16, 2009 11:25 am |
|
 |
|
berkinet
Joined: Nov 18, 2008 Posts: 1721 Location: Berkeley, CA
|
 Re: NOAA script timing out again...
HighwayStar wrote: When I go into the Mac's System Preferences, Network, I get a drop down stating "Your network settings have been changed by another application".
Is this on Tiger? I *think* this is a known bug. It has to do with permissions. Try going into the Security control panel and check (or uncheck) require password to unlock each system preference. Take a look at this thread on MacFixit for more help.
Richard
|
| Mon Mar 16, 2009 1:02 pm |
|
 |
|
berkinet
Joined: Nov 18, 2008 Posts: 1721 Location: Berkeley, CA
|
jay wrote:I've not tried the curl approach, but it certainly might work. You could try it from the command line and if it works then that would point to a problem with the URL Access Scripting Scripting Addition.
In my case, curl did work at times when applescript was having problems.
In addition, curl has some nice options, like max-session and max-connect tiime-outs, that avoid a lot of applescript. As an added bonus, once you call a shell script you can easily pipe the output of curl into a chain of commands to grab the data you need: typically a series of grep, cut, tr etc. That also helps avoid a lot of fragile applescript code for manipulating text. The only real downside is sometimes it can be a real pain to get character quoting for special characters ["., etc] right in the applescript.
Richard
|
| Mon Mar 16, 2009 1:16 pm |
|
 |
|
HighwayStar
Joined: Sep 07, 2005 Posts: 82 Location: NY
|
 Re: NOAA script timing out again...
berkinet wrote: Is this on Tiger? I *think* this is a known bug. It has to do with permissions. Try going into the Security control panel and check (or uncheck) require password to unlock each system preference. Take a look at this thread on MacFixit for more help. Richard
Richard, I cannot thank you enough. Unbelievable. The MacFixit thread was quite enlightening. Straightened me right out.
Thank you again, your help was invaluable. Have a great day !
Ken
|
| Mon Mar 16, 2009 2:06 pm |
|
 |
|
jamus
Joined: Dec 01, 2007 Posts: 177
|
FYI, I was getting a URL Access Scripting got an error: AppleEvent timed out.(-1712) with the NOAA script and another script that uses URL Access Scripting.
The scripts have a "tell application to quit", but in my case, URL Access Scripting locked up hard, requiring me to force quit it via Activity Monitor. Once I did that, both scripts were working fine.
|
| Mon Jul 20, 2009 9:50 am |
|
 |
|
artpics
Joined: Feb 24, 2009 Posts: 156 Location: Calabasas CA
|
berkinet wrote:For the noaa script, I think (I.e. only quickly tested) you would replace - Code: Select all
tell application "URL Access Scripting" download "http://www.nws.noaa.gov/data/current_obs/" & stationID & ".xml" to file myFile replacing yes -- work around -31040 error: tell application "URL Access Scripting" to quit end tell
with - Code: Select all
do shell script "/usr/bin/curl -s -S -m " & webQueryTimeout & " http://www.nws.noaa.gov/xml/current_obs/" & stationID & ".xml >" & myFile
Richard
Thanks again it worked for me on snow leopard 
|
| Wed Sep 16, 2009 8:04 pm |
|
 |
|
DataBoy
Joined: Jun 08, 2005 Posts: 2 Location: Richardson, Tx
|
 NOAA Weather
I'm getting this error when I run the script. OSX 10.5.8 on a mini duo.
Sep 18, 2009 4:49:59 PM
Trigger Action NOAA Weather trigger
Weather NOAA SendToIndigo:IndigoServer got an error: A descriptor type mismatch occurred.(-10001)
|
| Fri Sep 18, 2009 4:23 pm |
|
|