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

improvements to is_active ping logic #2450

Merged
merged 3 commits into from
Sep 18, 2023

Conversation

kecnry
Copy link
Member

@kecnry kecnry commented Sep 12, 2023

Description

This pull request aims fix lag and "flickering" issues within the is_active ping logic, hopefully for the last time 🤞 .

See:

TODO:

  • attempt to write a robust test that can mimic slow behavior in a method without requiring large test data and somehow test against flickering
  • manual testing on different machines with different data across all applicable plugins
  • if this change is insufficient, consider implementing dynamic timeout rates that adjust based on time to call methods

Change log entry

  • Is a change log needed? If yes, is it added to CHANGES.rst? If you want to avoid merge conflicts,
    list the proposed change log here for review and add to CHANGES.rst before merge. If no, maintainer
    should add a no-changelog-entry-needed label.

Checklist for package maintainer(s)

This checklist is meant to remind the package maintainer(s) who will review this pull request of some common things to look for. This list is not exhaustive.

  • Are two approvals required? Branch protection rule does not check for the second approval. If a second approval is not necessary, please apply the trivial label.
  • Do the proposed changes actually accomplish desired goals? Also manually run the affected example notebooks, if necessary.
  • Do the proposed changes follow the STScI Style Guides?
  • Are tests added/updated as required? If so, do they follow the STScI Style Guides?
  • Are docs added/updated as required? If so, do they follow the STScI Style Guides?
  • Did the CI pass? If not, are the failures related?
  • Is a milestone set? Set this to bugfix milestone if this is a bug fix and needs to be released ASAP; otherwise, set this to the next major release milestone.
  • After merge, any internal documentations need updating (e.g., JIRA, Innerspace)?

@kecnry kecnry added this to the 3.6.3 milestone Sep 12, 2023
@codecov
Copy link

codecov bot commented Sep 12, 2023

Codecov Report

Patch coverage is 85.71% of modified lines.

Files Changed Coverage
jdaviz/core/template_mixin.py 85.71%

📢 Thoughts on this report? Let us know!.

@camipacifici
Copy link
Contributor

Tested where I was seeing the flickering (it is a notebook where I first load a bunch of spectra in mosviz and then I load one in specviz2d) and it is gone. Works well, thank you!

Copy link
Contributor

@pllim pllim left a comment

Choose a reason for hiding this comment

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

Approving by proxy based on Cami's comment. Thanks!

@pllim
Copy link
Contributor

pllim commented Sep 14, 2023

Up to you if you want to add a change log since I don't think this flicker shows up for everyone?

@pllim pllim added bug Something isn't working performance Performance related 💤 backport-v3.6.x on-merge: backport to v3.6.x labels Sep 14, 2023
@kecnry
Copy link
Member Author

kecnry commented Sep 14, 2023

I'm still hoping to come up with a robust regression test for this (which is why I'm keeping it in draft), but its not an easy thing to test.

@kecnry kecnry modified the milestones: 3.6.3, 3.7 Sep 15, 2023
@kecnry kecnry removed the 💤 backport-v3.6.x on-merge: backport to v3.6.x label Sep 15, 2023
* fixes case where method call taking longer than ping timeout results in flashing
including retroactive changelog for spacetelescope#2386 which this builds on
@kecnry
Copy link
Member Author

kecnry commented Sep 15, 2023

Re-milestoned to 3.7 since this builds on #2386 which was not backported and we're likely not doing a 3.6.3 release anyways. I was not successful in creating a proper regression test, but am including some test infrastructure/coverage for the active pings anyways.

@kecnry kecnry marked this pull request as ready for review September 15, 2023 18:30
Copy link
Contributor

@javerbukh javerbukh left a comment

Choose a reason for hiding this comment

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

Tried in Imviz and Mosviz and couldn't replicate the original bug. LGTM!

Copy link
Contributor

@pllim pllim left a comment

Choose a reason for hiding this comment

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

I don't grok the test but something is better than nothing. My approval stands. Thanks!

@kecnry kecnry merged commit 09141f8 into spacetelescope:main Sep 18, 2023
14 of 15 checks passed
@kecnry kecnry deleted the active-ping-take-4 branch September 18, 2023 19:25
bmorris3 pushed a commit to bmorris3/jdaviz that referenced this pull request Sep 22, 2023
* add to skip list before running method - fixes case where method call taking longer than ping timeout results in flashing
* ping test coverage
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working performance Performance related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants