McCode icon indicating copy to clipboard operation
McCode copied to clipboard

MAXII_811.instr trace crash

Open antoinepado opened this issue 3 years ago • 4 comments

When trying to get a Trace for MAXII_811.instr

‘NoneType’ object has no attribute ‘group’

error appears.

The COMPONENT mono_lower in MAXII_811.instr:

COMPONENT mono_lower = Bragg_crystal( length=0.05,width=0.02,h=1,k=1,l=1,alpha=0) AT(0,-mono1_y,8) RELATIVE mirror1_pos ROTATED(-(theta-2*mirror1_angle),0,0) RELATIVE mirror1_pos

Seems to accept 0 for the x rotation value (trace works) but crashes for non zero values.

antoinepado avatar Oct 13 '21 14:10 antoinepado

The crash is caused by the python plotter non being able to handle data files with nan's in them.

Of course there should not be nan's in the data at all - this is obviously caused by something else. Will investigate further. I am assuming this was for McXtrace 1.6 - or did you run with a development version?

ebknudsen avatar Oct 15 '21 07:10 ebknudsen

Yes with McXtrace 1.6.

antoinepado avatar Oct 15 '21 07:10 antoinepado

@ebknudsen this goes in the direction of somehow allowing to plot data with NaN's but with a huge WARNING added to e.g. the title or legends

willend avatar Oct 15 '21 07:10 willend

Agreed - I'll see if something can be done along that line.

ebknudsen avatar Oct 15 '21 09:10 ebknudsen

Still there...

farhi avatar May 10 '23 06:05 farhi

At present I am unable to reproduce this. What parameters were you running with @farhi ?

ebknudsen avatar May 10 '23 08:05 ebknudsen

This is only McXtrace 1.x related: Trace brings

starting particle parsing
'NoneType' object has no attribute 'group'

farhi avatar May 10 '23 09:05 farhi

hmm - I've tried with both 1.x and 3.1 and still can't reproduce. The error message is most often related to a failing regexp match somewhere, but where I do not know.

ebknudsen avatar May 10 '23 09:05 ebknudsen

@ebknudsen I just reproduced on elearn1, if you have time, please try

  • logging in to elearn1
  • execute my fresh build using /home/nexmap/pkwi/McXtrace/mcxtrace/1.x-dev/environment
  • try doing mxdisplay

willend avatar May 10 '23 09:05 willend

(Anyway, not critical as we want to abandon 1.x soon)

willend avatar May 10 '23 09:05 willend