Sauté onions in butter until translucent. Stir in flour and cook, stirring, until flour browns. Measure liquor from oysters and add enough fish stock or clam juice to total four cups. Whisk stock and oyster liquor mixture into onions and cook for 10 minutes, stirring frequently. Add rice and cook for 20 minutes, or until almost tender. Fold in oysters and cook with rice. This should be no more than 10 minutes before serving, or oysters will be overcooked. Season with salt and pepper. Serve immediately.