-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DCPError: no transports defined #332
Comments
FYI - this probably means that XHR threw an exception, so DCP wanted to move to a non-socketio transport, but we only have one transport implemented right now. We consider uncategorized exceptions like this to be fatal errors for a given connection. |
just reproed by Caleb |
I'm hitting this as well - with stack: Uncaught undefined DCPError: no transports defined
DCPError@webpack://dcp/./src/common/dcp-error.js?:22:5Connection530$$connectTransport@webpack://dcp/./src/protocol/connection.js?:828:22
async*Connection530$$connectInternal@webpack://dcp/./src/protocol/connection.js?:760:16
async*Connection530$$connect@webpack://dcp/./src/protocol/connection.js?:674:10
Connection530$$send@webpack://dcp/./src/protocol/connection.js?:1189:15
Connection530$$request@webpack://dcp/./src/protocol/connection.js?:1233:15
provisionSubscriptionTokens@webpack://dcp/./src/events/event-subscriber.js?:227:48
subscribeManyEvents@webpack://dcp/./src/events/event-subscriber.js?:307:18
subscribeCustomEvents@webpack://dcp/./src/dcp-client/job/index.js?:1228:34
addInitialEvents@webpack://dcp/./src/dcp-client/job/index.js?:1189:18
async*exec@webpack://dcp/./src/dcp-client/job/index.js?:954:39
timestamp: 2024-07-01T21:45:41.886Z,
code: 'DCPC-1014',
process: 'z-pure-pm-joe' undefined
Uncaught undefined DCPError: no transports defined
DCPError@webpack://dcp/./src/common/dcp-error.js?:22:5Connection530$$connectTransport@webpack://dcp/./src/protocol/connection.js?:828:22
async*Connection530$$connectInternal@webpack://dcp/./src/protocol/connection.js?:760:16
async*Connection530$$connect@webpack://dcp/./src/protocol/connection.js?:674:10
Connection530$$send@webpack://dcp/./src/protocol/connection.js?:1189:15
Connection530$$request@webpack://dcp/./src/protocol/connection.js?:1233:15
provisionSubscriptionTokens@webpack://dcp/./src/events/event-subscriber.js?:227:48
subscribeManyEvents@webpack://dcp/./src/events/event-subscriber.js?:307:18
subscribeCustomEvents@webpack://dcp/./src/dcp-client/job/index.js?:1228:34
addInitialEvents@webpack://dcp/./src/dcp-client/job/index.js?:1189:18
async*exec@webpack://dcp/./src/dcp-client/job/index.js?:954:39
timestamp: 2024-07-01T21:45:49.390Z,
code: 'DCPC-1014',
process: 'z-pure-pm-joe' undefined undefined Error: xhr poll error
TransportError@webpack://dcp/./node_modules/@kingsds/engine.io-client/build/cjs/transport.js?:14:9
onError@webpack://dcp/./node_modules/@kingsds/engine.io-client/build/cjs/transport.js?:46:37
doPoll/<@webpack://dcp/./node_modules/@kingsds/engine.io-client/build/cjs/transports/polling.js?:255:18
Emitter.prototype.emit@webpack://dcp/./node_modules/@socket.io/component-emitter/index.mjs?:140:20
onError@webpack://dcp/./node_modules/@kingsds/engine.io-client/build/cjs/transports/polling.js?:356:14
create/xhr.onreadystatechange/<@webpack://dcp/./node_modules/@kingsds/engine.io-client/build/cjs/transports/polling.js?:329:30
description: 0,
context:
XMLHttpRequest {
onloadstart: undefined,
onprogress: undefined,
onabort: undefined,
onerror: undefined,
onload: undefined,
ontimeout: undefined,
onloadend: undefined,
onreadystatechange: [Function],
UNSENT: 0,
OPENED: 1,
HEADERS_RECEIVED: 2,
LOADING: 3,
DONE: 4,
timeout: 0 },
type: 'TransportError',
transport: 'socketio',
httpStatus: 0,
httpHeaders: {},
__statusTextCode: undefined undefined from the following repro: #!/usr/bin/env python3
import pythonmonkey as pm
import asyncio
#relative path - but fwiw, I'm on develop dcp-client & dcp as of 2024-07-01
dcpClient = pm.require('./dcp/js/node_modules/dcp-client')
dcpClient['init']()
async def compute_for_it():
pm.eval('''
globalThis.myJob = dcp.compute.for([1,2,3,4,5,6,7,8,9,10], (x) => { progress(); return x + x })
''')
asyncio.run(compute_for_it())
my_j = pm.eval("globalThis.myJob")
my_j.on('readystatechange', print)
my_j.on('accepted', lambda: print(my_j.id))
my_j.on('result', print)
my_j.public.name = 'simple example'
async def exec_it():
return await my_j.exec()
res = asyncio.run(exec_it())
print(pm.eval('Array.from')(res)) |
Still getting this issue |
See private KDS Slack thread about my reporting of this bug and it being frequent. |
I just saw a new manifestation of this error while running in a public library, with a high-repro rate: Uncaught undefined DCPError: no transports defined |
Issue type
Bug
How did you install PythonMonkey?
None
OS platform and distribution
No response
Python version (
python --version
)No response
PythonMonkey version (
pip show pythonmonkey
)No response
Bug Description
sometimes get
Warning: keepalive failed for compute groups service DCPError: no transports defined
DCPError@webpack://dcp/./src/common/dcp-error.js?:22:5Connection530$$connectTransport@webpack://dcp/./src/protocol/connection.js?:825:22
asyncConnection530$$connectInternal@webpack://dcp/./src/protocol/connection.js?:757:16
asyncConnection530$$connect@webpack://dcp/./src/protocol/connection.js?:667:10
Connection530$$send@webpack://dcp/./src/protocol/connection.js?:1170:15
DcpMessage$$send@webpack://dcp/./src/protocol/dcp-message.js?:58:26
Connection530$$keepalive@webpack://dcp/./src/protocol/connection.js?:1225:18
keepAlive@webpack://dcp/./src/dcp-client/compute-groups/index.js?:65:36
addJobToGroups@webpack://dcp/./src/dcp-client/compute-groups/index.js?:458:17
joinComputeGroups@webpack://dcp/./src/dcp-client/job/index.js?:1304:47
exec@webpack://dcp/./src/dcp-client/job/index.js?:999:43
sendPromiseRejectWrapper@webpack://dcp/./src/protocol/connection.js?:1135:32
DialogueRegistry$$clear@webpack://dcp/./src/protocol/dialogue-registry.js?:173:24
finalize@webpack://dcp/./src/protocol/connection.js?:491:29
Connection530$$shutdown/<@webpack://dcp/./src/protocol/connection.js?:460:9
Connection530$$a$enqueue@webpack://dcp/./src/protocol/connection.js?:1118:27
Connection530$$send@webpack://dcp/./src/protocol/connection.js?:1182:36
DcpMessage$$send@webpack://dcp/./src/protocol/dcp-message.js?:58:26
Connection530$$keepalive@webpack://dcp/./src/protocol/connection.js?:1225:18
keepAlive@webpack://dcp/./src/dcp-client/compute-groups/index.js?:65:36
addJobToGroups@webpack://dcp/./src/dcp-client/compute-groups/index.js?:458:17
joinComputeGroups@webpack://dcp/./src/dcp-client/job/index.js?:1304:47
exec@webpack://dcp/./src/dcp-client/job/index.js?:999:43
code: 'DCPC-1014', message: 'no transports defined'
Standalone code to reproduce the issue
No response
Relevant log output or backtrace
No response
Additional info if applicable
No response
What branch of PythonMonkey were you developing on? (If applicable)
No response
The text was updated successfully, but these errors were encountered: