bugGNU Health - Bugs: bug #61867, health_federation: error when ...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #61867: health_federation: error when save page of life.

Submitter:  Feng Shu <tumashu>
Submitted:  Thu 20 Jan 2022 06:18:14 AM UTC
   
 
Category:  Programming / Tracebacks Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  meanmicio
Open/Closed:  Closed Release:  3.9.0
Module:  all Component:  None

Tue 25 Jan 2022 09:40:10 AM UTC, comment #5: 

Thank you!

Just noticed I missed the msg_ prefix, that is why you saw "health_federation.no_institution" instead of the text of the error code (SM-FEDERATION-0005: You need to create an institution) :)

Fixed here:
https://hg.savannah.gnu.org/hgweb/health/rev/fac8b97e841f

Luis Falcon <meanmicio>
Group administrator
Tue 25 Jan 2022 02:05:56 AM UTC, comment #4: 


comment #3:

> I have try the newest code, when I create patient, "health_federation.no_instituation" window will show.


When I set current company as Instituation, the problem seem to solve.

Feng Shu <tumashu>
Group Member
Tue 25 Jan 2022 02:00:37 AM UTC, comment #3: 

I have try the newest code, when I create patient, "health_federation.no_instituation" window will show.

Feng Shu <tumashu>
Group Member
Mon 24 Jan 2022 05:53:35 PM UTC, comment #2: 
Luis Falcon <meanmicio>
Group administrator
Mon 24 Jan 2022 02:30:00 PM UTC, comment #1: 

Hi Tumashu!

Confirmed.

I'm migrating now all the instances of raise_user_error to the new system message classes.

Luis Falcon <meanmicio>
Group administrator
Thu 20 Jan 2022 06:18:14 AM UTC, original submission:  

ERROR trytond.protocols.dispatcher <class 'trytond.pool.gnuhealth.pol'>.create(([{'age': '36y 9m 3d', 'federation_account': 'ZNU764BTS', 'medical_context': 'prescription', 'node': 'xxx', 'page': 'ac7b351f-8f0c-41e5-a37a-c3a0fa839f99', 'page_date': datetime.datetime(2022, 1, 20, 6, 13, 23), 'page_type': 'medical', 'person': 3, 'relevance': 'important', 'social_context': None, 'summary': '测试', 'author': '', 'author_acct': '', 'gene': '', 'health_condition': 8, 'health_condition_code': 'A01.2', 'health_condition_text': '副伤寒乙', 'info': '11111', 'institution': 1, 'natural_variant': '', 'phenotype': '', 'procedure': 16, 'procedure_code': '1-207', 'procedure_text': '脑电图'}], {'client': 'c39e9094-4a3c-4beb-bef1-5ccf8f91b782', 'company_filter': 'one', 'company': 1, 'company.rec_name': 'xxx', 'language': 'zh_CN', 'language_direction': 'ltr', 'groups': [7, 8, 1, 22, 4, 2, 5, 15, 21, 24, 25, 30, 26, 28, 31, 29, 20, 33, 3, 6, 12, 13, 14, 9, 10, 11], 'locale': {'date': '%Y-%m-%d', 'grouping': [3, 0], 'decimal_point': '.', 'thousands_sep': ','}}), *{}) from admin@127.0.0.1/gnuhealth1/

Traceback (most recent call last):
  File "/trytond/wsgi.py", line 117, in dispatch_request
    return endpoint(request, **request.view_args)
  File "/trytond/protocols/dispatcher.py", line 46, in rpc
    return methods.get(request.rpc_method, _dispatch)(
  File "/trytond/wsgi.py", line 84, in auth_required
    return wrapped(args, *kwargs)
  File "/trytond/protocols/wrappers.py", line 159, in wrapper
    return func(request, pool, args, *kwargs)
  File "/trytond/protocols/dispatcher.py", line 180, in _dispatch
    result = rpc.result(meth(c_args, *c_kwargs))
  File "/trytond/modules/health_federation/health_federation.py", line 644, in create
    FederationQueue.enqueue(
  File "/trytond/modules/health_federation/health_federation.py", line 404, in enqueue
    cls.create(rec)
  File "/trytond/model/modelsql.py", line 159, in wrapper
    return func(cls, args, *kwargs)
  File "/trytond/model/modelsql.py", line 597, in create
    defaults = cls.default_get(default, with_rec_name=False)
  File "/trytond/model/model.py", line 149, in default_get
    value[field_name] = cls._defaults[field_name]()
  File "/trytond/modules/health_federation/health_federation.py", line 217, in default_node
    FederationQueue.raise_user_error(
AttributeError: type object 'gnuhealth.federation.queue' has no attribute 'raise_user_error'

Fault: type object 'gnuhealth.federation.queue' has no attribute 'raise_user_error'

Feng Shu <tumashu>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by meanmicio (Posted a comment)
  • -email is unavailable- added by tumashu (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-01-25 meanmicio StatusReady For Test Fixed
        Open/ClosedOpen Closed
    2022-01-24 meanmicio StatusConfirmed Ready For Test
    2022-01-24 meanmicio StatusNone Confirmed
        Assigned toNone meanmicio
        ReleaseNone 3.9.0
        Modulehealth_federation all

    Back to the top

    Powered by Savane 3.12.
    Corresponding source code