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

Fix diagnostics page for light miner #521

Closed
shawaj opened this issue Apr 7, 2023 · 6 comments · Fixed by #530
Closed

Fix diagnostics page for light miner #521

shawaj opened this issue Apr 7, 2023 · 6 comments · Fixed by #530

Comments

@shawaj
Copy link
Member Author

shawaj commented Apr 7, 2023

FYI @MuratUrsavas ^^

@MuratUrsavas
Copy link
Contributor

MuratUrsavas commented Apr 7, 2023

@shawaj Should I remove that old residue, then? It is working well in current state (with template_hyper)

@MuratUrsavas
Copy link
Contributor

@shawaj It's stub now, we can easily remove that. Let's do this in next change. No need to deal with it for two PR's.

@shawaj
Copy link
Member Author

shawaj commented Apr 7, 2023

ahh so this template diagnostics_page_light_miner.html is not being used?

Also - it looks like diagnostics.RE in here is checking for UN123 - but I think you deprecated that functionality now in this latest update? So I guess we need to change how it checks for radio operational and region plan...

<td class="border-0">Region Plan</td>
{% if diagnostics.RE == 'UN123' %}
<td class="border-0 text-right">Awaiting Location Assertion</td>
{% else %}
<td class="border-0 text-right">{{ diagnostics.RE }}</td>
{% endif %}
</tr>
</table>
</div>
</div>
<div class="col-12 col-lg-6 mb-4 mb-lg-0">
<div class="card mb-0 h-100">
<table class="table dt-responsive nowrap m-2 w-auto">
<tr>
<td>Radio Operational</td>
{% if diagnostics.LOR %}
<td class="text-success text-right">True</td>
{% elif diagnostics.RE == 'UN123' and not diagnostics.LOR %}
<td class="text-right">Awaiting Location Assertion</td>
{% else %}
<td class="text-danger text-right">False</td>
{% endif %}
</tr>

@shawaj
Copy link
Member Author

shawaj commented Apr 7, 2023

@MuratUrsavas what will it show if the location is not asserted?

@shawaj
Copy link
Member Author

shawaj commented Apr 12, 2023

We also need to add the connected validator bit: (i forgot validators will no longer exist)

<td>Connected Validator</td>
{% if not diagnostics.has_errors([DIAG_CONSTS.VALIDATOR_URI_KEY]) %}
<td class="border-0 text-success text-right"><a href="https://explorer.helium.com/validators/{{ diagnostics.get(DIAG_CONSTS.VALIDATOR_ADDRESS_KEY) }}"
target="_blank">{{ diagnostics.get(DIAG_CONSTS.VALIDATOR_URI_KEY) }}</a></td>
{% else %}
<td class="text-warning text-right">Disconnected</td>
{% endif %}
</tr>

                <tr>
                  {% if not diagnostics.has_errors([DIAG_CONSTS.VALIDATOR_URI_KEY]) %}
                    <td>Connected Validator</td> 
                    <td class="text-right"><a href="https://explorer.helium.com/validators/{{ diagnostics.get(DIAG_CONSTS.VALIDATOR_ADDRESS_KEY) }}" 
                    target="_blank">{{ diagnostics.get(DIAG_CONSTS.VALIDATOR_URI_KEY) }}</a></td> 
                  {% else %} 
                    <td>Connected Validator</td> 
                    <td class="text-warning text-right">Disconnected</td> 
                  {% endif %} 
                </tr>

shawaj added a commit that referenced this issue Apr 12, 2023
shawaj added a commit that referenced this issue Apr 12, 2023
shawaj added a commit that referenced this issue Apr 12, 2023
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 a pull request may close this issue.

2 participants