Skip to content

Commit

Permalink
ComputationalResourcesWidget refresh things after every update (#306)
Browse files Browse the repository at this point in the history
fixes #301. In this PR the ComputationalResourcesWidget's behaviour is improved:

After each computer setup the code widget is refreshed.
After each code setup, the list of available codes is refreshed.
Additionally, there were a few changes to achieve the things mentioned above:

- ComputationalResourcesWidget refresh things after each setup.
- Simplify ComputationalResourcesWidget by the use of refresh()
method defined in the subwidgets.
- Simplify `ssh_copy_id` function that raises a RuntimeError in
case the connection to a remote computer couldn't be established.
The exception is then handled outside.
- Define `refresh` method as a part of AiidaCodeSetup.
- Use `on_<event>` methods to append function to an internal list.
- Implement ssh connection states in `SshComputerSetup` widget.

Introduce `ssh_connection_state` trait that contains the current status
of the SSH connection. The widget acts according to the value of the
trait.


Co-authored-by: Carl Simon Adorf <simon.adorf@epfl.ch>
Co-authored-by: Jusong Yu <jusong.yeu@gmail.com>
  • Loading branch information
3 people authored May 6, 2022
1 parent 7d56d78 commit 6cff758
Show file tree
Hide file tree
Showing 4 changed files with 332 additions and 231 deletions.
Loading

0 comments on commit 6cff758

Please sign in to comment.