Commit 5cea110c authored by Ayres, Andrew's avatar Ayres, Andrew
Browse files

Small fixes

parent 7d981487
Loading
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
"""Main Application."""

import sys
from .models.fractal import Fractal


def main() -> None:
+16 −0
Original line number Diff line number Diff line
@@ -78,6 +78,22 @@ Layouts are responsible for arraging your content in a consistent manner. In Tra
**1. `src/nova_tutorial/app/views/main.py` (Modify):**

```python
import logging

from nova.mvvm.trame_binding import TrameBinding
from nova.trame import ThemedApp
from nova.trame.view import layouts
from trame.app import get_server
from trame.widgets import vuetify3 as vuetify

from ..mvvm_factory import create_viewmodels
from ..view_models.main import MainViewModel
from .tab_content_panel import TabContentPanel
from .tabs_panel import TabsPanel

logger = logging.getLogger(__name__)
logger.setLevel(logging.INFO)

class MainApp(ThemedApp):
    """Main application view class. Calls rendering of nested UI elements."""

+2 −2
Original line number Diff line number Diff line
@@ -151,7 +151,7 @@ class PlotlyView:

As with our previous examples, there is a corresponding model.

**2. `PlotlyConfig` Model Class (src/viz_examples/models/plotly.py) (Create):**
**2. `PlotlyConfig` Model Class (src/viz_examples/app/models/plotly.py) (Create):**

*   **Imports**:  The graph_objects module is how we will define the content for our chart. The iris module defines an example dataset.

@@ -218,7 +218,7 @@ class PlotlyConfig(BaseModel):

First, let's add replace the sample tabs from the template with the following:

**3. `src/viz_examples/views/tab_content_panel.py` (Modify):**
**3. `src/app/viz_examples/app/views/tab_content_panel.py` (Modify):**

*   **Import `PlotlyView`**

+2 −1
Original line number Diff line number Diff line
@@ -10,12 +10,13 @@ This section guides you through setting up your development environment to follo
Before proceeding, ensure you have met the following prerequisites:

*   **Basic Python Knowledge:** A basic understanding of Python programming concepts is required.
*   **Python Installation:** You must have Python 3.8 or higher installed on your system.  Verify your Python version by running `python --version` or `python3 --version` in your terminal.
*   **Python Installation:** You must have Python 3.10 or higher installed on your system.  Verify your Python version by running `python --version` or `python3 --version` in your terminal.
*   **Python's `copier` Library:** We will be using this library to generate a starting application from a template. Install it using `pip install copier`.
*   **Poetry:** The code samples provided in this tutorial leverage Poetry for dependency management.  If you don't have Poetry installed, follow the instructions on the official Poetry website: [https://python-poetry.org/docs/#installation](https://python-poetry.org/docs/#installation).
*   **NDIP Access:** You should have access to a working NDIP system. (Specific details about NDIP access will need to be provided by the instructor.)  Ensure you have the necessary credentials (API key and NDIP URL) to connect to NDIP. These will be set as environment variables, as described later.
*   **NOVA Libraries:**  While Poetry will manage these dependencies for you, it's helpful to be aware of the core NOVA libraries: `nova-galaxy`, `nova-trame`, and `nova-mvvm`.  You can find documentation for these libraries on ReadTheDocs (links provided in the "References" section).
*   **A Text Editor or IDE:** You will need a text editor or IDE (such as VS Code, Sublime Text, or Atom) for writing code.
*   **Git:** You must have git installed on your system.
*   **Familiarity with the Command Line:** You will need to be comfortable using the command line or terminal.

## 2. Getting your Galaxy API Key