gnumed-bugs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-bugs] <bug>: add medication


From: Karsten Hilbert
Subject: Re: [Gnumed-bugs] <bug>: add medication
Date: Mon, 1 Jul 2019 12:39:27 +0200
User-agent: Mutt/1.10.1 (2018-07-13)

Dear Lars,

thanks for taking the time to report this issue.

> user comment  : add medication
>
> client version: 1.6.15

You are running the latest released version in the 1.6
branch, good, which is what comes with your version of
Ubuntu:

> Platform: ('Linux', 'MAIN-SYSTEM', '4.18.0-24-generic', '#25~18.04.1-Ubuntu 
> SMP Thu Jun 20 11:13:08 UTC 2019', 'x86_64', 'x86_64')

        
https://ubuntu.pkgs.org/18.04/ubuntu-universe-i386/gnumed-client-de_1.6.15+dfsg-1_all.deb.html

The problem you have encountered

> 2019-06-30 18:15:49  DEBUG     gm.gui 
> (/usr/share/gnumed/Gnumed/wxpython/gmExceptionHandlingWidgets.py::handle_uncaught_exception_wx()
>  #227): unhandled exception caught:
> Traceback (most recent call last):
>   File "/usr/share/gnumed/Gnumed/wxpython/gmEditArea.py", line 340, in 
> _on_save_button_pressed
>     if self._PNL_ea.save():
>   File "/usr/share/gnumed/Gnumed/wxpython/gmEditArea.py", line 203, in save
>     if self._save_as_new():
>   File "/usr/share/gnumed/Gnumed/wxpython/gmMedicationWidgets.py", line 623, 
> in _save_as_new
>     preparation = self._PRW_preparation.GetValue().strip()
>   File "/usr/share/gnumed/Gnumed/business/gmMedication.py", line 3793, in 
> turn_into_intake
>     preparation = self._payload[self._idx['preparation']]
>   File "/usr/share/gnumed/Gnumed/business/gmMedication.py", line 2824, in 
> create_substance_intake
>     rows, idx = gmPG2.run_rw_queries(queries = [{'cmd': cmd, 'args': args}], 
> return_data = True)
>   File "/usr/share/gnumed/Gnumed/pycommon/gmPG2.py", line 1860, in 
> run_rw_queries
>     curs.execute(query['cmd'], args)
>   File "/usr/lib/python2.7/dist-packages/psycopg2/extras.py", line 144, in 
> execute
>     return super(DictCursor, self).execute(query, vars)
> IntegrityError: null value in column "fk_substance" violates not-null 
> constraint
> DETAIL:  Failing row contains (31229, 0, 2019-06-30 18:15:49.016549+02, 
> 736040d0a9b823c5, 691, 2019-06-30 18:15:49.016549+02, 4194, 380, null, p, 
> 147, null, null, null, null, null, f, null, null, null, null, null, null).

happens when a user attempts to add a medication to a medical
record and the selected drug is a vaccine.

The recommended way to document a vaccination is to use the
dedicated user interface for that. One has to admit, GNUmed
fails to shield the user from being able to select a vaccine
in the add-medication dialog. The GNUmed backend does at
least protect the user from saving an invalid state into the
database, though, but GNUmed does not do a particularly good
job of failing gracefully.

However: There's been a whole new stable branch (1.7)
released for quite some time which ought to behave better.
You could attempt to install that from Debian Testing, or
soon from Debian Stable

        gnumed-client | 1.4.12+dfsg-1 | oldstable  | source, all
        gnumed-client | 1.6.11+dfsg-3 | stable     | source, all
        gnumed-client | 1.7.5+dfsg-3  | testing    | source, all
        gnumed-client | 1.7.5+dfsg-3  | unstable   | source, all

or download a version to be run from a local directory:

        http://www.gnumed.de/downloads/client/1.7/

Given that it is quite unlikely that any new version fixing
non-security related problems will be accepted into any
currently stable Debian or Ubuntu we won't publish an
explicit fix for the 1.6 branch UNLESS any given problem can
be demonstrated to be an active problem in a REAL LIFE
deployment.

Feel free to report back and ask if any other questions arise.

Best,
Karsten
--
GPG  40BE 5B0E C98E 1713 AFA6  5BC0 3BEA AC80 7D4F C89B



reply via email to

[Prev in Thread] Current Thread [Next in Thread]