Codecov reported 55.55% patch coverage on the previous commit: four of the nine
measured lines were only partially covered. No test paginates forwards in a
thread timeline, and the focus states Requested, Loading and Failure were never
live when a forward pagination arrived, so only the Success branch of
isPending() was ever evaluated both ways.
Add a test per uncovered state: a forward pagination is deferred while the focus
request is still being debounced and while the focused timeline is being
created, it is performed again once the request has failed, and it is dropped in
a thread timeline while a backward one still goes through.
The pagination recorder now also sits on the live timeline, and the presenter is
built on that same timeline. Before the detached timeline exists, a pagination
that escaped the gate would go to the live one, so without this the new guards
would pass against the unfixed presenter. The deferred cases end on the emitted
state rather than on cancelAndIgnoreRemainingEvents for the same reason: the
recorder throws from inside the presenter coroutine and cancelling swallows it.
Verified by reverting the gate: the three deferred-pagination tests then fail
with "This lambda should never be called."
Opening a room from a notification asks the timeline to focus the notified
event. When that event is outside the loaded live window the controller
creates a detached timeline for it, and a detached timeline always carries a
forward loading indicator as its last chronological item. The items list is
reversed for display, so that indicator is the bottom-most row and is composed
on first layout, which unconditionally emits a forward pagination request
nobody asked for. Because a notified event sits close to the live end, that one
page reaches the end, and the controller responds by closing the detached
timeline. The live window replaces the item list while it is still anchored at
the bottom, so the user lands on the newest message and the focus request is
discarded.
Defer automatic forward pagination while a focus request is still pending. Once
the focused event has been rendered the viewport has moved off the indicator
row, so only a real scroll back to the live end switches to the live timeline,
which is what the controller's existing behaviour is for. Backward pagination
and the explicit jump-to-live action are untouched.
* Explain a rate limiting push gateway in the notification troubleshooter
The push loop back test printed whatever HTTP status the gateway
answered, so a user throttled by the public ntfy.sh gateway was told
"Error: HTTP 507", which reads as a server fault rather than as a quota
they can wait out or move away from.
Map the two statuses that mean the notification was throttled onto a
typed failure and give the troubleshooter a message that says what to do.
* Import strings from localazy, remove `temporary.xml` in `:libraries:push:impl`
---------
Co-authored-by: Jorge Martín <jorgem@element.io>
Cover the last remaining interfaces across libraries/audio, libraries/cachestore,
libraries/indicator, libraries/slashcommands, libraries/voiceplayer and
services/apperror, with their members and parameters.
This completes the effort: all 222 in-scope interfaces and their 820 members in
the 60 api modules that hold any now carry documentation.
Notable points: CacheStore applies no expiry of its own and only records when each
entry was written, leaving staleness to the caller; SlashCommandService.parse
never throws, returning NotACommand for ordinary text and an error case for a
malformed command.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Cover the last remaining interfaces across features/announcement, cachecleaner,
call, contentscanner, createroom, knockrequests, lockscreen, rolesandpermissions,
startchat, userprofile and viewfolder, with their members and parameters.
Grouped into one commit rather than eleven near-empty ones, per the AGENTS.md rule
about tiny commits.
This completes every features/* api module.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Cover the remaining interfaces of features/login, features/logout,
features/preferences and features/share, along with their members and parameters.
Points recorded here: AccountProviderAccessControl returns true on a build with no
enterprise restriction, ExtraDeveloperOptionsRenderer is bound to a no-op in the
standard build, DirectLogoutView draws nothing until a logout event is sent, and
CacheService exists because clearing a cache destroys the client and the app has
to react.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document AcceptDeclineInviteEvents, AcceptDeclineInviteView and the
SeenInvitesStore interface.
The view doc explains why it is a shared component rather than part of one screen:
it is embedded everywhere an invitation can be acted on, so the confirmation
dialogs behave identically in the invite list and in a room preview.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document the members of SecretKeyRepository and EncryptionDecryptionService.
The caveat worth having in the API doc comes from KeyStoreSecretKeyRepository:
requiresUserAuthentication only takes effect when the key is created, so an
existing key keeps whatever protection it was created with.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document the members of AppNavigationStateService and AppForegroundStateService
that had none, and add the missing @param entries.
The recurring `owner` parameter is now explained, from
DefaultAppNavigationStateService: the navigation state is a stack, pushing a level
without its parent logs an error and does nothing, and a leave call whose owner
does not match the current level is silently ignored so that a node which has
already been replaced cannot pop someone else's state.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document RageshakeFeatureAvailability, LogFilesRemover and the BugReporter
interface, and complete the docs of its remaining members.
The BugReporter doc records that progress and the outcome arrive through the
listener passed to sendBugReport rather than through a return value or an
exception.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document LocationService, StaticMapUrlBuilder, TileServerStyleUriBuilder and the
members of ActiveLiveLocationShareManager that had none.
The two URL builders now say what happens when no map provider is configured for
the build, which is the case LocationService.isServiceAvailable exists to guard.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Cover the remaining interfaces of libraries/troubleshoot, libraries/matrixmedia,
libraries/dateformatter, libraries/featureflag, libraries/workmanager and
libraries/mediaviewer, along with their members and parameters.
Behaviours worth recording: NotificationTroubleshootTest reports its outcome
through its state flow rather than by returning, and its quickFix throws unless
the test offers one; DateFormatter.format turns a null timestamp into an empty
string so callers need no null check; ImageLoaderHolder keeps one loader per
session because decrypting room media needs that session's client.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document PickerProvider and each of its register methods.
The interface doc carries the two rules that apply to all of them: they must be
called during composition rather than from a click handler, and a cancelled pick
arrives as a null uri or an empty list rather than as an error.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document PusherSubscriber and PushHandler at the interface level, document the
PushProvider members that had none, and add the missing @param entries.
Notable points: getCurrentDistributor also returns null when the stored
distributor is no longer installed, rotateToken throws unless canRotateToken is
true, and handleInvalid records the payload in the push history for diagnosis.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document SessionStore, SessionObserver and SessionListener at the interface level
and add the missing @param entries.
The store doc records that sessions are ordered by last usage, which is what makes
"the latest session" meaningful across the rest of the interface, and the listener
doc explains that wasLastSession is the signal to clean up app-wide data too.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document AnalyticsProvider, AnalyticsTransaction, AnalyticsTracker and
ErrorTracker at the interface level, and add the missing @param entries.
The provider doc records that providers are driven by the analytics service and
only receive data once the user has consented, and that startTransaction returns
null on a provider with no performance support.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Add the interface level docs that StringProvider, SystemClock and
BuildVersionSdkIntProvider were missing, document ExternalIntentLauncher.launch,
and add the remaining @param entries.
Each doc says why the abstraction exists rather than restating the signature:
these wrap Context, Build.VERSION and the clock so that presenters can be tested
without them.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document OAuthIntentResolver and OAuthActionFlow along with their members.
OAuthActionFlow now explains why it exists rather than the result simply being
returned: the activity that receives the redirect and the login screen waiting for
it are not in the same navigation subtree.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document UserRepository and UserListDataSource along with their members.
Two behaviours from MatrixUserRepository and MatrixUserListDataSource are recorded
because callers rely on them: the data source swallows a failed directory request
into an empty list, and a query that is a well-formed user id other than the
current user's yields that user even when the directory does not know them.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document RoomLatestEventFormatter, TimelineEventFormatter and
PinnedMessagesBannerFormatter along with their members.
The formatters return a nullable CharSequence, so each one now states what null
means: the event is not rendered as text at all.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document DeeplinkParser, DeepLinkCreator and InviteFriendsUseCase, including that
DeepLinkCreator.create silently ignores the deeper arguments once an outer one is
null.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document RoomMemberModerationState, RoomMemberModerationEvents and
RoomMemberModerationRenderer along with their members and parameters.
The renderer doc states that it draws nothing until the host screen asks for a
member's actions, and that onSelectAction exists so the host can navigate for the
actions that need a screen of their own.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document PollContentStateFactory, SendPollResponseAction and EndPollAction along
with their members and parameters.
The two action interfaces exist to wrap a plain timeline call, so their docs say
what they add: both capture an analytics event on success, which is the reason
callers should go through them rather than calling the timeline directly.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document LeaveRoomState, LeaveRoomEvent and LeaveRoomRenderer.
The renderer doc records the two things a host screen needs to know, both taken
from LeaveRoomPresenter and LeaveRoomView: it draws nothing until a leave event is
sent, and onSelectNewOwners fires specifically when the user is the last owner of
a room that still has other members.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document InvitePeopleState and each of its properties, InvitePeopleEvents,
InvitePeopleRenderer and the presenter factory.
The state properties now say what drives them, in particular that
createRoomFromDmAction covers the case of inviting a third person into an
existing direct message, and that the factory accepts a null room for that flow.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document HtmlConverterProvider, MessageComposerContext,
PinnedEventsTimelineProvider, the MessagesEntryPoint node proxy and the voice
message composer factory.
HtmlConverterProvider carries the ordering constraint that matters: the converter
is rebuilt from the Compose theme, so Update has to be composed before provide is
called.
MessagesEntryPoint and its Callback are navigation plumbing and out of scope.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document EnterpriseService, SessionEnterpriseService and
RemoteEnterpriseConfigProvider along with all their members and parameters.
Two points that callers get wrong are stated explicitly: these services return
permissive defaults on a standard build, so there is no need to branch on the
build type, and SessionEnterpriseService only answers meaningfully once init has
run. The many nullable getters now say what null means in each case, which is
generally "no override, use the app default".
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document PermissionsStore, PermissionStateProvider, LocalNetworkPermissionAdvisor
and the PermissionsPresenter factory, along with their members and parameters.
The store doc explains why the module exists: Android does not let an app
distinguish "never asked" from "asked and denied", so the app has to remember
that itself in order to decide whether it may show a rationale.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document UserPushStore, UserPushStoreFactory, PushClientSecret,
PushClientSecretStore and PushClientSecretFactory along with all their members.
The client secret interfaces now explain why they exist at all: a push gateway
delivers notifications without saying which account they belong to, so the secret
is what lets an incoming push be attributed back to a session.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document WellknownRetriever, ElementWellknownStore, ElementWellKnownParser and
their factories, along with every member.
The caching semantics are the part callers need and cannot see in the signatures,
so they are recorded here: the store reports entries older than a day as outdated
rather than missing, the retriever returns such a value immediately and refreshes
in the background, an enterprise build with a hardcoded configuration
short-circuits entirely, and the parser ignores unknown JSON fields.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document MediaSender and all its members, its two factories, MediaPreProcessor,
MaxUploadSizeProvider and MediaOptimizationConfigProvider.
The MediaSender doc explains the two-step shape of the API, which the individual
signatures do not convey: pre-processing and sending are separate so a preview
can be shown in between, and the temporary files that pre-processing creates are
only released by cleanUp, whether or not anything was ultimately sent.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document AddRecentEmoji, GetRecentEmojis.invoke, the EmojiPickerRenderer
interface and the EmojiPickerPresenter factory, pointing at the no-op renderer
and the empty recent-emoji source so callers know how to opt out of each.
EmojiPickerPresenter itself is a Presenter and therefore out of scope.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Document AnalyticsService and ScreenTracker at the interface level, document the
members of the cold start and room list watchers, and add the missing @param
entries across the analytics interfaces.
The AnalyticsService doc states the rule that applies to the whole interface:
nothing reaches the providers until the user has given their consent.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>