Skip to content

Conversation

lizlooney
Copy link
Collaborator

Removed functions related to projects from the Storage interface. Added code to project.ts to handle project stuff.

This will make implementing the server side storage easier.

Added listModules and fetchModuleDataModifiedMillis functions to Storage interface.
Added modulePathFilter parameter to listModules.
Removed renameProject and copyProject.
Removed moduleType parameter from deleteModule.

In client_side_storage:
Updated implementation of Storage interface (see above).
Removed _renameOrCopyProject.

In names:
Added makeModulePathPrefix.

In project:
Updated renameProject and copyProject functions.
Added renameOrCopyProject function.
Removed renameModule, copyModule, and _renameOrCopyModule from client_side_storage

In project.ts, updated implementation of renameModuleInProject and copyModuleInProject. Added renameOrCopyModule function.
Removed deleteProject from client_side_storage.

In project.ts, updated implementation of deleteProject.
Removed downloadProject from client_side_storage.

In project.ts, replaced produceDownloadProjectBlob with downloadProject.

In Menu.tsx, call storageProject.downloadProject instead of storage.downloadProject.
Removed uploadProject from client_side_storage.

In project.ts:
Added uploadProject function.
Modified processUploadedBlob to return just classNameToModuleContentText.
Moved code from processUploadedModule to processUploadedBlob.

In Menu.tsx, call storageProject.uploadProject instead of storage.uploadProject.
@lizlooney lizlooney requested a review from alan412 August 11, 2025 06:45
Copy link
Collaborator

@alan412 alan412 left a comment

Choose a reason for hiding this comment

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

I am approving this, because I think it takes us in the right direction. However, I think we will want a listProjects that doesn't read all of the modules. That way it will return quickly. I think of it like reading a directory. You want to return the subdirectory names without parsing all of the files in each subdirectory.

@alan412 alan412 merged commit fa92a90 into wpilibsuite:main Aug 11, 2025
1 check passed
@lizlooney lizlooney deleted the pr_refine_storage_interface branch August 11, 2025 16:11
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