Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.acorn.programmer > #500 > unrolled thread
| Started by | Martin Bazley <martin.bazley@blueyonder.co.uk> |
|---|---|
| First post | 2011-07-04 21:44 +0100 |
| Last post | 2011-07-08 17:14 +0200 |
| Articles | 18 on this page of 38 — 17 participants |
Back to article view | Back to comp.sys.acorn.programmer
Task Obey madness Martin Bazley <martin.bazley@blueyonder.co.uk> - 2011-07-04 21:44 +0100
Re: Task Obey madness Vince M Hudd <vinceh@softrock.co.uk> - 2011-07-04 22:35 +0100
Re: Task Obey madness "John Williams (News)" <UCEbin@tiscali.co.uk> - 2011-07-05 08:07 +0200
Re: Task Obey madness Rob Davison <nospamthanks@invalid.invalid> - 2011-07-05 19:59 +1200
Re: Task Obey madness Paul Sprangers <Paul@sprie.nl> - 2011-07-05 10:28 +0200
Re: Task Obey madness "John Williams (News)" <UCEbin@tiscali.co.uk> - 2011-07-05 12:08 +0200
Re: Task Obey madness Vince M Hudd <vinceh@softrock.co.uk> - 2011-07-05 11:36 +0100
Re: Task Obey madness Paul Sprangers <Paul@sprie.nl> - 2011-07-05 12:43 +0200
Re: Task Obey madness "John Williams (News)" <UCEbin@tiscali.co.uk> - 2011-07-05 12:51 +0200
Re: Task Obey madness Ian Hamilton <Ian.Hamilton@AAUG.net> - 2011-07-05 12:03 +0100
Re: Task Obey madness "John Williams (News)" <UCEbin@tiscali.co.uk> - 2011-07-05 13:32 +0200
Re: Task Obey madness Vince M Hudd <vinceh@softrock.co.uk> - 2011-07-05 12:57 +0100
Re: Task Obey madness "John Williams (News)" <UCEbin@tiscali.co.uk> - 2011-07-05 14:17 +0200
Re: Task Obey madness Paul Sprangers <Paul@sprie.nl> - 2011-07-05 14:39 +0200
Re: Task Obey madness Vince M Hudd <vinceh@softrock.co.uk> - 2011-07-05 12:22 +0100
Re: Task Obey madness Rob Davison <nospamthanks@invalid.invalid> - 2011-07-06 08:27 +1200
Re: Task Obey madness Rick Murray <heyrickmail-usenet@yahoo.co.uk> - 2011-07-06 08:15 +0200
Re: Task Obey madness jgharston <jgh@arcade.demon.co.uk> - 2011-07-06 18:48 -0700
Re: Task Obey madness "Ste (news)" <steve@revi11.plus.com> - 2011-07-07 13:55 +0100
Re: Task Obey madness Rick Murray <heyrickmail-usenet@yahoo.co.uk> - 2011-07-12 20:07 +0200
Re: Task Obey madness cferris@freeRemoveuk.com.invalid - 2011-07-05 09:09 +0100
Re: Task Obey madness Steve Drain <steve@kappa.me.uk> - 2011-07-05 10:19 +0100
Re: Task Obey madness Martin Bazley <martin.bazley@blueyonder.co.uk> - 2011-07-05 12:40 +0100
Re: Task Obey madness Martin <News03@avisoft.f9.co.uk> - 2011-07-05 16:19 +0100
Re: Task Obey madness Alan Adams <alan@adamshome.org.uk> - 2011-07-05 17:31 +0100
Re: Task Obey madness Ian J Hartley <Ian.Hartley@sky.com> - 2011-07-06 12:35 +0100
Re: Task Obey madness "Ste (news)" <steve@revi11.plus.com> - 2011-07-07 13:57 +0100
Re: Task Obey madness Alan Adams <alan@adamshome.org.uk> - 2011-07-07 21:18 +0100
Re: Task Obey madness Ian J Hartley <Ian.Hartley@sky.com> - 2011-07-13 12:36 +0100
Re: Task Obey madness "Ste (news)" <steve@revi11.plus.com> - 2011-07-14 15:58 +0100
Re: Task Obey madness Ian Hamilton <Ian.Hamilton@AAUG.net> - 2011-07-14 16:10 +0100
Re: Task Obey madness Ian J Hartley <Ian.Hartley@sky.com> - 2011-07-17 12:30 +0100
Re: Task Obey madness "Ste (news)" <steve@revi11.plus.com> - 2011-07-17 14:23 +0100
Re: Task Obey madness Ian J Hartley <Ian.Hartley@sky.com> - 2011-07-17 16:14 +0100
Re: Task Obey madness druck <news@druck.org.uk> - 2011-07-14 19:23 +0100
Re: Task Obey madness Ian J Hartley <Ian.Hartley@sky.com> - 2011-07-17 14:17 +0100
Re: Task Obey madness Jeremy Nicoll - news posts <jn.nntp.scrap007@wingsandbeaks.org.uk> - 2011-07-05 22:15 +0100
Re: Task Obey madness Rainer Schubert <dl6hbo@dl6hbo.inka.de> - 2011-07-08 17:14 +0200
Page 2 of 2 — ← Prev page 1 [2]
| From | cferris@freeRemoveuk.com.invalid |
|---|---|
| Date | 2011-07-05 09:09 +0100 |
| Message-ID | <5f0cefed51.cferris@cferris.freeuk.com> |
| In reply to | #502 |
In message <51ede3e23cUCEbin@tiscali.co.uk>
"John Williams (News)" <UCEbin@tiscali.co.uk> wrote:
> In article <mpro.lntvzt002odox02pg.vinceh@softrock.co.uk>,
> Vince M Hudd <vinceh@softrock.co.uk> wrote:
>
> > Throw sensible checks around any CLOSE commands - only issue the
> > CLOSE if the handle isn't 0 (and then set that handle *to* 0).
>
> I particularly agree with that bit that Vince offers. So I'll repeat
> it for emphasis
>
> Only close a file if the handle is not zero, and when you do, set the
> handle to zero. Make it a habit!
>
> Do the same particularly in your error routine.
>
Something like :-
*******
FileNo%= 10
IF FileNo% THEN VDU 7:REM CLOSE FileNo%
*******
--
Colin Ferris Cornwall UK
[toc] | [prev] | [next] | [standalone]
| From | Steve Drain <steve@kappa.me.uk> |
|---|---|
| Date | 2011-07-05 10:19 +0100 |
| Message-ID | <cHAQp.18674$29.12886@newsfe08.ams2> |
| In reply to | #504 |
cferris wrote: > John Williams wrote: >> Vince M Hudd wrote: >>> Throw sensible checks around any CLOSE commands - only issue the >>> CLOSE if the handle isn't 0 (and then set that handle *to* 0). >> I particularly agree with that bit that Vince offers. So I'll repeat >> it for emphasis >> Only close a file if the handle is not zero, and when you do, set the >> handle to zero. Make it a habit! >> Do the same particularly in your error routine. > Something like :- I cannot resist mentioning that Basalt addressed this problem way back. The keyword CLOSE is made 'safe' in just the way described. It makes TIME 'safe' as well. ;-) Steve
[toc] | [prev] | [next] | [standalone]
| From | Martin Bazley <martin.bazley@blueyonder.co.uk> |
|---|---|
| Date | 2011-07-05 12:40 +0100 |
| Message-ID | <2a5e02ee51.martin@blueyonder.co.uk> |
| In reply to | #501 |
The following bytes were arranged on 4 Jul 2011 by Vince M Hudd : > I'm inclined to say that what you're seeing is a classic 'close all' > symptom. i.e. it looks like *something* on your system(s) is trying to close > a file with a handle of 0. That might explain the initial crash, but certainly not the following insanity. > I'd start by checking the programs involved: You mention where the OPENOUT > commands are - but what about the CLOSE commands? Are they equally 'deep' in > the BASIC and are you absolutely sure one isn't being issued where an > equivalent OPENOUT hasn't already been issued, so the handle is therefore 0? > Throw sensible checks around any CLOSE commands - only issue the CLOSE if > the handle isn't 0 (and then set that handle *to* 0). Beat you to it, I'm afraid - having been bitten by this many times in the past, I have all CLOSE statements in a procedure called PROCclose, which does this: DEF PROCclose IF h%<>0 CLOSE#h%:h%=0:SYS "OS_File",18,out$,filetype% IF s%<>0 CLOSE#s%:s%=0:SYS "OS_File",6,sout$ IF p%<>0 CLOSE#p%:p%=0:SYS "OS_File",6,pout$ ENDPROC The first three lines in the file are: ON ERROR REPORT:PRINT " at line ";ERL:END h%=0:s%=0:p%=0 ON ERROR:ON ERROR OFF:PROCclose:ERROR EXT ERR,REPORT$+" at line "+STR$ERL The only other place PROCclose is called is after conversion is complete. And PROCclose most certainly isn't being called before the program terminates, because the files are left open! > Having said that, it doesn't necessarily have to be the programs you are > experiencing problems with that are doing this - it could be something else > entirely; What else changed around the time the problem started - did you > install anything at that point? Not that I'm aware of! The only possible culprit is a recent test build of NetSurf, which is the only thing I've downloaded recently, and installed on both computers. It may well have been running at the time. -- __<^>__ === RISC OS is a work of art. Some people adore it, === / _ _ \ === others can't see the point of it, and it's really === ( ( |_| ) ) === expensive. === \_> <_/ ======================= Martin Bazley ===================
[toc] | [prev] | [next] | [standalone]
| From | Martin <News03@avisoft.f9.co.uk> |
|---|---|
| Date | 2011-07-05 16:19 +0100 |
| Message-ID | <51ee1665a1News03@avisoft.f9.co.uk> |
| In reply to | #515 |
On 05 Jul, in article <2a5e02ee51.martin@blueyonder.co.uk>, Martin Bazley <martin.bazley@blueyonder.co.uk> wrote: > And PROCclose most certainly isn't being called before the program > terminates, because the files are left open! You seem to have eliminated the CLOSE#0 suggestion from within your program. But that leaves you with the question 'how did the program terminate without calling PROCclose?' which is really 'where the hell DID the program go?' ! <plug>Sounds like a case for Reporter to me!</plug> But as you are running several instances of the program, you may need to be able to identify which *Report is which, eg by listing the parms when it starts? Martin -- Martin Avison Note that unfortunately this email address will become invalid without notice if (when) any spam is received.
[toc] | [prev] | [next] | [standalone]
| From | Alan Adams <alan@adamshome.org.uk> |
|---|---|
| Date | 2011-07-05 17:31 +0100 |
| Message-ID | <ecf71cee51.Alan.Adams@laptop.adamshome.org.uk> |
| In reply to | #519 |
In message <51ee1665a1News03@avisoft.f9.co.uk>
Martin <News03@avisoft.f9.co.uk> wrote:
> On 05 Jul, in article <2a5e02ee51.martin@blueyonder.co.uk>,
> Martin Bazley <martin.bazley@blueyonder.co.uk> wrote:
>> And PROCclose most certainly isn't being called before the program
>> terminates, because the files are left open!
> You seem to have eliminated the CLOSE#0 suggestion from within your
> program. But that leaves you with the question 'how did the program
> terminate without calling PROCclose?' which is really 'where the hell DID
> the program go?' !
> <plug>Sounds like a case for Reporter to me!</plug>
> But as you are running several instances of the program, you may need to
> be able to identify which *Report is which, eg by listing the parms when
> it starts?
> Martin
Probably a complete red herring, but...
Occasionally during !Boot I get files opened instead of run. A distant
recollection says this is because the shift key was held down as the
command was executed. Could this be triggered by something similar?
alan
--
Alan Adams, from Northamptonshire
alan@adamshome.org.uk
http://www.nckc.org.uk/
[toc] | [prev] | [next] | [standalone]
| From | Ian J Hartley <Ian.Hartley@sky.com> |
|---|---|
| Date | 2011-07-06 12:35 +0100 |
| Message-ID | <9abf85ee51.Ian@Ian.Hartley.sky.com> |
| In reply to | #520 |
In message <ecf71cee51.Alan.Adams@laptop.adamshome.org.uk>
Alan Adams <alan@adamshome.org.uk> wrote:
> Occasionally during !Boot I get files opened instead of run.
I thought I was the only one who suffered this, hardly ever from !Boot
to me it some times happens when I run something after !Boot.
--
Ian J Hartley
http://ianhartley.drobe.co.uk
[toc] | [prev] | [next] | [standalone]
| From | "Ste (news)" <steve@revi11.plus.com> |
|---|---|
| Date | 2011-07-07 13:57 +0100 |
| Message-ID | <51ef110f08steve@revi11.plus.com> |
| In reply to | #524 |
In article <9abf85ee51.Ian@Ian.Hartley.sky.com>, Ian J Hartley <Ian.Hartley@sky.com> wrote: > In message <ecf71cee51.Alan.Adams@laptop.adamshome.org.uk> > Alan Adams <alan@adamshome.org.uk> wrote: > > > Occasionally during !Boot I get files opened instead of run. > > I thought I was the only one who suffered this, hardly ever from !Boot > to me it some times happens when I run something after !Boot. Are you running something like Mauser or another third-party app which means that select click-and-hold acts as a load rather than a run operation and you start clicking on stuff before the boot sequence has completed? Or, are you starting to type things and pressing the shift key before the boot sequence has completed? Steve -- Steve Revill @ Home Note: All opinions expressed herein are my own.
[toc] | [prev] | [next] | [standalone]
| From | Alan Adams <alan@adamshome.org.uk> |
|---|---|
| Date | 2011-07-07 21:18 +0100 |
| Message-ID | <597d39ef51.Alan.Adams@laptop.adamshome.org.uk> |
| In reply to | #527 |
In message <51ef110f08steve@revi11.plus.com>
"Ste (news)" <steve@revi11.plus.com> wrote:
> In article <9abf85ee51.Ian@Ian.Hartley.sky.com>,
> Ian J Hartley <Ian.Hartley@sky.com> wrote:
>> In message <ecf71cee51.Alan.Adams@laptop.adamshome.org.uk>
>> Alan Adams <alan@adamshome.org.uk> wrote:
>>
>>> Occasionally during !Boot I get files opened instead of run.
>>
>> I thought I was the only one who suffered this, hardly ever from !Boot
>> to me it some times happens when I run something after !Boot.
> Are you running something like Mauser or another third-party app which means
> that select click-and-hold acts as a load rather than a run operation and
> you start clicking on stuff before the boot sequence has completed?
Standard behaviour on RO5.16, and yes, IĀ could be doing that
> Or, are
> you starting to type things and pressing the shift key before the boot
> sequence has completed?
and I could be doing that.
My comment wasn't intended as a complaint - i know how to prevent it
happening, it's called patience...
I wondered whether a similar interaction could be causing the odd
behaviour the OP reported.
--
Alan Adams, from Northamptonshire
alan@adamshome.org.uk
http://www.nckc.org.uk/
[toc] | [prev] | [next] | [standalone]
| From | Ian J Hartley <Ian.Hartley@sky.com> |
|---|---|
| Date | 2011-07-13 12:36 +0100 |
| Message-ID | <03b520f251.Ian@Ian.Hartley.sky.com> |
| In reply to | #527 |
In message <51ef110f08steve@revi11.plus.com>
"Ste (news)" <steve@revi11.plus.com> wrote:
> In article <9abf85ee51.Ian@Ian.Hartley.sky.com>,
> Ian J Hartley <Ian.Hartley@sky.com> wrote:
>> In message <ecf71cee51.Alan.Adams@laptop.adamshome.org.uk>
>> Alan Adams <alan@adamshome.org.uk> wrote:
>>
>>> Occasionally during !Boot I get files opened instead of run.
>>
>> I thought I was the only one who suffered this, hardly ever from !Boot
>> to me it some times happens when I run something after !Boot.
> Are you running something like Mauser or another third-party app which means
> that select click-and-hold acts as a load rather than a run operation
> and
I have !MouseAxes.
> you start clicking on stuff before the boot sequence has completed? Or, are
> you starting to type things and pressing the shift key before the boot
> sequence has completed?
I never touch the mouse or keyboard before boot has finnished because
some times it would hang if I moved the mouse.
!RiScript used to be a devil when run it would open three directories
instead of running 3 plugins, while other apps would run normally
inbetween.
Even clicking on a button in one of my own apps which oscli Filer_Run
an obey file that runs RC5 would sometimes open it in a taskwindow
instead of running quiet.
> Steve
--
Ian J Hartley
http://ianhartley.drobe.co.uk
[toc] | [prev] | [next] | [standalone]
| From | "Ste (news)" <steve@revi11.plus.com> |
|---|---|
| Date | 2011-07-14 15:58 +0100 |
| Message-ID | <51f2b70080steve@revi11.plus.com> |
| In reply to | #555 |
In article <03b520f251.Ian@Ian.Hartley.sky.com>, Ian J Hartley <Ian.Hartley@sky.com> wrote: > I never touch the mouse or keyboard before boot has finnished because > some times it would hang if I moved the mouse. Erm, what on Earth are you loading in your boot sequence? What hardware and OS version are you using? Something is very broken. Ta, Steve -- Steve Revill @ Home Note: All opinions expressed herein are my own.
[toc] | [prev] | [next] | [standalone]
| From | Ian Hamilton <Ian.Hamilton@AAUG.net> |
|---|---|
| Date | 2011-07-14 16:10 +0100 |
| Message-ID | <51f2b81a3bIan.Hamilton@AAUG.Net> |
| In reply to | #564 |
In article <51f2b70080steve@revi11.plus.com>, Ste (news) <steve@revi11.plus.com> wrote: > In article <03b520f251.Ian@Ian.Hartley.sky.com>, > Ian J Hartley <Ian.Hartley@sky.com> wrote: > > I never touch the mouse or keyboard before boot has finnished because > > some times it would hang if I moved the mouse. > Erm, what on Earth are you loading in your boot sequence? What hardware > and OS version are you using? Something is very broken. Not necessarily. The Belkin mouse that was supplied with the early Iyonix machines crashes if it's moved while being interrogated. Ian -- Ian Hamilton (Iyonix RO5) http://www.hamiltoni.pwp.blueyonder.co.uk/
[toc] | [prev] | [next] | [standalone]
| From | Ian J Hartley <Ian.Hartley@sky.com> |
|---|---|
| Date | 2011-07-17 12:30 +0100 |
| Message-ID | <f7702ff451.Ian@Ian.Hartley.sky.com> |
| In reply to | #564 |
In message <51f2b70080steve@revi11.plus.com>
"Ste (news)" <steve@revi11.plus.com> wrote:
> In article <03b520f251.Ian@Ian.Hartley.sky.com>,
> Ian J Hartley <Ian.Hartley@sky.com> wrote:
>> I never touch the mouse or keyboard before boot has finnished because
>> some times it would hang if I moved the mouse.
> Erm, what on Earth are you loading in your boot sequence? What hardware and
> OS version are you using? Something is very broken.
StrongED, WinSnap, Blinds, PreShut, mouseAxes, IcnClpBrd, SmartMenu,
PhotoFilr, FullNames, MiniDisc, Chimes, DogGlass, Organizer, IClear,
MouseCmd, 3 Button menus, MoreDesk, FlashTop, ScrollDesk (mine)
Geminus, QFiler, Fat32, FilerAct, Gut.. (martin w)
Logitech wireless mouse keyboard combo, TVcard
Just enuf time to light my cig and take a drag 30 sec start up.
I wouldnt say very broken the problem is rare and very rare during
boot, and only Riscript which is not run at boot would need a reboot
to run properly when it was acting up.
--
Ian J Hartley
http://ianhartley.drobe.co.uk
[toc] | [prev] | [next] | [standalone]
| From | "Ste (news)" <steve@revi11.plus.com> |
|---|---|
| Date | 2011-07-17 14:23 +0100 |
| Message-ID | <51f439daedsteve@revi11.plus.com> |
| In reply to | #569 |
In article <f7702ff451.Ian@Ian.Hartley.sky.com>, Ian J Hartley <Ian.Hartley@sky.com> wrote: > I wouldnt say very broken the problem is rare and very rare during > boot, and only Riscript which is not run at boot would need a reboot > to run properly when it was acting up. Ian Hamilton had a suggestion as to a possible cause. Does that sound like it might be relevant to you? Ta, Steve -- Steve Revill @ Home Note: All opinions expressed herein are my own.
[toc] | [prev] | [next] | [standalone]
| From | Ian J Hartley <Ian.Hartley@sky.com> |
|---|---|
| Date | 2011-07-17 16:14 +0100 |
| Message-ID | <1dff43f451.Ian@Ian.Hartley.sky.com> |
| In reply to | #571 |
In message <51f439daedsteve@revi11.plus.com>
"Ste (news)" <steve@revi11.plus.com> wrote:
> Ian Hamilton had a suggestion as to a possible cause. Does that sound like
> it might be relevant to you?
logitec wireless USB mouse keyboard combo here using Alternative USB
Mouse in configure with Hid set to use USBHID module.
--
Ian J Hartley
http://ianhartley.drobe.co.uk
[toc] | [prev] | [next] | [standalone]
| From | druck <news@druck.org.uk> |
|---|---|
| Date | 2011-07-14 19:23 +0100 |
| Message-ID | <ivnc6r$ph5$1@dont-email.me> |
| In reply to | #555 |
On 13/07/2011 12:36, Ian J Hartley wrote: > In message<51ef110f08steve@revi11.plus.com> > "Ste (news)"<steve@revi11.plus.com> wrote: > >> In article<9abf85ee51.Ian@Ian.Hartley.sky.com>, >> Ian J Hartley<Ian.Hartley@sky.com> wrote: >>> In message<ecf71cee51.Alan.Adams@laptop.adamshome.org.uk> >>> Alan Adams<alan@adamshome.org.uk> wrote: >>> >>>> Occasionally during !Boot I get files opened instead of run. >>> >>> I thought I was the only one who suffered this, hardly ever from !Boot >>> to me it some times happens when I run something after !Boot. > >> Are you running something like Mauser or another third-party app which means >> that select click-and-hold acts as a load rather than a run operation >> and > > I have !MouseAxes. > >> you start clicking on stuff before the boot sequence has completed? Or, are >> you starting to type things and pressing the shift key before the boot >> sequence has completed? > > I never touch the mouse or keyboard before boot has finnished because > some times it would hang if I moved the mouse. Nothing should be affected by moving the mouse, do you have any 3rd party utilities loaded that implement mouse guestures? (Something like MouseAxes?) > !RiScript used to be a devil when run it would open three directories > instead of running 3 plugins, while other apps would run normally > inbetween. > Even clicking on a button in one of my own apps which oscli Filer_Run > an obey file that runs RC5 would sometimes open it in a taskwindow > instead of running quiet. That sounds like you have a utility which implements a long double click. It works by detecting a long mouse press and simulating the shift key so the filer will open an application directory rather than running it. Having the shift key pressed has all sorts of side effects when applications are starting up, such as displaying obey files in an editor rather than running them. I suggest removing any utilities which alter the desktop behaviour, unless you are actively using them (many things are installed because they sounded good, and then forgotten about, resulting in unexpected behaviour later). If you are using them, then just keep hands off until there is no other activity. ---druck
[toc] | [prev] | [next] | [standalone]
| From | Ian J Hartley <Ian.Hartley@sky.com> |
|---|---|
| Date | 2011-07-17 14:17 +0100 |
| Message-ID | <a84139f451.Ian@Ian.Hartley.sky.com> |
| In reply to | #567 |
In message <ivnc6r$ph5$1@dont-email.me>
druck <news@druck.org.uk> wrote:
>> I have !MouseAxes.
[Snip]
> Nothing should be affected by moving the mouse, do you have any 3rd
> party utilities loaded that implement mouse guestures? (Something like
> MouseAxes?)
Did you miss the above :-)
[Snip]
> That sounds like you have a utility which implements a long double
> click. It works by detecting a long mouse press and simulating the shift
> key so the filer will open an application directory rather than running
> it. Having the shift key pressed has all sorts of side effects when
> applications are starting up, such as displaying obey files in an editor
> rather than running them.
You are probably right.
> I suggest removing any utilities which alter the desktop behaviour,
> unless you are actively using them (many things are installed because
> they sounded good, and then forgotten about, resulting in unexpected
> behaviour later). If you are using them, then just keep hands off until
> there is no other activity.
I would if it was all the time but its so rare.
Its probaby something to do with MouseAxes Hid which I forgot to
mention gets booted to ste and I think stronged dose something with
double clicks.
--
Ian J Hartley
http://ianhartley.drobe.co.uk
[toc] | [prev] | [next] | [standalone]
| From | Jeremy Nicoll - news posts <jn.nntp.scrap007@wingsandbeaks.org.uk> |
|---|---|
| Date | 2011-07-05 22:15 +0100 |
| Message-ID | <mpro.lnvpqa00477xq02sc@wingsandbeaks.org.uk.invalid> |
| In reply to | #500 |
Martin Bazley <martin.bazley@blueyonder.co.uk> wrote: > This is a most peculiar set of symptoms which I've never experienced > before a couple of weeks ago, but which I've now experienced on both RO5 > and RO6. > > I have a command-line BASIC program which converts from one file format > to another. In the process it opens two more, temporary, files in the > same directory as the output, which it deletes when the process is > complete. (It's been a while since I did any RO programming so some of this reply could be tosh.) Something that's not entirely clear to me... presumably the basic program does not itself multitask? Do those temporary files have fixed names? If so, running two of these things in parallel against the same output directory would be a problem. If I was doing this I'd dynamically create such leafnames using something like a microsecond-accurate timestamp, and even then there might be a clash. > I batch-convert a lot of files in one go by means of a Task > Obey script, which does not produce any VDU output. This normally runs > as expected. However, sometimes it doesn't... > > Very occasionally, the Task Obey will stop partway down with a "This > file is already open" error. The cause is random, and certainly not > caused by any open files. When you get that error do you then use a standalone utility to list all the open files? If not, how can you be so sure that the OS is wrong? > The last time it happened, I was running two different Task Obeys at once, I've never completely understood on what basis a Task-anything multitasks, but I have some distant feeling that it requires (text) output to the task window. Is that rubbish? Does running a Task-Obey cause the taskwindow server to front-end any SWIs? > outputting into different directories and getting input from the same > directory, but this shouldn't have made a difference, as input-only files > are allowed to be opened any number of times, and all I was doing was one > call to OS_File 16. It's also occurred when I was only running one > instance. > What happens next seems equally random. On one occasion, immediately > after giving the error, the Task Obey then skated drunkenly down all the > remaining star-commands in the file, executed about 30% of them > completely at random, and then forcibly terminated them all, leaving a > large assortment of temporary files still open. I cannot possibly > imagine what could have caused this unique and demented behaviour. I wonder if a reporter log showing these *commands being executed/skipped would help? Presumably normally if your basic program was failing it would issue *ERROR... and that would flush the rest of the Obey file. Does that mean that *ERROR didn't get executed? > Now, let's get one thing quite clear. The Task Obey does not open any > files. The Task Obey is nothing more than a list of start-commands, all > calling the BASIC file for different input values (via an alias to take > out the repetitive bits). Whenever I've used a BASIC program like this I've preceded its start by setting a system variable to a default "something went wrong running the program" error message, and within the program only as the very last thing done if it's run ok, reset that var to "OK". Then in the Obey file I've checked the var had the "OK" value. But that wouldn't work if you had more than one such Obey file running in parallel because they'd be hitting the same sysvar name. One would need to be more creative... > All OPENOUT commands are in the BASIC file, and quite deep within the > BASIC file at that. In order to open each two of those temporary files, > the Task Obey must have executed each of its remaining lines, processed > the alias, and called the BASIC file with the correct parameters for each > one. For "each one"? Must it? Surely the TO causes one BASIC program to run, waits for it to complete, then goes on to the next set of commands? > The BASIC file must then have validated its parameters, loaded the > input file into memory, interpreted and generated quite a large number of > complex data structures, done an entire first pass over most of the input > data to define variable limits, and DIMensioned an ungodly number of > arrays, before it even got close to the output procedure in which the two > temporary files were created. So what? If you're multitasking two of these task-obeys they could get to this point at the same time. Does your program check return codes from everything? > (The final files, which didn't appear, are left until after the temporary > files are finished.) And since it isn't that long after the creation that > the first bytes of output are written, the Task Obey must have seeked > through the whole (not inconsiderable) initialisation process until it > discovered two OPENOUT commands, Umm, in how much of what precedes this did you mean BASIC when you said Task Obey? > What caused this? I do not have a clue. It is the single most bizarre > thing I have observed RISC OS do, and in my time as a programmer, I've > seen it do many. Why are these Task Obey files not just simple Obey files? > Furthermore, does anyone have any idea what may cause a program to throw a > "This file is already open" error for no reason at all? Nope but I'd need convinced there was no reason. -- Jeremy C B Nicoll - my opinions are my own. Email sent to my from-address will be deleted. Instead, please reply to newsreplyaaa@wingsandbeaks.org.uk replacing "aaa" by "284".
[toc] | [prev] | [next] | [standalone]
| From | Rainer Schubert <dl6hbo@dl6hbo.inka.de> |
|---|---|
| Date | 2011-07-08 17:14 +0200 |
| Message-ID | <4E171EF0.7040507@dl6hbo.inka.de> |
| In reply to | #522 |
Am 05.07.2011 23:15, schrieb Jeremy Nicoll - news posts: [snip] > Why are these Task Obey files not just simple Obey files? Because Task Obeys do multi-task, while simple Obeys don't. Saves the programmer a lot of work. -- Rainer Schubert
[toc] | [prev] | [standalone]
Page 2 of 2 — ← Prev page 1 [2]
Back to top | Article view | comp.sys.acorn.programmer
csiph-web