Skip to content

Conversation

@iceljc
Copy link
Collaborator

@iceljc iceljc commented Oct 17, 2025

PR Type

Enhancement


Description

  • Display seconds in instruction log timestamps

  • Update time format to include hours, minutes, and seconds

  • Change format from default to 'MMM D YYYY, hh:mm:ss A'


Diagram Walkthrough

flowchart LR
  A["utcToLocal function"] -- "add format parameter" --> B["'MMM D YYYY, hh:mm:ss A'"]
  B -- "displays" --> C["Timestamp with seconds"]
Loading

File Walkthrough

Relevant files
Enhancement
log-item.svelte
Add seconds to timestamp display format                                   

src/routes/page/instruction/log/log-item.svelte

  • Updated utcToLocal() function call to include explicit time format
    parameter
  • Changed format from default to 'MMM D YYYY, hh:mm:ss A' to display
    seconds
  • Affects the created_time column in the instruction log table
+1/-1     

@iceljc iceljc requested a review from Oceania2018 October 17, 2025 00:12
@iceljc iceljc merged commit e062ae8 into SciSharp:main Oct 17, 2025
1 of 2 checks passed
@qodo-merge-pro
Copy link

PR Compliance Guide 🔍

Below is a summary of compliance checks for this PR:

Security Compliance
Time formatting handling

Description: Passing a format string to a time conversion function could lead to inconsistent locale
handling or injection if the format were user-controlled; however, here the format is
static and low risk—verify utcToLocal safely handles inputs and timezones.
log-item.svelte [26-26]

Referred Code
<td class="instruction-log-col ellipsis">{utcToLocal(item.created_time, 'MMM D YYYY, hh:mm:ss A')}</td>
<td>
Ticket Compliance
🎫 No ticket provided
- [ ] Create ticket/issue <!-- /create_ticket --create_ticket=true -->

</details></td></tr>
Codebase Duplication Compliance
Codebase context is not defined

Follow the guide to enable codebase context checks.

Custom Compliance
No custom compliance provided

Follow the guide to enable custom compliance check.

Compliance status legend 🟢 - Fully Compliant
🟡 - Partial Compliant
🔴 - Not Compliant
⚪ - Requires Further Human Verification
🏷️ - Compliance label

@qodo-merge-pro
Copy link

PR Code Suggestions ✨

Explore these optional code suggestions:

CategorySuggestion                                                                                                                                    Impact
General
Use a sortable date format

Change the date format to a lexicographically sortable one, such as YYYY-MM-DD
HH:mm:ss, to ensure correct chronological sorting if the table column is
sortable.

src/routes/page/instruction/log/log-item.svelte [26]

-<td class="instruction-log-col ellipsis">{utcToLocal(item.created_time, 'MMM D YYYY, hh:mm:ss A')}</td>
+<td class="instruction-log-col ellipsis">{utcToLocal(item.created_time, 'YYYY-MM-DD HH:mm:ss')}</td>
  • Apply / Chat
Suggestion importance[1-10]: 6

__

Why: The suggestion correctly points out that the new date format is not lexicographically sortable, which would break sorting functionality on the created_time column. This is a valid usability and functionality concern.

Low
  • More

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant