Failure to save image offline due to dataframe size - FileNotFoundError: [WinError 206] The filename or extension is too long

I ve just tried again on a Mac ( the above is on windows).
I find the same issue but the limit is at 9500 lines on the random dataframe


import plotly.express as px
import pandas as pd

df = pd.DataFrame(np.random.randint(0,1000,size=(10000, 9)), columns=list(‘ABCDEFGHI’))
df.head()
fig1 = px.scatter(df, x=“A”, y=“B”, size=“D”, color=“E”,
hover_name=“F”, )

fig1.update_layout(title=‘test’,width=1200,height=500)
fig1.show()

1000 lines of dataframe gives this error on Mac ( kind of similar but wording is different)

call([‘orca’, ‘graph’, json.dumps(fig1, cls=plotly.utils.PlotlyJSONEncoder), ‘-o’, ‘graph_name’,’-d’,‘images’,’-f’,‘svg’])


OSError Traceback (most recent call last)
in
----> 1 call([‘orca’, ‘graph’, json.dumps(fig1, cls=plotly.utils.PlotlyJSONEncoder), ‘-o’, ‘graph_name’,’-d’,‘images’,’-f’,‘svg’])

//anaconda3/lib/python3.7/subprocess.py in call(timeout, *popenargs, **kwargs)
321 retcode = call([“ls”, “-l”])
322 “”"
–> 323 with Popen(*popenargs, **kwargs) as p:
324 try:
325 return p.wait(timeout=timeout)

//anaconda3/lib/python3.7/subprocess.py in init(self, args, bufsize, executable, stdin, stdout, stderr, preexec_fn, close_fds, shell, cwd, env, universal_newlines, startupinfo, creationflags, restore_signals, start_new_session, pass_fds, encoding, errors, text)
773 c2pread, c2pwrite,
774 errread, errwrite,
–> 775 restore_signals, start_new_session)
776 except:
777 # Cleanup if the child failed starting.

//anaconda3/lib/python3.7/subprocess.py in _execute_child(self, args, executable, preexec_fn, close_fds, pass_fds, cwd, env, startupinfo, creationflags, shell, p2cread, p2cwrite, c2pread, c2pwrite, errread, errwrite, restore_signals, start_new_session)
1520 if errno_num == errno.ENOENT:
1521 err_msg += ': ’ + repr(err_filename)
-> 1522 raise child_exception_type(errno_num, err_msg, err_filename)
1523 raise child_exception_type(err_msg)
1524

OSError: [Errno 7] Argument list too long: ‘orca’