Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sum & product models hanging sasview (Trac #766) #880

Closed
RichardHeenan opened this issue Mar 30, 2019 · 2 comments
Closed

sum & product models hanging sasview (Trac #766) #880

RichardHeenan opened this issue Mar 30, 2019 · 2 comments
Assignees
Labels
Critical High priority Defect Bug or undesirable behaviour
Milestone

Comments

@RichardHeenan
Copy link
Contributor

RichardHeenan commented Mar 30, 2019

on creating a new sum or product model, an _user is being appended to the name, this causes a hang. Trace back below.

Andrew thinks that (a) a new model is created on compilation, (b) it gets written to disk, (c) on being reloaded it conflicts with the one already in memory. [It does cleverly seem to update the models list without having to do "load plugin models", but perhaps that is the weak point?]

If close sasview and start a new session, the newly created model works fine, without any _user appended to the name.

Traceback (most recent call last):
File "C:\stfc\sasview4\sasview\src\sas\sasgui\perspectives\fitting\fitpage.py", line 1269, in _on_select_model
self._set_dipers_Param(event=None)
File "C:\stfc\sasview4\sasview\src\sas\sasgui\perspectives\fitting\basepage.py", line 2263, in _set_dipers_Param
self._reset_dispersity()
File "C:\stfc\sasview4\sasview\src\sas\sasgui\perspectives\fitting\basepage.py", line 2343, in _reset_dispersity
self.save_current_state()
File "C:\stfc\sasview4\sasview\src\sas\sasgui\perspectives\fitting\basepage.py", line 802, in save_current_state
self.state.model = self.model.clone()
File "C:\stfc\sasview4\sasview\src\sas\sascalc\calculator\BaseComponent.py", line 176, in clone
return self._clone(obj)
File "C:\Users\rkh98.sasview\plugin_models\rkh_sph_hardsph_v5.py", line 100, in _clone
obj.params = copy.deepcopy(self.params)
AttributeError: 'NoneType' object has no attribute 'deepcopy'

Migrated from http://trac.sasview.org/ticket/766

{
    "status": "closed",
    "changetime": "2016-10-11T15:03:56",
    "_ts": "2016-10-11 15:03:56.573599+00:00",
    "description": "on creating a new sum or product model, an _user is being appended to the name, this causes a hang. Trace back below.\n\nAndrew thinks that (a) a new model is created on compilation, (b) it gets written to disk, (c) on being reloaded it conflicts with the one already in memory. [It does cleverly seem to update the models list without having to do \"load plugin models\", but perhaps that is the weak point?]\n\nIf close sasview and start a new session, the newly created model works fine, without any _user appended to the name.\n--------------------------------------------\n\nTraceback (most recent call last):\n  File \"C:\\stfc\\sasview4\\sasview\\src\\sas\\sasgui\\perspectives\\fitting\\fitpage.py\", line 1269, in _on_select_model\n    self._set_dipers_Param(event=None)\n  File \"C:\\stfc\\sasview4\\sasview\\src\\sas\\sasgui\\perspectives\\fitting\\basepage.py\", line 2263, in _set_dipers_Param\n    self._reset_dispersity()\n  File \"C:\\stfc\\sasview4\\sasview\\src\\sas\\sasgui\\perspectives\\fitting\\basepage.py\", line 2343, in _reset_dispersity\n    self.save_current_state()\n  File \"C:\\stfc\\sasview4\\sasview\\src\\sas\\sasgui\\perspectives\\fitting\\basepage.py\", line 802, in save_current_state\n    self.state.model = self.model.clone()\n  File \"C:\\stfc\\sasview4\\sasview\\src\\sas\\sascalc\\calculator\\BaseComponent.py\", line 176, in clone\n    return self._clone(obj)\n  File \"C:\\Users\\rkh98\\.sasview\\plugin_models\\rkh_sph_hardsph_v5.py\", line 100, in _clone\n    obj.params     = copy.deepcopy(self.params)\nAttributeError: 'NoneType' object has no attribute 'deepcopy'\n",
    "reporter": "richardh",
    "cc": "",
    "resolution": "fixed",
    "workpackage": "SasView Bug Fixing",
    "time": "2016-10-10T21:17:22",
    "component": "SasView",
    "summary": "sum & product models hanging sasview",
    "priority": "critical",
    "keywords": "",
    "milestone": "SasView 4.1.0",
    "owner": "mathieu",
    "type": "defect"
}
@RichardHeenan RichardHeenan added this to the SasView 4.1.0 milestone Mar 30, 2019
@RichardHeenan RichardHeenan added Critical High priority Defect Bug or undesirable behaviour Incomplete Migration and removed Incomplete Migration labels Mar 30, 2019
@mdoucet
Copy link
Contributor

mdoucet commented Mar 30, 2019

Trac update at 2016/10/11 14:58:02: mathieu commented:

In changeset 64f0a1c671d05c84078beba73c75405ee2eccfd7:

#!CommitTicketReference repository="sasmodels" revision="64f0a1c671d05c84078beba73c75405ee2eccfd7"
Make sure Sum|Multi models are not loaded a second time as _user. Re #880

@mdoucet
Copy link
Contributor

mdoucet commented Mar 30, 2019

Trac update at 2016/10/11 15:03:56:

  • mathieu commented:

In changeset f80b8a9:

#!CommitTicketReference repository="sasview" revision="f80b8a9f791a4f6550750aaa17b79f334e1ba267"
Make sure the copy module is available regardless of how the model is loaded. Fixes #880
  • mathieu changed resolution from "" to "fixed"
  • mathieu changed status from "new" to "closed"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Critical High priority Defect Bug or undesirable behaviour
Projects
None yet
Development

No branches or pull requests

2 participants