× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Nathan, I think you are missing a lot of the nuance I am trying to express.

On Wed, Jun 21, 2017 at 10:11 AM, Nathan Andelin <nandelin@xxxxxxxxx> wrote:
On one hand,
you appear to be interested in sending diagnostic and escape messages to
CLPs from Python.

Not really.

Let's back up. I need to confirm that you understand firstly that the
original point of this thread had nothing to do with Python. Nothing
at all. Zero, zip, zilch.

Python came up purely as a tangent. OK? We clear on that?

Second, you keep saying "messages to CLPs". I'm not sure that's quite
correct either. What I'm really interested in is getting the most
useful messages to the most useful recipients. The best recipient
*might* be a CLP in some cases. It might not.

Ultimately, I want the message to be seen by a person if the point is
for a person to do something with that information. If the point is
for some other program to see the message, then naturally I want the
message to be seen by that other program (which might be a CLP or
not). In all cases, I would prefer for the message to be reasonably
accessible.

But on the other hand, you say that you don't have the
means of doing that [sending diagnostic and escape
messages to CLPs from Python], and that it would take
an enormous effort to create that.

I don't know if you are just reading too quickly or what, but you are
definitely missing some very significant parts of what I'm saying.

Let's back up again, because there is a lot involved here.

First, we should be clear that I'm only talking about iSeriesPython.
If anything I say has any applicability to IBM's 5733-OPS Python for
PASE, that is purely incidental.

Second, I said I *do* have the means of sending messages from Python
to IBM's message queues. (I much prefer to express it this way than to
say "messages to CLPs", because conceptually, CLPs are not relevant to
me.) I have already done it, and it's pretty easy. Just wrap SNDPGMMSG
in a CLP, and call the CLP from Python.

Now, what would be an enormous effort is to *replicate RPG's level of
message integration* in Python. RPG sends messages about division by
zero or record format errors (just to take a couple of common
examples) to IBM's message queues. To set up something like this for
Python would be arduous and very likely misguided.

If your goal is for CLPs to receive messages from Python, I'm just
suggesting that you come up with a solution that doesn't involve using
program message queues.

Hopefully I have explained my goals better above. As I have now
repeatedly stated, program message queues *are* better, where *I*
work. Because that is what my colleagues are going to *see* (via
WRKACTJOB and/or inspecting job logs).

Maybe it's worth mentioning that I am not especially interested in a
mechanism that can be employed to programmatically inspect and handle
Python errors from outside of Python. In other words, I'm neither
expecting nor hoping that someone is trying to do RCVMSG or equivalent
on errors that are occurring in a Python program. If they are, that's
their business, and I don't have much motivation to make that task any
easier. By the time a Python program fails, I'm really looking for it
to either die quickly and silently, with no ill consequences, or alert
a human "operator" that there is a problem.

Maybe it's also worth mentioning that for end-user-facing error
messages, I generally send e-mails. Just because that is what works
best here.

John Y.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.