On 2021/10/15 14:45, Brian Callahan wrote:
> Hi Stuart --
> 
> On 10/15/2021 10:35 AM, Stuart Henderson wrote:
> > On 2021/10/15 12:58, Brian Callahan wrote:
> > > Hello Pat --
> > > 
> > > On 10/15/2021 12:19 AM, Pat Jensen wrote:
> > > > All,
> > > >
> > > > I'm submitting a unified diff of a new port of my console word search
> > > > game for OpenBSD.
> > > >
> > > > Please evaluate and comment on any necessary changes.
> > > >
> > > 
> > > New ports are usually sent as tarballs. Attached is an improved
> > > version of
> > > your port.
> > > 
> > > Changes:
> > > * Lowercase first letter of COMMENT as is style
> > > * You use 2.0 in both DISTNAME and MASTER_SITES so 2.0 becomes its own
> > > variable, V.
> > > * Tightened up whitespace
> > > * Leaf ports are going to be python 3 by default no need to specify
> > > FLAVOR
> > > * One of your do-install lines was over 80 characters. I was able to
> > > shorten
> > > it, but otherwise you'd have to split it over multiple lines
> > > * You want ${INSTALL_DATA_DIR}, not mkdir -p, in your do-install
> > > routine
> > > * PLIST changed when I ran `make update-plist`
> > > 
> > > Works for me on amd64.
> > > 
> > > ~Brian
> > 
> > 
> > 
> > Fails in my usual terminal (rxvt-unicode) though it works in
> > xterm/st/tmux:
> > 
> > $ wordsearch
> > Traceback (most recent call last):
> >   File "/usr/local/bin/wordsearch", line 504, in <module>
> >     curses.wrapper(Main)
> >   File "/usr/local/lib/python3.8/curses/__init__.py", line 105, in
> > wrapper
> >     return func(stdscr, *args, **kwds)
> >   File "/usr/local/bin/wordsearch", line 293, in Main
> >     curses.curs_set(2)
> > _curses.error: curs_set() returned ERR
> 
> Unfortunately I can't replicate this. I tried just now with a freshly
> installed rxvt-unicode package. Tried both with and without tmux running in
> urxvt, both worked. Let me know if there's some special setup you have and
> I'll try to track the problem down.
> 
> ~Brian

I'm not sure what's triggering it, but looking at curs_set(3) doc
I think ERR should simply be ignored:

       The curs_set routine sets the cursor state is set to invisible, normal,
       or very visible for visibility equal to 0, 1, or 2 respectively.  If
       the terminal supports the visibility requested, the previous cursor
       state is returned; otherwise, ERR is returned.

This works but I don't know python so there might be a nicer way

  # Initialize curses
  try:
    curses.curs_set(2)
  except:
    1

Reply via email to