Skip to content

Local projects and communication #148

@robotasun

Description

@robotasun

Is it possible to run local projects in the Scratch app, without User/Password information or a sessionId?
I'm working with external hardware, and communication to it will be through a Python script that mustn't be tampered with, and preferably takes no inputs. It is also okay if the Scratch project receives nothing from the Python script, i.e. I just want to read some variables from Scratch.

From PyPI:
Get a Scratch cloud var from the clouddata logs:
Does not require a connection / session.

value = scratch3.get_var("project_id", "variable")
variables = scratch3.get_cloud("project_id") #Returns a dict with all cloud var values

Is project_id in this case something that is reached online, or could a local project be accessed with its own ID number?
Would such an ID number be constant?
Is it possible to sniff current project_ID values of Scratch projects running on the machine?

Finally, is it possible to run the following line with something like localhost instead?

conn = scratch3.TwCloudConnection(project_id = "project_id", username="username", cloud_host="<wss://clouddata.turbowarp.org")

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions