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

Keywords are not shown via search box #331

Closed
troplin opened this issue May 7, 2016 · 2 comments
Closed

Keywords are not shown via search box #331

troplin opened this issue May 7, 2016 · 2 comments

Comments

@troplin
Copy link

troplin commented May 7, 2016

When using the search box to find a crate and the using the link from the search results to navigate to that crates's page, keywords are not shown until the page is reloaded

This is yet another strange dependency on the referrer page, like issue #306.

@ducks
Copy link

ducks commented Aug 31, 2016

I found the ember debugger and noticed something funky going on I believe.

The first screenshot below is the first page load after clicking hyper from the search page.
The second is after a page reload.

As you can see, the first time ember seems to be loading the same 10 models from the search page (weird caching?). But the second time it only retrieves the one.

I'm fairly new to ember so I'm not sure why that would happen but it seems like something that could cause issues.

This line I think specifically keywords: computed.alias('crate.keywords').
Since there are 10 crate models vs the 1?

screen shot 2016-08-30 at 5 08 32 pm
screen shot 2016-08-30 at 5 09 06 pm

@carols10cents
Copy link
Member

carols10cents commented Nov 22, 2016

I'm seeing this happen with the new category functionality that I'm adding as well, categories also fail to show up on a crate's page if you navigate to that page from a list of crates. They do show up if you visit the URL of a crate's page directly or if you reload the crate page after arriving :(

carols10cents added a commit to integer32llc/crates.io that referenced this issue Nov 23, 2016
Fixes rust-lang#331. Thank you @locks!!!!

On crate list pages, we had *some* data about each crate, but not
keywords. The way the links were constructed, ember saw the partial data
that matched and would use that on the crate page instead of reloading
the whole crate from the crate show api JSON, which *does* have keywords
available. Using the id with the links instead of the whole model forces
the request for all the data to happen.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants