From: "Antanas Ursulis" <antanas.ursulis@gmail.com>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/log-analysis:master commit in: /
Date: Mon, 29 Jul 2013 16:08:24 +0000 (UTC) [thread overview]
Message-ID: <1374098599.5640153330f6ff8935009f1570563c48a088aef5.uranium@gentoo> (raw)
commit: 5640153330f6ff8935009f1570563c48a088aef5
Author: Antanas Uršulis <antanas.ursulis <AT> gmail <DOT> com>
AuthorDate: Wed Jul 17 22:03:19 2013 +0000
Commit: Antanas Ursulis <antanas.ursulis <AT> gmail <DOT> com>
CommitDate: Wed Jul 17 22:03:19 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/log-analysis.git;a=commit;h=56401533
Send only filename, not full path
---
simple_client.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/simple_client.py b/simple_client.py
index 0335260..3abc7c9 100644
--- a/simple_client.py
+++ b/simple_client.py
@@ -2,14 +2,14 @@
Simple submission client that forms a correct protobuf message and performs a POST
"""
-import submission_pb2, sys, urllib
+import submission_pb2, sys, urllib, os
def send_submission(filenames):
submission = submission_pb2.Submission()
for f in filenames:
new_file = submission.files.add()
- new_file.filename = f
+ new_file.filename = os.path.basename(f)
new_file.data = open(f, 'rb').read()
print urllib.urlopen('http://[::1]:5000/submit', submission.SerializeToString()).read()
next reply other threads:[~2013-07-29 16:08 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-29 16:08 Antanas Ursulis [this message]
-- strict thread matches above, loose matches on Subject: below --
2013-07-29 22:40 [gentoo-commits] proj/log-analysis:master commit in: / Antanas Ursulis
2013-07-29 22:40 Antanas Ursulis
2013-07-29 22:40 Antanas Ursulis
2013-07-29 18:59 Antanas Ursulis
2013-07-29 16:08 Antanas Ursulis
2013-07-29 16:08 Antanas Ursulis
2013-07-29 16:08 Antanas Ursulis
2013-07-05 0:00 Antanas Ursulis
2013-07-05 0:00 Antanas Ursulis
2013-07-04 1:39 Antanas Ursulis
2013-07-03 7:15 Antanas Ursulis
2013-07-03 7:15 Antanas Ursulis
2013-07-03 7:15 Antanas Ursulis
2013-07-03 7:15 Antanas Ursulis
2013-07-03 7:15 Antanas Ursulis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1374098599.5640153330f6ff8935009f1570563c48a088aef5.uranium@gentoo \
--to=antanas.ursulis@gmail.com \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox