Skip to content

Comments

feat(agora): add structured logging and error handling across components (AG-1787)#3890

Open
sagely1 wants to merge 3 commits intoSage-Bionetworks:mainfrom
sagely1:agora/AG-1977-part3-add-logging
Open

feat(agora): add structured logging and error handling across components (AG-1787)#3890
sagely1 wants to merge 3 commits intoSage-Bionetworks:mainfrom
sagely1:agora/AG-1977-part3-add-logging

Conversation

@sagely1
Copy link
Contributor

@sagely1 sagely1 commented Feb 20, 2026

Description

This PR standardizes logging and error handling. It specifically improves memory handling, SSR compatibility and logging.

Related Issues

AG-1787

Changelog

  • Add LoggerService and ErrorOverlayService to all Agora components for consistent error handling and observability via Sentry
  • Add takeUntilDestroyed to all component subscriptions to prevent memory leaks
  • Add isPlatformBrowser guards where needed for SSR compatibility
  • Add structured logging to gene-details, gene-evidence-*, gene-comparison-tool, gene-soe-charts, gene-similar, nominated-targets, teams, and app components
  • Add missing OnDestroy cleanup for search-input debounce subject

Test plan

  • Verify Sentry breadcrumbs are logged in dev mode (check console for [LOG] messages)
  • Verify error overlay appears when API calls fail
  • Verify no memory leaks (subscriptions cleaned up on component destroy)
  • Verify gene detail pages, comparison tool, nominated targets, and teams pages work correctly
  • Verify both Agora and Model-AD app components log version loading

sagely1 and others added 3 commits February 20, 2026 23:22
…mponents

- Make wikiParams a required input on wiki, popover-link, and modal-link components
- Switch wiki component from effect-based to OnInit lifecycle for data fetching
- Add isPlatformBrowser guard to wiki and terms-of-service components
- Improve wiki/wiki-hero layout with flexbox for better loading state display
- Convert wiki isLoading to signal for reactive state management
- Add className input to wiki and wiki-hero components for external styling
- Add heroBackgroundImagePath input to wiki-hero for customizable backgrounds
- Fix logger service to not log undefined when optional data/error params are omitted
- Add non-null assertion for optional headerTitleWikiParams in comparison-tool-header

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… shared components

Remove the agora-specific about, news, and shared libraries that have been
superseded by the explorers shared component library. Migrate all Agora
components to use explorers equivalents for modal-link, popover-link,
wiki, loading-icon, and svg-icon.

- Delete libs/agora/about, libs/agora/news, libs/agora/shared
- Delete SynapseApiService and SynapseWiki model (replaced by explorers equivalents)
- Delete agora-specific popover-link component from genes library
- Update all gene, comparison-tool, and nominated-target components to import
  from @sagebionetworks/explorers/util instead of @sagebionetworks/agora/shared
- Route about/news pages through shared wiki-hero component
- Add wiki-pages styles for about and news page content
- Remove unused tsconfig path aliases
- Update testing mocks to use explorers models

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add LoggerService and ErrorOverlayService to all Agora components for
consistent error handling and observability via Sentry.

- Add LoggerService logging to gene-details, gene-evidence-*, gene-similar,
  gene-comparison-tool, gene-soe-charts, nominated-targets, and teams
- Add ErrorOverlayService.showError for user-visible error states
- Add takeUntilDestroyed to all component subscriptions to prevent memory leaks
- Add DestroyRef injection pattern for proper subscription cleanup
- Add isPlatformBrowser guards where needed for SSR compatibility
- Add LoggerService to Agora and Model-AD app components for version loading
- Add missing OnDestroy cleanup for search-input debounce subject

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@sagely1 sagely1 requested review from a team and hallieswan as code owners February 20, 2026 23:33
@sagely1 sagely1 changed the title feat(agora): add structured logging and error handling across components feat(agora): add structured logging and error handling across components (AG-1787) Feb 21, 2026
<div
class="gct-how-to-panel-pane active"
[ngClass]="{ active: activePane === i }"
[class.active]="activePane === i"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Standardizing on newer syntax

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 this pull request may close these issues.

1 participant