Update content of files

This commit is contained in:
GitHub Action 2024-08-05 10:52:21 +00:00
parent 67de2cbb54
commit 4b26b20925

View file

@ -209,10 +209,13 @@ As specified in the constructor docs, some of the fields must not be overwritten
<p>The full info database contains info from the <a href="/constructor/userFull">userFull</a>, <a href="/constructor/chatFull">chatFull</a> and <a href="/constructor/channelFull">channelFull</a> constructors. </p>
<p>To populate the full info database for a peer, invoke <a href="/method/users.getFullUser">users.getFullUser</a>, <a href="/method/messages.getFullChat">messages.getFullChat</a>, <a href="/method/channels.getFullChannel">channels.getFullChannel</a>, all requiring the previously cached <a href="#access-hash">access_hash »</a>. </p>
<p>Populate the full info database only when the client needs some data from a full constructor, <strong>and</strong> there is no entry already in the database. </p>
<p>Full peer info stored to the database must be refreshed <strong>only in the following conditions</strong> (i.e. <strong>do not</strong> refresh user info when opening the profile page, or every time the entry is accessed, <strong>do not</strong> use TTLs to expire the database entries, and so on...): </p>
<p>Invalidate only <a href="/constructor/userFull">userFull</a> and <a href="/constructor/channelFull">channelFull</a> entries 60 seconds after they are stored.</p>
<p>Full peer info stored to the database must be refreshed <strong>only in the following conditions</strong> (i.e. <strong>do not</strong> refresh user info when opening the profile page, or every time the entry is accessed, or when the TTL expires): </p>
<ul>
<li>No entry is present in the full peer database or it was invalidated by the TTL, but some information from a full peer entry was requested by the user or some functionality of the client. </li>
<li>Some event (specified <a href="#peer-info-database">here »</a>) changes the value of a specific subset of fields of an entry in the (non-full!) <a href="#peer-info-database">peer info database »</a>.<br>
The relative full info entry should only be refreshed when some specific fields of the locally cached <a href="/constructor/user">user</a>/<a href="/constructor/channel">channel</a> are changed, see the documentation in the constructor pages for the full list. </li>
<li>When receiving an <a href="/constructor/updateUser">updateUser</a>, <a href="/constructor/updateChat">updateChat</a>, <a href="/constructor/updateChannel">updateChannel</a>, and some other updates, as specified <a href="/type/Update">here »</a></li>
<li>After invoking <a href="/method/bots.setBotInfo">bots.setBotInfo</a> after changing <code>about</code> or <code>description</code> (but <strong>not</strong> <code>name</code>), for the bot whose info we changed.</li>
<li>After invoking <a href="/method/messages.setChatWallPaper">messages.setChatWallPaper</a> to <em>remove</em> the wallpaper and receiving an error, for the peer whose wallpapers we tried to change, to fetch the correct and updated wallpaper settings. </li>
<li>After invoking <a href="/method/messages.setChatAvailableReactions">messages.setChatAvailableReactions</a> and getting an error different from <code>CHAT_NOT_MODIFIED</code>, for the peer whose reaction settings we tried to change. </li>
@ -221,6 +224,19 @@ The relative full info entry should only be refreshed when some specific fields
<li>The <a href="/constructor/channelFull">channelFull</a>.<code>linked_chat_id</code> of channnel/supergroup A is updated to point to channel/supergroup B, but the <a href="/constructor/channelFull">channelFull</a>.<code>linked_chat_id</code> of channel/supergroup B does not point to channel/supergroup A, refresh the <a href="/constructor/channelFull">channelFull</a> of channel/supergroup B.</li>
<li>Info about a bot that is a participant to the channel/supergroup is fetched by other means, but the bot is not contained in <a href="/constructor/channelFull">channelFull</a>.<code>bot_info</code>. </li>
<li>After receiving an error different from <code>USER_NOT_PARTICIPANT</code> when calling <a href="/method/channels.leaveChannel">channels.leaveChannel</a></li>
<li>After successfully invoking any of the following methods, for the bot in question:<ul>
<li><a href="/method/bots.deletePreviewMedia">bots.deletePreviewMedia</a></li>
</ul>
</li>
<li>After invoking any of the following methods (successfully or not):<ul>
<li><a href="/method/bots.setBotGroupDefaultAdminRights">bots.setBotGroupDefaultAdminRights</a> - For the bot</li>
<li><a href="/method/bots.setBotBroadcastDefaultAdminRights">bots.setBotBroadcastDefaultAdminRights</a> - For the bot</li>
<li><a href="/method/bots.setBotInfo">bots.setBotInfo</a> - For the bot</li>
<li><a href="/method/channels.inviteToChannel">channels.inviteToChannel</a> - For the channel/supergroup</li>
<li><a href="/method/channels.editAdmin">channels.editAdmin</a> - For the channel/supergroup</li>
<li><a href="/method/channels.editCreator">channels.editCreator</a> - For the channel/supergroup</li>
</ul>
</li>
</ul>
<p><strong>Do not</strong> refresh full peer information in any other case, to avoid overloading the server by continuously requesting changes for the same unchanged information.</p></div>