Let me assume that you are going to be on the working holiday visa for a year (July 2014 to July 2015).
For the UK side of things, as what you have described, you may not likely be deemed as non-resident, as you may not have meet the general criteria under the statutory resident test (SRT).
As a guideline, you will be non-resident if:
- you did not spend more than 45 days in the UK and were not resident
in the UK in any of the three previous tax years, or
- you did not spend more than 15 days in the UK and were resident in
the UK in one or more of the three previous tax years, or
- you are working full-time overseas and;
- you spend fewer than 91 days in the UK, and
- you do not work in the UK for three hours or more on more than 30 days.
and the guidelines pertain to the corresponding tax year (6 April - 7 April).
You need to check out the HMRC RDR3 Guidance or use this online tool to check your UK residency status.
You may be able to benefit from split year treatment, where you are taxed as a non-resident (see preceding paragraph) for the period you are working overseas and as a UK resident for the period you are in UK (i.e. Mar - July 2014). Again, check out HRMC RDR3 to check if you qualify.
If you don't qualify for split year treatment, your overseas income (i.e. Japanese income) will be taxed by HMRC as though it was derived from the UK. However, there is a double taxation agreement signed between Japan and UK, which prevents such taxation from occurring.
Hence, if your status with the HMRC is either non-resident or split year treatment, the problem you have stated would not occur, as you would be paying Japanese tax only (for work done in Japan).
If you are subjected to UK tax on overseas income (i.e. accorded resident status), you should pay Japanese tax as per normal for non-UK work. Once it's time to file the UK tax returns, you should claim a Foreign Tax Credit Relief for the income that was taxed under Japanese tax rules (i.e. income from work in Japan), so as to avoid double taxation. However, income for work in the UK (even remote work) will be subjected to UK tax, irregardless of residency status. I don't know if Japan tax rules would tax non-Japanese derived sources.
tldr: Japanese income should be paid to the National Tax Agency (Japan) and UK income to the HMRC. If your UK tax status is such that you have to pay tax on overseas income, claim a Foreign Tax Credit Relief as there is a DTC between Japan and UK.
N.B. Income denotes remuneration paid for work in that particular country.