xdg-mime default opera.desktop x-scheme-handler/http xdg-mime default opera.desktop x-scheme-handler/https
Thursday, February 14, 2013
Monday, November 22, 2010
Next big Snaked's release. It features:
Browser mode in quick open dialog.
Pygtk hint provider allows to complete attributes and signal handlers parameters based on glade file.
Regex support in search plugin. Replace is also implemented.
Doc string hint provider. One can place type hints directly in python code.
Django hint provider. Supported ORM fields, managers (objects and related sets) and query sets.
Also some minor improvements:
- Hide tab bar on <Alt>F11.
- Switch tabs on additional "standard" <Ctrl>PageUp/PageDown keys.
- Automatic character encoding detection.
- Highlight selection on <Ctrl>H.
- All search dialogs allow activate the one item by Enter key in search entry.
- Hints config format changed. Now it is ordinary python module.
- Show cursor column on <Ctrl><Alt>O
- Editor's line spacing option.
- Hints for re.RegexObject and re.MatchObject.
- Auto remove trailing space on file save.
- Disable left mouse button click in text view window.
- Rewrap text on right margin with <Alt>F.
What will be in next version?
- Multiple snippet contexts.
- Variable autocomplete in Django/Jinja templates.
- Editing capabilities improving.
You can install:
sudo pip install snaked
sudo pip install -U snaked
Thursday, November 4, 2010
Have you ever got IncompleteRead exception on trying to fetch chunked data with urllib2? I did. Look at the snippet:
import urllib2, httplib try: data = urllib2.urlopen('http://some.url/address').read() except httplib.IncompleteRead: # Ahtung! At this point you lose any fetched data except last chunk.
IRL most bad servers transmit all data, but due implementation errors they wrongly close session and urllib raise error and bury your precious bytes.
What you have to do to handle such situation?
I don't like any solutions which involve manual data reading loop, so I prefer to patch read function.
import httplib def patch_http_response_read(func): def inner(*args): try: return func(*args) except httplib.IncompleteRead, e: return e.partial return inner httplib.HTTPResponse.read = patch_http_response_read(httplib.HTTPResponse.read)
It allows you to deal with defective http servers.
Friday, October 22, 2010
- Python code navigation (goto definition and quick outline) and completion based on Rope refactoring library. Also Snaked can provide additional type information for rope static object infer system to allow you to complete every object in the project.
- Light UI without unnecessary widgets.
- Keyboard oriented control.
- Tabbed or windowed interface on your choice.
sudo pip install snaked
You can find detailed editor documentation in the folowing page: Snaked user manual
Feel free to post any issues, ideas and suggestions on Github page or in comments.