By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,369 Members | 1,246 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,369 IT Pros & Developers. It's quick & easy.

i am new to python-Please somebody help

P: n/a
i dont know how to convert a txt file into a zip file

(i.e.,)i have a file named packages and i want the packages file with
a ".gz" extension by implementing a python program

Aug 2 '07 #1
Share this Question
Share on Google+
14 Replies

P: n/a
On Aug 2, 4:31 am, cool.vimalsm...@gmail.com wrote:
>
i want the packages file with
a ".gz" extension by implementing a python program
http://docs.python.org/lib/module-gzip.html

Aug 2 '07 #2

P: n/a
On Thu, 02 Aug 2007 09:31:43 +0000, cool.vimalsmail wrote:
[snip]

You would be better off actually writing a sensible subject line instead
of grovelling.

Subject: How to use gzip in Python? [beginner]

Then, having written a good subject line, it might have suggested a good
search string for Google: "gzip python"

http://www.google.com.au/search?&q=gzip+python

The first two links found will answer your question.
--
Steven.

Aug 2 '07 #3

P: n/a
On Aug 2, 8:51 am, Steven D'Aprano
<st...@REMOVE.THIS.cybersource.com.auwrote:
On Thu, 02 Aug 2007 09:31:43 +0000, cool.vimalsmail wrote:

[snip]

You would be better off actually writing a sensible subject line instead
of grovelling.

Subject: How to use gzip in Python? [beginner]

Then, having written a good subject line, it might have suggested a good
search string for Google: "gzip python"

http://www.google.com.au/search?&q=gzip+python

The first two links found will answer your question.

--
Steven.
This link answers my question --http://www.google.com/search?hl=en&q...+list+rudeness.
Honestly, I have developed in both Ruby and Python for years now and
have consistently found that the Ruby community if more newbie-
friendly than Python's. Your points are well-taken in how to properly
post and how to do your own homework. Message correct. Delivery
lacking...

Aug 2 '07 #4

P: n/a
On Aug 2, 8:51 am, Steven D'Aprano
<st...@REMOVE.THIS.cybersource.com.auwrote:
On Thu, 02 Aug 2007 09:31:43 +0000, cool.vimalsmail wrote:

[snip]

You would be better off actually writing a sensible subject line instead
of grovelling.

Subject: How to use gzip in Python? [beginner]

Then, having written a good subject line, it might have suggested a good
search string for Google: "gzip python"

http://www.google.com.au/search?&q=gzip+python

The first two links found will answer your question.

--
Steven.
<OT>
Unlike gregarican, I mostly agree with the content of your post.
Except for your subject line suggestion. Why on earth would you
recommend someone use the obnoxious "How to ______ ?" question
format? Yes, I know it's extremely common, but it's completely
nonsensical English. Just try saying it out loud with an inquiring
inflection on the last word. Sounds ridiculous doesn't it? At least
without the question mark it means that the thread is on the topic of
"How to _____".
</OT>

Aug 2 '07 #5

P: n/a

"gregarican" <gr*********@gmail.comwrote in message
news:11*********************@q3g2000prf.googlegrou ps.com...
| friendly than Python's. Your points are well-taken in how to properly
| post and how to do your own homework. Message correct. Delivery
| lacking...

Sorry, I saw nothing rude in Steven's straightforward and indeed polite
suggestion. Your post, however, ....

tjr

Aug 2 '07 #6

P: n/a
On Aug 2, 12:58 pm, "Terry Reedy" <tjre...@udel.eduwrote:
"gregarican" <greg.kuj...@gmail.comwrote in message

news:11*********************@q3g2000prf.googlegrou ps.com...
| friendly than Python's. Your points are well-taken in how to properly
| post and how to do your own homework. Message correct. Delivery
| lacking...

Sorry, I saw nothing rude in Steven's straightforward and indeed polite
suggestion. Your post, however, ....

tjr
Maybe it's just me but the word "grovelling" just doesn't ring of
newbie friendliness. To each their own I guess. Kind of like the
Smalltalk list where a few respondents are really dry. Someone will
post asking something like "Can I use Smalltalk to do X so that it
talks to Y?" One guy (without pointing to a link or offering a
snippet) just posts "Yes." I guess literally they have contributed. Or
someone calls your house and asks, "Is so-and-so there?" You just say
"Yes" and hang up on them :-)
Aug 2 '07 #7

P: n/a
On 2007-08-02, gregarican <gr*********@gmail.comwrote:
On Aug 2, 12:58 pm, "Terry Reedy" <tjre...@udel.eduwrote:
>"gregarican" <greg.kuj...@gmail.comwrote in message

news:11*********************@q3g2000prf.googlegro ups.com...
| friendly than Python's. Your points are well-taken in how to properly
| post and how to do your own homework. Message correct. Delivery
| lacking...

Sorry, I saw nothing rude in Steven's straightforward and indeed polite
suggestion. Your post, however, ....

tjr

Maybe it's just me but the word "grovelling" just doesn't ring
of newbie friendliness.
Maybe not, but it seemed to be a reasonable characterisation of
the subject line.

The only thing more valued than politeness on most programming
newsgroups is correctness.
To each their own I guess. Kind of like the Smalltalk list
where a few respondents are really dry. Someone will post
asking something like "Can I use Smalltalk to do X so that it
talks to Y?" One guy (without pointing to a link or offering a
snippet) just posts "Yes." I guess literally they have
contributed. Or someone calls your house and asks, "Is
so-and-so there?" You just say "Yes" and hang up on them :-)
Those kind of replies are posted for the fun of it, and with the
knowledge that somebody else will feel less flip at the time and
probably provide real help.

--
Neil Cerutti
The pastor will preach his farewell message, after which the choir will sing,
"Break Forth Into Joy." --Church Bulletin Blooper
Aug 2 '07 #8

P: n/a

"gregarican" <gr*********@gmail.comwrote in message
news:11**********************@i13g2000prf.googlegr oups.com...
| On Aug 2, 12:58 pm, "Terry Reedy" <tjre...@udel.eduwrote:
|| Sorry, I saw nothing rude in Steven's straightforward and indeed
polite
| suggestion. Your post, however, ....
| >
| tjr
|
| Maybe it's just me but the word "grovelling" just doesn't ring of
| newbie friendliness. To each their own I guess.

I'll give you half a point here. I have seen enough friendly, helpful
posts from Steven that I am predisposed to give a friendly interpretation,
especialy when additional helpful suggestions follow. 'Stop grovelling'
<send*would* have been rude, but that is far away from what Steven
posted.

| Kind of like the
| Smalltalk list where a few respondents are really dry. Someone will
| post asking something like "Can I use Smalltalk to do X so that it
| talks to Y?" One guy (without pointing to a link or offering a
| snippet) just posts "Yes." I guess literally they have contributed. Or
| someone calls your house and asks, "Is so-and-so there?" You just say
| "Yes" and hang up on them :-)

I'll take the half point back here ;-). "Yes <click>" is precisely what
Steven did not do, so it was *not* 'kind of like'. He followed with a
useful suggestion and example link.

tjr

Aug 2 '07 #9

P: n/a
gregarican a écrit :
(snip)
This link answers my question --http://www.google.com/search?hl=en&q...+list+rudeness.
I seriously don't think that this newsgroup can be qualified as "rude"
(and I'm possibly one of the "rudest" persons here). Compared to most
comp.* newsgroup, Python is certainly one of the most tolerant and
newbie-friendly around - and quite a lot of newcomers say so. FWIW, even
FAQs, RTFMs or STFWs are usually expressed in a mostly polite way, and
almost always with links and pointers (and FWIW, it's the case here).
Honestly, I have developed in both Ruby and Python for years now and
have consistently found that the Ruby community if more newbie-
friendly than Python's.
I spent sometimes lurking on c.l.ruby and didn't find it *that*
friendly. Not more than c.l.py at least, and certainly less respectful
of peoples coming from other languages...

Now if you want some examples of definitively "rude" newsgroups, I
suggest you take your chance on other newsgroups in the comp.*
hierarchy...
Aug 2 '07 #10

P: n/a
On Aug 2, 11:03 am, Bruno Desthuilliers
<bdesth.quelquech...@free.quelquepart.frwrote:
gregarican a écrit :
(snip)
This link answers my question -->http://www.google.com/search?hl=en&q...+list+rudeness.

I seriously don't think that this newsgroup can be qualified as "rude"
(and I'm possibly one of the "rudest" persons here). Compared to most
comp.* newsgroup, Python is certainly one of the most tolerant and
newbie-friendly around - and quite a lot of newcomers say so. FWIW, even
FAQs, RTFMs or STFWs are usually expressed in a mostly polite way, and
almost always with links and pointers (and FWIW, it's the case here).
Honestly, I have developed in both Ruby and Python for years now and
have consistently found that the Ruby community if more newbie-
friendly than Python's.

I spent sometimes lurking on c.l.ruby and didn't find it *that*
friendly. Not more than c.l.py at least, and certainly less respectful
of peoples coming from other languages...

Now if you want some examples of definitively "rude" newsgroups, I
suggest you take your chance on other newsgroups in the comp.*
hierarchy...
Good points. I guess I read a little too much into things. Apology
extended. I do recall when I was learning Python most of my questions
weren't crushed or anything. And I hear you about some of the other
comp.* lists. Browsing them awhile back I was left with my jaw open
thinking, "Oh no he diiiiiii....nt."

Aug 2 '07 #11

P: n/a

"gregarican" <greg.....il.comwrote:
Maybe it's just me but the word "grovelling" just doesn't ring of
newbie friendliness. To each their own I guess. Kind of like the
Smalltalk list where a few respondents are really dry. Someone will
post asking something like "Can I use Smalltalk to do X so that it
talks to Y?" One guy (without pointing to a link or offering a
snippet) just posts "Yes." I guess literally they have contributed. Or
someone calls your house and asks, "Is so-and-so there?" You just say
"Yes" and hang up on them :-)
Or at table - "Can you pass the salt?"

"Yes"

< a brief hiatus, laden with unfulfilled expectations and no action >

"Please pass me the salt"

"Certainly - there you are."

On the subject of "grovelling" - this refusal to tug, and to condone
tugging at forelocks, may be a Southern Hemisphere affliction.

Don't like it myself.

- Hendrik

Aug 3 '07 #12

P: n/a
"Bruno Desthuilliers" <bdes...art.frwrote:
>Now if you want some examples of definitively "rude" newsgroups, I
suggest you take your chance on other newsgroups in the comp.*
hierarchy...
I know someone who derisively refers to anybody that is associated
with computers in any way as a "Pencil Neck".

This leads me to wonder whether or not the rudeness stems from
the physically deficient's urge to kick sand in the bully's face.

- Hendrik

Aug 3 '07 #13

P: n/a
On the discussion of rudeness, we have to include the OP. He/She/it
did not even attempt a Google before posting, and posted with a
meaningless subject. We'll chalk that up to newness, but some sort of
retort was called for IMHO. How else do we learn the conventions that
govern rudeness. Personally, there is only one form of rudeness that
can not be overlooked and that is the prima donna that says "My Way Is
The Only Way", or posts some nonsense like "that is not correct" with
no other explanation. Any attempt to sincerely help, I can live with.

Aug 3 '07 #14

P: n/a
BTW - on the subject of polite discussions, how about this one as an
example of opinions politely expressed.
Oh, and does anyone know how to use zip in Python. Yes+1.

Aug 3 '07 #15

This discussion thread is closed

Replies have been disabled for this discussion.