Related Posts not displaying sometimes since update
-
I posted this question a week ago, saying that after I updated to Contextual Related Posts 3.0.3, related posts display some of the time but not all of the time. I discovered that if I uncheck the box for “Related posts based on title and content” (in List Tuning), they display again. But I have some posts where none display if that box is checked.
You suggested that I set “Limit content to be compared” under List Tuning to 70. That fixed it for a while, but now it’s happening again on at least one post. I set “Limit content to be compared” to 40, and that hasn’t fixed it.
I used Query Monitor and here are 2 screenshots of the errors on that page:
The page I need help with: [log in to see the link]
-
I have to admit this one is frustrating me!
Can you please post the link of your post – I’d like to try the contents of your post in my test install to see if I can duplicate this issue.
One option am thinking is to use to Keyword function in the meta box at the bottom of the edit post screen to enter a few keywords that will work.
Am trying to see what else I can do to pull related posts when this error pops up as it is quite random and I think depends on the actual content of the post that confuses the preg_match
Right now the post isn’t published — it’s in draft mode and publishes tomorrow. Would it help for me to paste the contents here? If so, they’re below. The headline is:
interviews when you have food allergies, snow days when not everyone can work from home, and moreContents of post are:
It’s five answers to five questions. Here we go…
1. Food allergies and etiquette
I recently found out (by way of nearly dying the night before my wedding, no less) that I have a life-threatening allergy to seafood. Due to the severity of the reaction, I only eat at restaurants that have absolutely no seafood on the menu. This severely limits me, as most restaurants have at least one seafood dish, and even those that don’t often have “hidden” things like Caesar dressing that have fish in them.
I am extremely nervous about how this may impact my future. I currently work in corporate finance and I am going to get my MBA, so I will surely be interviewing in the future. If someone wants to meet over a meal, do I disclose this? Do I ask to meet over coffee instead? It’s easy enough for one interview, but what happens if I’m invited to a company for a “sell day/weekend”?
I also worry how this will affect my long-term career goals — food can be such an important way to connect. Going out for lunch, potlucks, cakes for special occasions, company dinners, catered meetings — I’m mourning the loss of all of these opportunities. Will I ever be able to shake the “allergic” label, or will people always feel a little bit uncomfortable that I never join in the food festivities?
A lot of people deal with similar issues, more than you might think — not only people with serious allergies but also strictly observant kosher Jews and others. You should be fine!
If you’re invited to an interview over a meal, it’s fine to say, “I have an allergy that makes it risky to eat in most restaurants. Would it be possible to meet over coffee instead?” In other situations, like a sell weekend, it should be okay to bring your own food if that’s the easiest way to handle it. If asked about it, you can matter-of-factly say, “Oh, tricky food allergies — this keeps it a lot simpler.” If it’s an option for you to go to group meals and just nurse a drink or a snack you bring yourself, that can be useful to do since a lot of networking happens over meals; just keep being matter-of-fact and treating it like it’s no big deal and other people will generally take their cues from you. (Also, it’s helpful to research restaurants that are safe for you ahead of time so you can suggest those.)
You will probably run into people who want to solve this for you — to find a restaurant you can eat at, order something in for you, etc. If you’re comfortable with that, let them do it. If you’re not, it’s fine to say, “It’s restrictive enough that this is easiest, but thank you for offering!”
It’ll be easier once you’re working somewhere; at that point the logistics of bringing your own food (especially to things like potlucks) get a lot more straightforward (you just do it, basically). And if you have a good office, you can often work with the person who orders food for events to order you meals from a place you know is safe.
2. Snow days when only some people can work from home
Over the past year due to COVID-19, my agency has been able to support most of the staff in most departments with either working from home full-time or figuring out some sort of part-time work-from-home situation. However, this is not a small agency and there are still many positions that cannot be completed from home. My question is about how snow days should be handled. Management wants everyone with the ability to complete their work from home to do so, but is giving those whose work can only be completed in-office the day off fully paid. This doesn’t seem fair and also makes me wonder about situations where people who can technically complete their work from home may lose power or internet.
Yeah, it’s not ideal — but it’s better than the alternative, which would be everyone getting the day off with pay and no work getting done even though it could be. It’s reasonable to say that you want everyone to work who can, and those whose jobs don’t allow it won’t be penalized. I’d also point out that people who can work from home get perks that the office-only people don’t — like not having to take the day off when you have a repair person coming or a kid is home sick, being able to do your laundry while you’re on conference calls, etc. This is the flip side of those advantages.
3. Should I tell an employer why I’d never take the job?
After completing the last round of interviews for a role I had never been very enthusiastic about, I concluded there was nothing they could offer that would make me happily accept the role and so emailed the HR rep to withdraw from consideration. As this is a company it’s conceivable I’d like to work for at some point in the future (albeit not in this role or department), I left it polite and vague. They quickly emailed back to ask for an explanation and now I’m conflicted. I learned many things about the company and the role that were major red flags for me.
There was little to no cross-training, resulting in people on the team being unable to take vacations since there’s no one to cover for them. Conflicts between short-term crises users are having and long-term team goals were left to individuals and not managers, resulting in the boss admitting people who were “unable to manage their time” were punished for not “achieving team goals.” Their tech stack was outdated 20 years ago and, while they’re updating, that would make them out of date by about 15 years — meaning if I accepted this role, every year I worked for them I would be increasingly unviable for jobs in the modern era. The HR manager in my initial screen seemed very skeptical that I, a woman, would really be interested in or capable of a highly technical role. When I asked how they are handling keeping morale up during a pandemic, I was told they have a very formal mandatory fun plan. Suffice to say, there were many issues there and none of them sound polite or positive when I type them out.
How do I play this? I feel like any even slightly informative or truthful response can only hurt me and potentially burn bridges. Is it rude to just ignore the follow-up email or is that also going to cause potential drama? I’m already the sort of person who declines most exit interviews (if you didn’t listen to me while I worked for you, why would you care now that I’m leaving?) and I can see even less reason to go out on a limb to help an employer who would have sent me an automated rejection email without any explanation if the tables were turned. I’m almost tempted to respond that my freelance consulting rates are such and such, if you’d like to discuss this further let’s make an appointment, because I do have a lot of ideas about how they could improve and modernize. But I’m sure that would be seen as wildly gauche. What do you think?
Yeah, don’t cite your consulting rates. They’re not asking for consulting; they’re asking if there’s something you can easily and comfortably convey about why the job wasn’t right for you (just like many job applicants ask if there’s something the employer can easily and comfortably convey about why they were rejected). It’s okay for them to ask.
But you’re not obligated to give a full answer! You can go with something very vague, like that you’re focusing on other roles that are more in line with what you’re looking for in your next position. Or you could pick one thing that’s not terribly loaded, like that it’s important to you to work with more modern tech in order to keep your skills up-to-date. (At least, that won’t be terribly loaded if they’re generally reasonable, and it’s actually helpful feedback to hear.) Personally, I’d love for you to attribute it to the HR rep who didn’t think women are interested in or capable of highly technical roles — that’s something they need to hear about, and there’s no reason you can’t say it.
But you don’t need to say any of this if you don’t want to get into it. It’s fine to just stay super vague — “I appreciated getting to know your team more but right now am focusing on other roles that are more X and Y.”
4. Should I tell my boss I want to change careers?
I am in my mid-20s and currently three years into my first post-uni job in the arts sector. I work for a very small charity in a close-knit and supportive team. I am considering a complete career change into a totally unrelated sector as, while I have enjoyed my current job, I don’t see myself doing it much longer and don’t want to progress in this sector.
I’ve had a new manager start recently who has subtly asked about my future career plans and mentioned that he wants to help support me in developing skills that will help me progress in the future. At my recent appraisal, my boss said similar things and asked me to consider training and development opportunities they could provide that would help me develop my skills in my career going forward.
I don’t know how honest to be about the fact that I want to change careers and have no desire to progress in this sector. They are so supportive and keen to help but seem to be assuming that I will want to progress in the same sector. I don’t have any immediate plans to leave, but I also don’t want to give a false impression when I do plan to leave eventually. Should I share with them that I am wanting to change careers, and if so how should I go about it, or should I just say that I don’t know what I want to do yet?
Don’t tell them that you want to change careers, or even that you don’t know what you want to do yet. That’s the kind of thing that gets people written off as not invested and can affect what opportunites you’re given and can even put your name at the top of the list if they need to make cuts.
That said, you also don’t need to fake ambitions you don’t feel. It’s generally okay to say something like, “For right now, I’m really happy with what I’m doing currently and would like to stay with what I’m doing for the foreseeable future.” You could add, “If I do come up with a specific path I’m interested in beyond that, I will definitely talk to you about it at that point.”
But it’s also worth thinking about what kinds of skill-building they’re able to offer you. Even if you don’t plan to stay on this career path, will any of those skills help you with other jobs? A lot of skills are transferrable from one career to another and could end up helping you get whatever job you target next. (And if you have no idea, sometimes it’s useful just to be able to show that you took on progressively more responsibility and/or continued to get better and better at something, even if it’s not directly relevant to whatever comes next.)
5. Can my employer make me return to the office before I’m vaccinated?
I am a client-facing senior employee at a very large national corporation. To their credit, my company has ordered everyone to work from home since March and has focused on making us as productive as possible at home. The company has been vague about when we will return to the office, but at this point it is clear that we will be home through the winter.
Can the company make return to the office before I am able to get a COVID vaccination? As an under-40, healthy individual with no underlying conditions, I suspect that I will be last in line for the vaccination, and rightly so. Many of my colleagues are older and belong to groups that will be prioritized. I imagine that offices will begin to open up once a large chunk of the population has been vaccinated. I have been careful about social distancing and would prefer to work from home until I can get the vaccination. Can my employer make me go back to the office before then?
Legally, yes, your company can require you to return to the office as a condition of keeping your job. If you have a disability that makes that risky, you can propose alternatives (although they can counter-propose other solutions). In your case, though, it doesn’t sound like that’s the case.
That said, just because they <i>can</i> require it doesn’t mean they will. You can talk to your manager and explain it’s important to you to continue to minimize your risk (and the risk of others in your household) until you’re vaccinated; lots of people are doing that, or will be doing that, and a lot of employers are willing to work with people on this. Not all, but it’s worth making the case for it.
Just an update to say that adding a keyword in the keyword box did fix it. It would still be great not to have to do that though, since it was never needed before this latest update!
Thanks for this. It won’t be immediately, but going to try to do a check that if it doesn’t generate any related posts in the default state – need to check if this is because of an error or not then it will find related posts by an alternate method.
I’ll get this out in v3.1.0 update. One thing that I can suggest for now if you’re facing multiple issues is to make an edit directly into the CRP core files.
https://github.com/WebberZone/contextual-related-posts/blob/v3.0.4/includes/main-query.php#L81
Replacing the function with get_crp_posts_id which uses the old function.
I think I figured out the issue with the incorrect table being found. Are you in a position to edit the plugin files, if so, could I ask you to please make this change:
https://github.com/WebberZone/contextual-related-posts/blob/v3.0.4/includes/class-crp-query.php#L379
Replace with this line – all that I’m doing is removing instances of ” from” which is a stopword anyway.
$match_fields_content[] = str_replace( ' from', '', crp_excerpt( $this->source_post, min( $this->query_args['match_content_words'], CRP_MAX_WORDS ), false ) );I have implemented this fix in the Github repo and will aim to get this out over the weekend
-
This reply was modified 5 years, 4 months ago by
Ajay.
That last suggestion fixed it! I was even able to change “Limit content to be compared” under List Tuning back to 0. Thank you for finding the fix!
Thanks for confirming! It’s going out in the update today.
Hmmm, it has started happening again! I hadn’t updated yet, so I installed the update but it didn’t make a difference. Is there more info I can give you?
Have you now updated. Are you getting the database errors with Query Monitor – and if so, can you please check what the word it says is the name of the database in the database error and give me the sentence that contains that word?
I’m not totally sure what that means, but here’s a screenshot of the error with Query Monitor:
The word is “his” in this case. Is this the updated version of the plugin?
Can you find the first occurrence of “his” in your text title/content.
By any chance does your title have the words “From his”?
If so, can I please ask you to navigate to:
https://github.com/WebberZone/contextual-related-posts/blob/v3.0.5/includes/class-crp-query.php#L374str_ireplace( ‘ from’, ‘’, $this->source_post->post_title )-
This reply was modified 5 years, 4 months ago by
Ajay.
Yes, this is the updated version of the plugin.
The post title DOES have the words “from his” in it!
I don’t understand what to do with the GitHub link though?
Similar to the change you did earlier in the plugin, can you edit that line and replace it with what I posted above.
Effectively, replacing the “ from” in the title as well
Just to make sure I understand, this would be a change in the plugin, but not something I’d have to do every time this happens?
That is correct. I will fix it in the next version of the plugin which I will release end of Feb.
There is one more bug that needs fixing in that release. And I want to hold off a few weeks to see if any more bugs are reported.
I’ll have this fixed in the github repo over the weekend
-
This reply was modified 5 years, 4 months ago by
The topic ‘Related Posts not displaying sometimes since update’ is closed to new replies.