https://prefect.io logo
Title
c

Charles Leung

12/17/2020, 8:28 PM
Hey guys, I'm getting an error when trying to call flow.register on a windows environment; using a basic flow as a test:
Result check: OK
---------------------------------------------------------------------------
ClientError                               Traceback (most recent call last)
<ipython-input-11-014533001643> in <module>()
----> 1 flow.register(project_name='test-charles')

C:\ProgramData\Anaconda3\lib\site-packages\prefect\core\flow.py in register(self, project_name, build, labels, set_schedule_active, version_group_id, no_url, idempotency_key, **kwargs)
   1667             version_group_id=version_group_id,
   1668             no_url=no_url,
-> 1669             idempotency_key=idempotency_key,
   1670         )
   1671         return registered_flow

C:\ProgramData\Anaconda3\lib\site-packages\prefect\client\client.py in register(self, flow, project_name, build, set_schedule_active, version_group_id, compressed, no_url, idempotency_key)
    821             create_mutation,
    822             variables=dict(input=inputs),
--> 823             retry_on_api_error=False,
    824         )  # type: Any
    825 

C:\ProgramData\Anaconda3\lib\site-packages\prefect\client\client.py in graphql(self, query, raise_on_error, headers, variables, token, retry_on_api_error)
    316             ):
    317                 raise VersionLockError(result["errors"])
--> 318             raise ClientError(result["errors"])
    319         else:
    320             return GraphQLResult(result)  # type: ignore

ClientError: [{'message': "'NoneType' object has no attribute 'get'", 'locations': [{'line': 2, 'column': 5}], 'path': ['create_flow_from_compressed_string'], 'extensions': {'code': 'INTERNAL_SERVER_ERROR', 'exception': {'message': "'NoneType' object has no attribute 'get'"}}}]
What's this error message mean? Using the latest version of prefect for python. Thanks,
d

Dylan

12/17/2020, 8:30 PM
Hi @Charles Leung, This looks potentially like a Prefect version mismatch between the version of the Flow and the version of your Prefect Server instance. Is the version of your Prefect Server instance > Flow’s Prefect version?
c

Charles Leung

12/17/2020, 8:37 PM
Ah, i see. Thanks Dylan i'll try downgrading my prefect!
d

Dylan

12/17/2020, 8:39 PM
Anytime!
c

Charles Leung

12/17/2020, 8:39 PM
fixed it right away 🙂 thanks!
d

Dylan

12/17/2020, 8:39 PM
Glad I could help!