Sid72020123 / scratchconnect

Python Library to connect Scratch API and much more.
https://sid72020123.github.io/scratchconnect/
MIT License
26 stars 14 forks source link

Error with Cloud Variable Length Limit #22

Closed suvidhpawar closed 2 years ago

suvidhpawar commented 2 years ago

Traceback (most recent call last): File "main.py", line 15, in variables.set_cloud_variable(variable_name='sever', value=encoded_string) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/scratchconnect/CloudConnection.py", line 134, in set_cloud_variable raise ValueError( ValueError: Scratch has Cloud Variable Limit of 256 Characters per variable. Try making the value shorter!  Cloud data has a limit of up to ten (10) cloud variables per project. Cloud variables can contain only numbers (unlike regular variables, they cannot contain letters or symbols). A character limit of 256 digits per variable has also been implemented (formerly 128 digits).

Quantum-Codes commented 2 years ago

Okay.. try shortening your encoded value.. I don't think there's a problem in scratchconnect.. Correct me if I'm wrong

Sid72020123 commented 2 years ago

Traceback (most recent call last): File "main.py", line 15, in variables.set_cloud_variable(variable_name='sever', value=encoded_string) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/scratchconnect/CloudConnection.py", line 134, in set_cloud_variable raise ValueError( ValueError: Scratch has Cloud Variable Limit of 256 Characters per variable. Try making the value shorter!  Cloud data has a limit of up to ten (10) cloud variables per project. Cloud variables can contain only numbers (unlike regular variables, they cannot contain letters or symbols). A character limit of 256 digits per variable has also been implemented (formerly 128 digits).

Yes, I know that. I also added that code to warn the user if he/she sets the cloud variable with a length more than 256. I think you are setting a variable with a big value. Try making the value shorter... Regards, Siddhesh Chavan, scratchconnect, Owner

Sid72020123 commented 2 years ago

Traceback (most recent call last): File "main.py", line 15, in variables.set_cloud_variable(variable_name='sever', value=encoded_string) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/scratchconnect/CloudConnection.py", line 134, in set_cloud_variable raise ValueError( ValueError: Scratch has Cloud Variable Limit of 256 Characters per variable. Try making the value shorter!  Cloud data has a limit of up to ten (10) cloud variables per project. Cloud variables can contain only numbers (unlike regular variables, they cannot contain letters or symbols). A character limit of 256 digits per variable has also been implemented (formerly 128 digits).

I also think that you are encoding a text/etc., Make the text to 128 characters for it to work. Because a character on encoding is converted into a number with a length of 2. It's not the Library's Problem... Scratch has a limit of 256 characters per cloud variable.

Sid72020123 commented 2 years ago

I think I should rename this issue to "Error with Cloud Variable Length Limit"

Quantum-Codes commented 2 years ago

Shouldn't this be closed?

Sid72020123 commented 2 years ago

Closed!