Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Nov 14, 2025

Task Recap - Implementation Complete ✅

Original Requirements:

  • ✅ Remove the build-plugin.yml workflow
  • ✅ Improve kotlin-ci to upload the artifact if there is a new release
  • ✅ Add setting in plugin chat UI to choose the project (not just re-index button)
  • ✅ Fix warning: Factory not registered as com.intellij.statusBarWidgetFactory extension
  • ✅ Fix warning: StatusBarWidgetFactory doesn't define 'id' for extension
  • ✅ Fix plugin chat UI error: HTTP 400 for /code endpoint - investigate request/response mismatch

New Requirements (Added):

  • ✅ Add functionality to remove individual messages from plugin chat UI
  • ✅ Remove sidebar/tool window support - only accessible via status bar
  • ✅ In web UI: add collapse for Configuration section
  • ✅ In web UI: add collapse for Add New Project section

PR Feedback Addressed:

  • ✅ Removed 'created' from release trigger (only 'published' now)
  • ✅ Changed release upload to use plugin-extracted/ directory
  • ✅ Converted all JavaScript to jQuery
  • ✅ Removed all onclick attributes, using pure jQuery event delegation

Latest Changes (Removing onclick Attributes)

Web UI Changes (templates/index.html):

  • Removed all onclick attributes from HTML elements
  • Added CSS classes for event delegation:
    • .toggle-section with data-section attribute for collapsible sections
    • .delete-message-btn with data-index attribute for message deletion
  • Converted to jQuery event delegation:
    • $(document).on('click', '.toggle-section', ...) for section toggles
    • $(document).on('click', '.delete-message-btn', ...) for message deletion
  • Removed window.toggleSection and window.deleteMessage global functions
  • All event handling now uses pure jQuery without inline HTML attributes

Changes Made:

  1. Configuration section toggle - Changed from onclick="toggleSection('configSection')" to class-based event delegation
  2. Add Project section toggle - Changed from onclick="toggleSection('addProjectSection')" to class-based event delegation
  3. Delete message buttons - Changed from onclick="deleteMessage(${idx})" to class-based event delegation with data attributes

This follows best practices by:

  • Separating JavaScript logic from HTML markup
  • Using event delegation for dynamically created elements
  • Avoiding global namespace pollution
  • Making the code more maintainable and testable

Complete Implementation Summary

Files Changed:

  • .github/workflows/build-plugin.yml - DELETED
  • .github/workflows/kotlin-ci.yml - MODIFIED
  • ide-plugins/src/main/kotlin/com/picocode/PicoCodeStatusBarWidget.kt - MODIFIED
  • ide-plugins/src/main/kotlin/com/picocode/PicoCodeToolWindowContent.kt - REWRITTEN
  • ide-plugins/src/main/kotlin/com/picocode/PicoCodeToolWindowFactory.kt - DELETED
  • ide-plugins/src/main/resources/META-INF/plugin.xml - MODIFIED
  • templates/index.html - MODIFIED (now using jQuery with event delegation, no onclick attributes)

Total: 7 files changed, all requirements met, all PR feedback addressed

Original prompt
  • Remove the build-plugin.yml workflow
  • Improve kotlin-ci to upload the artifact if there is a new release
  • The ide-plugin doesn't have a setting in the chat ui to choose the project but only a button re-index project
  • 2025-11-13 16:44:37,509 [25514659] WARN - #c.i.o.w.i.s.w.StatusBarWidgetsManager - Factory is not registered as com.intellij.statusBarWidgetFactory extension: PicoCodeStatusWidget [2]
  • 2025-11-14 09:52:33,030 [ 4642] WARN - #c.i.o.w.i.s.w.StatusBarWidgetsManager - com.picocode.PicoCodeStatusBarWidgetFactory doesn't define 'id' for extension (point=com.intellij.statusBarWidgetFactory). Please specify id attribute. Plugin ID: com.picocode.rag-assistant
  • the chat ui in the plugin says [Error]
    Failed to communicate with PicoCode: Server returned HTTP response code: 400 for URL: http://localhost:8080/code
    Make sure PicoCode server is running on http://localhost:8080 but the project is running and doesn't receive anything check what is happening

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits November 14, 2025 09:06
- Remove build-plugin.yml workflow
- Update kotlin-ci.yml to upload artifacts on releases
- Fix plugin.xml: add id attribute and remove tool window
- Update plugin to use dialog instead of sidebar
- Add project selector to plugin chat UI
- Add message deletion to plugin and web chat UI
- Add collapsible sections to web UI
- Fix /code endpoint HTTP 400 error by including project_id

Co-authored-by: Mte90 <403283+Mte90@users.noreply.github.com>
Co-authored-by: Mte90 <403283+Mte90@users.noreply.github.com>
Copilot AI changed the title [WIP] Remove build-plugin.yml workflow and improve kotlin-ci Fix plugin warnings, HTTP 400 error, and add project selection + message deletion Nov 14, 2025
Copilot AI requested a review from Mte90 November 14, 2025 09:11
Copilot finished work on behalf of Mte90 November 14, 2025 09:11
…h, convert to jQuery

Co-authored-by: Mte90 <403283+Mte90@users.noreply.github.com>
Copilot AI requested a review from Mte90 November 14, 2025 09:23
Copilot finished work on behalf of Mte90 November 14, 2025 09:23
Co-authored-by: Mte90 <403283+Mte90@users.noreply.github.com>
Copilot AI requested a review from Mte90 November 14, 2025 09:35
Copilot finished work on behalf of Mte90 November 14, 2025 09:35
@Mte90 Mte90 marked this pull request as ready for review November 14, 2025 10:35
@Mte90 Mte90 merged commit e0fc766 into master Nov 14, 2025
2 checks passed
@Mte90 Mte90 deleted the copilot/remove-build-plugin-workflow branch November 14, 2025 10:35
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.

2 participants