Skip to content

Conversation

@stevenhua0320
Copy link
Contributor

@zmx27 Ready for review same operation in #9
Fix module not used (E402) & cond comparison legacy issue (E711)

Copy link
Collaborator

@zmx27 zmx27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comments

"srxconfig",
desc="Comparing to the average intensity at similar diffraction angle, \npixels with intensity larger than avg_int*high will be masked",
desc="Comparing to the average intensity at similar diffraction angle,"
+ "\npixels with intensity larger than"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing space here

"srxconfig",
desc="Comparing to the average intensity at similar diffraction angle, \npixels with intensity less than avg_int*low will be masked",
desc="Comparing to the average intensity at similar diffraction angle,"
+ "\npixels with intensity less than avg_int*low will be masked",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing space here

def createPlot(self):
# image = np.log(self.srx.loadimage.loadImage(self.imagefile))
# image = np.log(self.srx.loadimage.
# loadImage(self.imagefile))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know that you probably did this because the line was too long, but is it possible to find some other way of doing this? It feels kind of awkward to split up a function call like this. If not, you can probably keep this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed the format, see the new commit

hinttext = Str(
"Zoom: <z>; Reset: <Esc>; Pan: <drag/drop>; Toggle XY coordinates: <P>"
"Zoom: <z>; Reset: <Esc>;"
"Pan: <drag/drop>; Toggle XY coordinates: <P>"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing a space here

@stevenhua0320 stevenhua0320 changed the title fix E402 E711 in datacontainer, imageplot, and live.py chore: resolve flake8 in datacontainer, imageplot, and live.py Sep 26, 2025
@stevenhua0320
Copy link
Contributor Author

@zmx27 Ready for another review

Copy link
Collaborator

@zmx27 zmx27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@stevenhua0320
Copy link
Contributor Author

@sbillinge Ready for review

@sbillinge
Copy link
Contributor

As a general matter, I think it is better to break strings without introducting the +. I think it is more readable that way. So not

string = "a very"
              + "long string

but instead
string = ("a very "
"long string")


We tend not to use the `+` string add method to do concatenation these days at all. 

@sbillinge sbillinge merged commit dd8d717 into diffpy:migration Sep 28, 2025
@sbillinge sbillinge deleted the migration-3 branch September 28, 2025 04:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants