https://www.growthbook.io/ logo
#ask-questions
Title
# ask-questions
l

little-postman-16709

01/15/2024, 9:56 AM
Hi. I have a question. I want to setup an experiment, where, based on a criteria the user will have a chance to see the new feature. So basically i need to set the user attributes later on. However, when i do it and and attempt to show the feature i see the "Skip because missing hashAttribute" error, even though i have the user attributes set. Is there anything else i need to do in order to make it work?
f

fresh-football-47124

01/15/2024, 9:57 AM
What attribute are you using for assignment in the experiment?
l

little-postman-16709

01/15/2024, 9:58 AM
I am setting them inside a useEffect
Copy code
useEffect(() => {
		if (!growthbook && !uid) return;

		growthbook
			?.setAttributes({
				uid,
			})
			.then(() => {
				console.log('uid set', uid);
			});
	}, [growthbook, uid]);
With this question you just gave me the answer. I was setting a wrong attribute 🙈. It was waiting for 'id', and i named it 'uid'. silly mistake
f

fresh-football-47124

01/15/2024, 10:16 AM
cool, glad its sorted
🙌 1
4 Views