Comments (8)
You are correct in your assessment. That status code looks like it can be handled in a more user-friendly manner.
But I'm interested to learn what can lead to this status code. After all, it does not appear to a common scenario when the remote service will simply delete the user session. If an incorrect UID is sent, then there could be a bug lurking somewhere in the code.
from pysmb.
well, I don't really know. I found this error in our newly installed Sentry. I can't tell yet how frequently this happens. I'll remember to update here if it is the case.
My best guess is that it could be a restart of the service.
from pysmb.
This error occurred again today. Unfortunately, I cannot reproduce it consistently and can't figure out why it occurs
from pysmb.
it happened again today
from pysmb.
@thomasleveil : Can you provide a few details about your task?
- Are you using one pysmb session to perform multiple file uploads/downloads?
- Does the error occur on the first file upload/download? If it happens like after a dozen operations, I suspect there could be some form of connection throttling.
- If possible, can you log some info of each file operation in terms of file size and duration of each upload/download? When the error occurs next time, is there any abnormal trends in that current upload/download operation? For instance, larger file size, prolonged duration, etc.
from pysmb.
Thanks @miketeo for the attention. Next time it happens I'll will take a closer look at operations the code is trying to run.
Would you recommend opening a new connection for each individual operation ?
from pysmb.
@miketeo, I've got another occurrence this morning. Looking at the code, we can have up to 5 calls triggered at the same time, in different threads.
Each call will :
- connect & auth to smb
- for path in [<list of 4 dir paths>]: recursive call to conn.listPath(...)
One of the calls is failing at connection time
from pysmb.
I suspect that you might be opening "too many" connections at one time. I had similar occurrences when I run the full regression test suites against a Windows 10 workstation.
I'm assuming each pysmb connection is running in its own thread.
A possible workaround could be to catch the exception and introduce a couple of seconds delay before reconnecting again in your step 1.
from pysmb.
Related Issues (20)
- Cant connect w/ smb on mac os, python 3.8 HOT 6
- Can't get file list on DFS shared folder HOT 6
- listPath fails with "STATUS_ACCESS_DENIED" due to too broad access mask HOT 2
- pysmb-provided MD4 implementation for Python3 is broken HOT 6
- ThreadPoolExecutor storeFile HOT 1
- Using same code in Windows and Linux to access remote paths HOT 2
- Problem performing listPath using SMB1 with version 1.2.8 (similar to issue #195)
- Server does not support any of the pysmb dialects HOT 2
- When are compressed transfers supported?
- Unable to install the latest version of pysmb(1.2.9) HOT 7
- TypeError: can't concat str to bytes HOT 2
- How to improve transfer speed
- Server does not support any of the pysmb dialects. Please email pysmb to add in support for your OS HOT 1
- Copy a file using pysmb from windows to linux HOT 8
- Don't connect to SMBv2 server HOT 5
- Provide wheel distributions
- Using Chunk? HOT 5
- Request to Update Documentation for SMBConnection Class HOT 4
- storeFile raise SMBTimeout exception on files > 1k HOT 2
- Compatibility Issue with Unraid SMB Server: Unable to Negotiate Supported SMB Dialect
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pysmb.