feat: Add external spreadsheet support with read-only access#2
Draft
feat: Add external spreadsheet support with read-only access#2
Conversation
Contributor
Author
|
@batonac 👋 This repository doesn't have Copilot instructions. With Copilot instructions, I can understand the repository better, work faster and produce higher quality PRs. I can generate a .github/copilot-instructions.md file for you automatically. Click here to open a pre-filled issue and assign it to me. I'll write the instructions, and then tag you for review. |
Co-authored-by: batonac <4996285+batonac@users.noreply.github.com>
…eadsheet support Co-authored-by: batonac <4996285+batonac@users.noreply.github.com>
Co-authored-by: batonac <4996285+batonac@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] feat: external spreadsheet support
feat: Add external spreadsheet support with read-only access
Aug 12, 2025
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
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.
This PR implements external spreadsheet support for the GASS framework, allowing read-only access to external Google Sheets using the Sheets API. The implementation enables developers to create Entry classes that retrieve data from spreadsheets outside of the current active spreadsheet while maintaining the same familiar API.
Key Features
External Entry Definition: Extended
IEntryMetainterface with an optionalspreadsheetIdfield. When present, the entry is treated as external and uses the sheet name (string) instead of numeric sheet ID:Optimized Filtering: Implements the exact scenario described in the issue using efficient API calls:
Read-Only Protection: External entries are automatically protected from modification operations. Attempts to save, update, or delete external entries throw clear error messages, preventing accidental data corruption.
A1 Notation Generation: Automatically synthesizes proper A1 notation from sheet metadata, converting column numbers to letters (1→A, 27→AA) and generating ranges like
"Affiliates!B2:B"for filtering operations.Technical Implementation
EntryRegistrysupports both internal and external entries in the same applicationbatchGetfor filtering to minimize API calls and data transferAPI Coverage
The implementation supports all standard Entry methods for external sheets:
Entry.get(filters)- Filtered retrieval with external optimizationEntry.getAll()- Bulk retrieval from external sheetsEntry.getValue(filters, column)- Single value extractionsave,delete,batchSave) are properly blocked with informative errorsDocumentation
Includes comprehensive documentation with working examples, API explanations, best practices, and unit tests to validate core functionality.
Fixes #1.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.