Library generation bug