Generate n digits of Gijswijt's sequence Introduction

Gijswijt's sequence (A090822) is famously really, REALLY slow. To illustrate:


The first 3 appears in the 9th term (alright).
The first 4 appears in the 220th term (a long way away, but feasible).
The first 5 appears at (approximately) the 10^(10^23)th term (just no).
No one really even knows where the first 6 is... it's suspected it's at the...

2^(2^(3^(4^5)))th term.


You can assume that you won't have to deal with a two-digit number.

The sequence is generated like so:


The first term is 1.
Each term after that is the amount of repeating "blocks" previous to it (if there are multiple repeating "blocks", the largest amount of repeating blocks is used).


To clarify, here are the first few terms. 

1 -&gt; 1, 1 (one repeating block (1), so the digit recorded is 1)

1, 1 -&gt; 1, 1, 2 (two repeating blocks (1), so the digit recorded is 2)

1, 1, 2 -&gt; 1, 1, 2, 1 (one repeating block (2 or 1, 1, 2), so the digit recorded is 1)

1, 1, 2, 1 -&gt; 1, 1, 2, 1, 1 (you get the idea)

1, 1, 2, 1, 1 -&gt; 1, 1, 2, 1, 1, 2

1, 1, 2, 1, 1, 2 -&gt; 1, 1, 2, 1, 1, 2, 2 (two repeating blocks (1, 1, 2), so the digit recorded is 2)

Task

Your task is, as stated in the question, to generate n digits of the Gijswijt sequence.

Instructions


The input will be an integer n.
Your code can output the digits in any form (a list, multiple outputs, etc.).


This is code golf, so shortest code in bytes wins.
Pyth, 25 22 21 bytes

t_u+eSmtfxG*Td1._GGQN


OP confirmed that we only need to handle single-digit numbers. This allowed to store the list as a string of digits. -> Saved 3 bytes

Try it online: Demonstration

Explanation:

t_u+...GQN      implicit: Q = input number
         N      start with the string G = '"'
  u     Q       do the following Q times:
    ...            generate the next number
   +   G           and prepend it to G
 _              print reversed string at the end
t               remove the first char (the '"')


And here's how I generate the next number:

eSmtfxG*Td1._G
           ._G    generate all prefixes of G
  m               map each prefix d to:
    f     1          find the first number T &gt;= 1, so that:
       *Td              d repeated T times
     xG                 occurs at the beginning of G
 S                  sort all numbers
e                   take the last one (maximum)   


21 bytes with lists

_u+eSmhhrcGd8SlGGtQ]1


Try it online: Demonstration

Uses the same ideas of Martin and Peter. At each step I split the string into pieces of length 1, pieces of length 2, ... Then I range-length-encode them and use the maximal first run as next number. 

20 bytes with strings

t_u+eSmhhrcGd8SlGGQN


Try it online: Demonstration

Combines the ideas of the two codes above.