Feature/authenticate extension calls#525
Open
Joabesv wants to merge 50 commits into
Open
Conversation
Keep connectors in-app for first iteration. Reverts app files to migration versions using @/connectors/* and @/errors/*, restores apps/core connectors and errors, drops @next/connectors dep from core and extension package.json. Standalone packages/connectors preserved for later use.
Duplicate logger was left at src/logger.ts by a merge conflict. Removes it and updates server.ts and two job/route imports to use @/utils/logger.js.
Enable allowImportingTsExtensions and switch internal relative imports from .js to .ts to match the package's direct-.ts exports.
Remove config.ts and configureConnectors/getConnectorConfig. UfabcParserConnector now takes (baseURL, requesterKey, traceId). SigaaConnector, UfabcMatriculaConnector, MoodleConnector now take (baseURL, traceId) instead of hardcoding URLs. Drop their singleton caching since baseURL is per-call. Remove ./config from package exports.
Remove schemas/index.ts barrel. Add per-schema subpath exports (./schemas/next-api, ./schemas/ufabc-parser, ./schemas/moodle) to package.json. Errors remains the only barrel export.
Replace node:timers/promises sleep with globalThis.setTimeout-based Promise in moodle connector and node:crypto randomUUID with globalThis.crypto.randomUUID in base-aws-connector.
Add defaultHeaders support to BaseRequester (merged into every outgoing request before global-trace-id). AIProxyConnector now takes an options object (baseURL, defaultHeaders, globalTraceId) instead of a dedicated serviceHeader param; callers pass x-service-id via defaultHeaders.
Replace extension's ofetch-based services with the shared @next/connectors package: - services/ufabc-parser.ts: use UfabcParserConnector (baseURL from WXT_UFABC_PARSER_URL); getUFComponents now returns UfabcParserComponent from @next/connectors/schemas/ufabc-parser. - services/next.ts: use NextApiConnector (baseURL from WXT_UFABC_NEXT_URL); re-export schema types Component, MatriculaStudent, SigStudent, UpdatedStudent; keep view-specific local types (TeacherReview, SubjectReview, Grade). - KicksModal.vue: adopt UfabcParserComponent fields (ufComponentId, shift) replacing legacy UFSeasonComponents (UFComponentId, turno). - Add ./next-api to package exports; make UfabcParserConnector traceId optional to support browser long-lived instances.
…cate-extension-calls
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.
Descrição
Tickets relacionados
Como testar esse PR