Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rtl cache ssr #2247

Merged
merged 3 commits into from
Jan 14, 2025
Merged

Rtl cache ssr #2247

merged 3 commits into from
Jan 14, 2025

Conversation

akiva10b
Copy link
Contributor

Description

A brief description of the PR

Code Changes

The following changes were made to the files below

Notes

Any additional notes go here

let settings = {context: 1, enVersion: panel.enVersion, heVersion: panel.heVersion};
//save versions first, so their new format is also saved on text cache
if(panel.text?.versions?.length){
let versions = Sefaria._saveVersions(panel.text.sectionRef, panel.text.available_versions);
let versions = Sefaria._saveVersions(panel.text.sectionRef, panel.text.versions);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@YishaiGlasner please verify that this is a correct change

const mergeTextInt = mergeText ? 1 : 0;
const return_format_string = (return_format) ? `&return_format=${return_format}` : '';
const encodedRef = Sefaria.normRef(ref);
const url = `${host}${endPoint}${encodedRef}?version=${versions.join('&version=')}&fill_in_missing_segments=${mergeTextInt}${return_format_string}`;
return url;
},
_textsStore: {},
_textsStoreSet: function(key, value) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

doc string to explain why we have 2 caches?

@akiva10b akiva10b merged commit 580678f into rtl-client Jan 14, 2025
17 checks passed
Copy link

sentry-io bot commented Jan 19, 2025

Suspect Issues

This pull request was deployed and Sentry observed the following issues:

  • ‼️ TypeError: undefined is not an object (evaluating 'Yn.virtualBooks.includes') Sefaria.parseRef(sefaria/sefaria) View Issue
  • ‼️ TypeError: Cannot read properties of undefined (reading 'includes') Sefaria.parseRef(sefaria/sefaria) View Issue
  • ‼️ TypeError: Cannot read properties of undefined (reading 'includes') Sefaria.parseRef(sefaria/sefaria) View Issue

Did you find this useful? React with a 👍 or 👎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants