Anytime you cannot prove on entry that your intention is to stay in Canada only temporarily, you risk being refused entry. When you have a PR application in process, your clear intention is to stay permanently - and they can refuse you, if they want to, simply on that basis. While an inland applicant is required to be in Canada, living with their sponsor, in order to be approved for PR - having an inland PR ap in process does not guarantee you'll be allowed to re-enter Canada if you leave. So if you leave and you can't get back in, you no longer meet the residence requirement of an inland applicant and, because the entire process (including landing) happens within Canada, you can't finalize your ap. That said, you can apply via the outland process, even while you're in Canada, but again - if you leave Canada during processing (and you'd have to if you were required to attend an interview because it would be held at the overseas visa office) you might not get back into Canada afterwards. The difference is that where you're living/staying has no impact on the outland process - an outland ap would continue to process whether you were in Canada or not.
Best option for helping to ensure that you can get into Canada when you have a PR ap in process: have your sponsor accompany you on re-entry and prove 1) that you have a qualifying relationship, 2) that the sponsor has financial means to support you, and 3) that you have had valid status during all previous stays in Canada and that you have applied, when necessary, to extend that status so that it's maintained. That said, if you're going to have to jump through all those hoops anyway - whether you apply inland or outland - it's probably best to apply outland and get the processing completed faster, so you get your PR visa and can get on with life sooner rather than later. The other drawback to the inland process is that there are no appeal rights so, if for some reason the ap was refused, you'd have to leave Canada - and you'd be applying for PR all over again (if you could overcome the reason for refusal) via the outland process anyway. Might as well do it that way to start.