Design a function in Python to generate Fibonacci numbers from 1 to a given range.
10
def fibonacci(x):
 fib_numbers = [1,1]
 for i in range(2,x):
  fib_numbers.append(fib_numbers[i-1] + fib_numbers[i-2])
 return fib_numbers