-
Notifications
You must be signed in to change notification settings - Fork 35
Add wiki moderator management and validation #250
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
Open
samuel-asleep
wants to merge
2
commits into
RetroShare:master
Choose a base branch
from
samuel-asleep:Add-wiki-moderator-management
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Add wiki moderator management and validation #250
samuel-asleep
wants to merge
2
commits into
RetroShare:master
from
samuel-asleep:Add-wiki-moderator-management
+546
−10
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* Add wiki moderator management and validation * Add implementation prompt for Wiki modernization This document provides implementation guidance for modernizing the Wiki in the libretroshare submodule, focusing on a forums-style moderator system. It includes context, requirements, files to modify, testing requirements, and an implementation checklist. * Add wiki moderator management and validation (#1) * Add wiki moderator management and validation * Initial plan * Address PR review comments: improve error messages and verify token completion Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Address review feedback: enhance error messages and verify token completion Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Delete _codeql_detected_source_root * Delete Libretroshare_promp.md --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Update for Todo 3 * Create Prompt.md * Add content fetching APIs for Wiki edit merging (Todo 3) (#5) * Initial plan * Wiki: Add content fetching APIs for edit merging (Todo 3) Implement getSnapshotContent() and getSnapshotsContent() methods to enable full content merging functionality in Wiki edit dialog. Changes: - Added content fetching methods to RsWiki interface (rswiki.h) - Implemented in p3Wiki class (p3wiki.h/cc) - Uses GXS token-based requests with waitToken for synchronous fetching - Returns page content mapped by snapshot message ID These APIs enable the GUI to fetch actual page content from selected edits for diff-based merging, completing Todo 3 implementation. Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Address code review feedback for content fetching APIs - Return true for empty input in getSnapshotsContent() for consistency - Use find() instead of count() for better performance - Return true even when no snapshots found (successful zero-result operation) Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Final update: Implementation complete and verified All tasks completed: - Interface methods added to rswiki.h - Implementation in p3wiki.h/cc - Code review feedback addressed - Security checks passed Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Address code review: Update docs and clarify API limitations - Fix documentation for getSnapshotsContent() return value - Add explanatory comments about GXS API limitation requiring full fetch - Clarify that fetching all messages is necessary when GroupId is unknown Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Delete _codeql_detected_source_root * Delete Prompt.md * Fix GXS API usage in snapshot content retrieval methods (#7) * Initial plan * Fix review comments: add <set> include, populate grpIds, clear contents map Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Use consistent token-based getGroupList in getSnapshotsContent Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Document intentional behavior difference between methods Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Fix GXS API usage in snapshot content retrieval methods Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Delete _codeql_detected_source_root --------- Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Address PR review comments: documentation and code optimizations (#9) * Initial plan * Address PR review comments: add docs, optimize addModerator, remove redundant check Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Final update: all actionable review comments addressed Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Remove unnecessary unique() call in addModerator Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Delete _codeql_detected_source_root * Fix compilation errors: disambiguate getGroupList and replace private member access * Initial plan * Fix compilation errors: disambiguate getGroupList and fix private member access Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Complete fix verification and code review Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Update src/services/p3wiki.cc Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> Co-authored-by: Akinniranye Samuel Tomiwa <benneu40@gmail.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Fix p3wiki.cc compilation errors: use retrieveNxsGrps and fix const-correctness * Initial plan * Fix compilation errors in p3wiki.cc Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Improve error handling in getCollectionData to match rsgenexchange.cc pattern Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Delete _codeql_detected_source_root * Add public getter for RsGenExchange::mDataStore (#19) * Initial plan * Add public getter for mDataStore and update p3wiki.cc to use it Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Complete: Fixed private member access violations Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Delete _codeql_detected_source_root --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> Co-authored-by: Akinniranye Samuel Tomiwa <benneu40@gmail.com> * Add specific Wiki event codes and classification logic * Initial plan * Add 4 new specific Wiki event codes and update notifyChanges logic - Add NEW_SNAPSHOT (0x03), NEW_COLLECTION (0x04), SUBSCRIBE_STATUS_CHANGED (0x05), NEW_COMMENT (0x06) to RsWikiEventCode enum - Update p3Wiki::notifyChanges() to distinguish NEW vs UPDATED events based on notification type - Add mKnownWikis tracking to distinguish new collections from updates - Detect comment vs snapshot messages based on RsGxsWikiCommentItem type - Handle subscribe status changes with TYPE_PROCESSED notification Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Fix nullptr check for mNewMsgItem before dynamic_cast Follow the pattern used in p3gxschannels to check for nullptr before dynamic_cast on mNewMsgItem Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Complete implementation of specific Wiki event codes Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Remove CodeQL build artifacts and update .gitignore Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Add build/ to .gitignore * Fix RsMutex constructor call - add required name parameter Initialize mKnownWikisMutex in p3Wiki constructor's initializer list with descriptive name, following the pattern used in p3GxsChannels Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Delete _codeql_detected_source_root * Initialize wiki event code for delete notifications * Initial plan * Add Wiki notification support with blocking helper methods - Add protected blocking helper methods to RsGxsIfaceHelper: * getServiceStatisticsBlocking() - synchronous service statistics retrieval * getGroupStatisticBlocking() - synchronous group statistics retrieval - Add public getWikiStatistics() method to RsWiki interface - Implement getWikiStatistics() in p3Wiki service using blocking helper Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Increase default timeout to 10 seconds for blocking helpers Address code review feedback: increase default timeout from 5 to 10 seconds to be more robust in high-load scenarios, matching similar patterns in the codebase. Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Complete Wiki notification support implementation All changes have been successfully implemented and reviewed: - Added protected blocking helper methods to RsGxsIfaceHelper - Added public getWikiStatistics() to RsWiki interface - Implemented in p3Wiki service - Addressed code review feedback (10s timeout) - Security scan passed (no vulnerabilities) Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> * Remove CodeQL temporary symlink --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Author
Contributor
Author
|
@csoler can you please review |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR introduces comprehensive wiki moderator management functionality and validation mechanisms to the libretroshare codebase.
Changes
Technical Details