473,395 Members | 1,948 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

fcntl and FCNTL

I followed discussion in the group about this problem:

ImportError: No module named fcntl

I found out there are two modules:
FCNTL
fcntl
the first one is obsolete and shouldn't be used.
But the second one is usable.

Unfortunately, there is no fcntl in my python installation (Python
2.3.3, I got it from python site for Windows). There is FCNTL.py which
is just a warning message and some imports.

Am I missing some files here. How could I have access to fcntl module.

Any help?

Thank you in advance.
Regards;
Jul 18 '05 #1
4 18276
Omid Fatemi wrote:
I followed discussion in the group about this problem:

ImportError: No module named fcntl

I found out there are two modules:
FCNTL
fcntl
the first one is obsolete and shouldn't be used.
But the second one is usable.

Unfortunately, there is no fcntl in my python installation (Python
2.3.3, I got it from python site for Windows). There is FCNTL.py which
is just a warning message and some imports.

Am I missing some files here. How could I have access to fcntl module.


From the docs in http://docs.python.org/lib/module-fcntl.html

"""Availability: Unix."""

I don't know if there's an alternative. Presumably the archives
for the list would answer this clearly, since as you say others
have asked the question before.

-Peter
Jul 18 '05 #2
Dear Peter;
thank you for your response.
Does this mean that in Windows I can't use fcntl module.
If yes, what functions do you suggest to use instead of fcntl funtions.

I could see the funtions in posixfile are using fcntl functions.
Do you have any alternative for posixfile module?

Regards;

Peter Hansen <pe***@engcorp.com> wrote in message news:<w4********************@powergate.ca>...
Omid Fatemi wrote:
I followed discussion in the group about this problem:

ImportError: No module named fcntl

I found out there are two modules:
FCNTL
fcntl
the first one is obsolete and shouldn't be used.
But the second one is usable.

Unfortunately, there is no fcntl in my python installation (Python
2.3.3, I got it from python site for Windows). There is FCNTL.py which
is just a warning message and some imports.

Am I missing some files here. How could I have access to fcntl module.


From the docs in http://docs.python.org/lib/module-fcntl.html

"""Availability: Unix."""

I don't know if there's an alternative. Presumably the archives
for the list would answer this clearly, since as you say others
have asked the question before.

-Peter

Jul 18 '05 #3
> Does this mean that in Windows I can't use fcntl module.
If yes, what functions do you suggest to use instead of fcntl funtions.
I could see the funtions in posixfile are using fcntl functions.
Do you have any alternative for posixfile module?


I don't use windows, so I can't help here - but what might give the
windows-gurus out there a hint how to help you would be to say what you
actually want to achieve - then they might know how to do that with
windows.
--
Regards,

Diez B. Roggisch
Jul 18 '05 #4
Omid Fatemi wrote:
Dear Peter;
thank you for your response.
Does this mean that in Windows I can't use fcntl module.
If yes, what functions do you suggest to use instead of fcntl funtions.
What are you using for documentation? In my "Global Module Index" it
says (in the module list):
....
fcntl (Unix)
....
posixfile (Unix)
.... I could see the funtions in posixfile are using fcntl functions.
Do you have any alternative for posixfile module?

I think you can take this as an indication without reading the source
that the Python modules are tied pretty closely to the Unix
functionality they provide, and therefore won;t be available on Windows
any time soon.

regards
Steve
--
http://www.holdenweb.com
http://pydish.holdenweb.com
Holden Web LLC +1 800 494 3119
Jul 18 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Meyer, Tony | last post by:
(I did try to google for an answer to this, but couldn't find anything, although plenty of instances of the warning). I don't understand this warning: >>> import fcntl C:\Program...
6
by: Pierre Rouleau | last post by:
Hi all! I am using Python 2.3.1 on Win32 (NT, 2000). Whenever a file imports the standard tempfile module, Python 2.3.1 issues the following warning: C:\Python23\lib\fcntl.py:7:...
0
by: Ryan Grow | last post by:
Hi, I'm trying to use fcntl to set an existing file descriptor to be nonblocking. This contrived example exhibits the behavior of python that is preventing me from doing this: import os,...
11
by: Chris Green | last post by:
Hey folks, Is there anyway for a signal handler in python to get the information from a 3 argument signal handler rather than just the signal number and stack frame? I've got an application...
3
by: thakadu | last post by:
The following code works as expected when run in the main body of a python script (ver 2.3.5) on OpenBSD v3.8. but when it is in the body of a function definition it does not work. It does not...
5
by: marcello | last post by:
Hello I need to do this: 1 opening a file for writing/appending 2 to lock the file as for writing (i mean: the program that lock can keep writing, all others programs can't ) 3 wtite and...
0
by: Mitko Haralanov | last post by:
I am trying to use the advisory locking with fcntl over NFS (thus, me choosing fcntl instead of flock and friends). I have the following code: lockdata = struct.pack ("hhllhh", fcntl.F_RDLCK, 0,...
9
by: mhearne808[insert-at-sign-here]gmail[insert-dot-he | last post by:
I'm having a number of problems with the fcntl module. First off, my system info: Mac OS X Darwin igskcicglthearn.cr.usgs.gov 8.10.1 Darwin Kernel Version 8.10.1: Wed May 23 16:33:00 PDT 2007;...
2
by: xucs007 | last post by:
I ran following 2 programs (lock1, lock2) at almost same time, to write either "123456", or "222" to file "aaa" at the same time. But I often just got "222456" in "aaa" . Is this a bug of python...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.