Add Classic Central Alert Inventory Workflow - #156
Open
KarthikSKumar98 wants to merge 1 commit into
Open
Conversation
- Created index.html with theme detection and loading of assets - Added token.json for API configuration with placeholders - Added token.json.example as a template for users to configure their access token
|
|
||
| @app.get("/{path:path}", include_in_schema=False) | ||
| def application_route(path: str) -> FileResponse: | ||
| static_path = (asset_root / path).resolve() |
| static_path = (asset_root / path).resolve() | ||
| if ( | ||
| static_path.is_relative_to(resolved_asset_root) | ||
| and static_path.is_file() |
| static_path.is_relative_to(resolved_asset_root) | ||
| and static_path.is_file() | ||
| ): | ||
| return FileResponse(static_path) |
|
|
||
| os.replace(temp_path, destination) | ||
| temp_path = None | ||
| temp_stat = None |
| if overwrite: | ||
| os.replace(temp_path, destination) | ||
| temp_path = None | ||
| temp_stat = None |
Comment on lines
+244
to
+253
| def _request_json( | ||
| credentials: Credentials, | ||
| path: str, | ||
| query: Sequence[tuple[str, str]], | ||
| *, | ||
| opener: Callable[..., Any] | None, | ||
| sleep: Callable[[float], None], | ||
| timeout: float, | ||
| should_cancel: Callable[[], bool] | None, | ||
| ) -> Any: |
| status_code, retry_after = _http_error_facts(error) | ||
| try: | ||
| error.close() | ||
| except Exception: |
| webbrowser.open(url) | ||
| try: | ||
| server.run(sockets=[bound_socket]) | ||
| except KeyboardInterrupt: |
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 adds a read-only workflow that retrieves enabled alert configurations from Classic Central. It provides scope-aware browser review and exports results as JSON or CSV for transition assessment, validation, and recordkeeping. This will help users as they transition from Classic Central to Central