This PR addresses the renaming of the contentstore/xblock_services folder to contentstore/xblock_storage_handlers as a follow-up to PR #32282. The renaming is done to prevent naming conflicts with xblock runtime services and to make the purpose of the files more understandable. The file xblock_service.py has been renamed to view_handlers.py to better reflect its functionality.
Justification and Future Refactoring Outlook:
The xblock_storage_handlers folder contains service methods that implement the business logic for view endpoints located in contentstore/views/block.py. It is renamed to xblock_storage_handlers to reflect its responsibility of handling storage-related operations of xblocks, such as creation, retrieval, and deletion.
The view_handlers.py file includes business methods called by the view endpoints. These methods, such as handle_xblock, delete_orphans, etc., interact with the required modulestore methods, handle any errors, and aggregate and serialize data for the response.
The term 'handler' in the context of 'view_handlers.py' represents methods that facilitate business logic for view endpoints. It is critical to note the distinction between these 'handler methods' and the xblock_handler method. The xblock_handler is a view endpoint itself, residing in contentstore/views/block.py, and is well known in this context. Although its name might suggest otherwise, it is not a handler in the sense of the 'handler methods' we've defined in 'view_handlers.py'. To maintain consistency with existing naming conventions, it remains as xblock_handler.
* feat: add pagination in course enrollment list API
* refactor: enrollment course list API
* refactor: follow best practice in course enrollment list API
Otherwise we're not really respecting the package-lock file and won't get
repeatable results.
Also:
- Clean up old error handling for npm<3. Were on npm 8 now. Probably
can get rid of this.
- Use the shorthand `npm ci` rather than `npm clean-install` just for
consistency with code elsewhere.
- Update comments in tests to be explicit about use of ci rather than
install
* Swagger was renamed to OpenAPI at some point so use the new name for
clarity.
* Prefix with `lms` to make it clear that these are the APIs from the
LMS and may not all be available in the CMS.
* This project was not being published anywhere.
* The previous commit that adds openapi generation capabilities to the
`docs/guides` replaces what this was doing.
Don't assume that there will be an extra `context` kwarg when using the
bookmark serializer. We use it this way in the current code but that's
specific to us and not comon to all serializers. There are a lot of API
documentation tools that automate introspecting serializers but they
won't know that they have to send in a `context` to the serializer.
To make this serializer behave more like other serializers without
changing the behavior, we just need to check that the `context` value is
defined before we dig into it. In the case that there is no `context`
we just treat it the same as if there is no `request` in the `context`.
* refactor: improve typing of StaticFile named tuple
* feat: copy static asset files into the clipboard
* feat: paste static assets
* feat: show notification in studio about pasted assets
* fix: HTML XBlocks would lose the editor="raw" setting when copy-pasted.
* feat: copy python_lib.zip to the clipboard when it seems to be in use