This is the second iteration of a telemetry viewer headed by Kai, Travis, Ariel and Gavin
Welcome to The Data Viewer, a powerful and user-friendly software tool designed to help you navigate and explore data collected by the McMaster Baja DAQ team!
The Data Viewer serves as a streamlined portal, offering a seamless experience for users to interact with data effortlessly. Its primary function revolves around uploading data through a straightforward form and subsequently exploring, analyzing, and visualizing this information. Once data is uploaded, users gain access to a comprehensive set of analytical tools—referred to as "analyzers"—that enable them to apply filters and manipulate the data for deeper insights.
For McMaster Baja and its affiliates, The Data Viewer is an invaluable asset. It facilitates swift and efficient data interpretation after rigorous data collection sessions, enabling quick comprehension and actionable insights. Whether it's assessing performance metrics, scrutinizing vehicle diagnostics, or examining test runs, The Data Viewer empowers users to swiftly grasp essential patterns, trends, and anomalies within the collected data.
For an in-depth user guide, consult the McMaster Baja Wiki.
- NodeJS and NPM
- JDK 21
- Clone repository.
- Inside a terminal, navigate to the folder Better-Data-Viewer\front-end, then run the command
npm i --force
- Inside a terminal, navigate to the folder Better-Data-Viewer\backend, then run the command
./mvnw quarkus:dev
- Inside start.ps1. add your JDK path to the list of
javaHomeLocations
. Setup complete!
- Ensure your Java Development Kit directory is added into the list
javaHomeLocations
in thestart.ps1
file - Run the command
./start.ps1
, and leave all terminals open. - Go to
localhost:5173
to begin.
For Quarkus, you can use the Quarkus CLI or Maven commands. For more information, see the readme in the backend/
folder.
- Ensure that java 21 is being used. You can check with the
java --version
command. - In the
backend/
folder, run either:quarkus dev
or./mvnw quarkus:dev
- Head to
localhost:8080
to test it out!
To run the front end, simply use the react scripts
- Ensure you have NodeJS and npm installed.
- In the
front-end/
folder, run thenpm start
command. - Head to
localhost:5173
to test it out!
All the below steps will take place from within the /e2e/
directory. Playwright is a E2E testing framework that allows us to automate testing the entire system at once. More information can be found here.
- Run tests:
npx playwright test
. Results of the tests are shown in the terminal. For more info see the Running Tests guide. - After the tests complete, an HTML reporter is generated. You can view these by running
npx playwright show-report
which will open a browser window with the results. For more info see - Finally, you can run tests in UI mode as well with
npx playwright test --ui
. This will open an application allowing you to look at each test being run individually. For more information see the Detailed UI Mode guide.
Playwright will automatically run in the pipeline on pull requests. You can view the trace outputted as an artifact, which can be downloaded through the action. To view the contents, unzip it and open the html file in your browser. Further, if you want to view the actual actions the browser saw, you can load the files in the /data/
folder. Run npx playwright show-trace
and upload them, then click through the test case!
- Powershell script unsigned, means script won't run unless
Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass
is run in powershell first Optionally, runSet-ExecutionPolicy unrestricted
in an administrator terminal to set it permanently
- To run ESLint on the front end, simply download the ESLint extension (The ) in VSCode. You should then be able to run the
Auto-format file
command via the command palette (Ctrl + Shift + P). - To run Java Google Format, go to the repository (https://github.com/google/google-java-format) and download the latest all-deps
.jar
file. Additionally you can find it locally in the backend folder. You can then run it via the commandjava -jar /path/to/google-java-format-${GJF_VERSION?}-all-deps.jar <options> [files...]
. A common option to add is--replace
which will automatically format it. - To run it easier, here's a cool command (run in
backend/
directory using bash)find ./ -name "*.java" -type f -print | xargs java -jar google-java-format-1.22.0-all-deps.jar --replace
Just make sure to check over what it changes
- first have rustup installed https://www.rust-lang.org/tools/install
- complete setup and use the stable branch of rust
- in the binary-to-csv-lib folder, run
cargo build --release
- once that is complete, copy the resulting dll file(windows) that is now in the
target/release/
folder - paste this folder in the
Better-Data-Viewer\API\src\main\java\backend\API\binary_csv\
Folder