Python/Django plugin for Dreamweaver - python

Does a plugin exists for Python/Django into Dreamweaver? Just wondering since Dreamweaver is a great web dev tool.

I remember looking for a plugin too, but came across this stumbling block:
Designers are assumed to be comfortable with HTML code. The template system isn’t designed so that templates necessarily are displayed nicely in WYSIWYG editors such as Dreamweaver. That is too severe of a limitation and wouldn’t allow the syntax to be as nice as it is. Django expects template authors are comfortable editing HTML directly.
That being said, I found a Dreamweaver extension whilst having another quick look, so give it a try and let us know how it goes! From experience, the Eclipse solution offered by Paolo works very nicely, and the Komodo plugins look great, too. I know you are looking for a graphical editor, but emacs does a very nice job ;)

As far as I know there's no Django-specific IDE plugins out there.
However I use Eclipse with PyDev for my Django/Python needs and it is quite nice.

Found one from some guy named Beshr Kayali, but I can't try it myself, since I don't have Dreamweaver.

Beshir Kayali's plugin fails installation for DW CS5 and Extension Manager CS4.
Irony that it asks for DW CS4 or better, else "upgrade" Extension manager to CS3.
I could put some effort in to make this work, yet this is the sole review of the extension:
I allows you to insert 6 kinds of template tags; if, for, template variable, block, comment, and tags. You press a button and then get a dialog box asking you for some info with maybe a few options. It doesn't actually do too much from what I can tell, definitely skippable.

Related

What are good options for debugging urwid applications?

My current makeshift approach is logging to a textfile, but that isn't very interactive. I've tried using pdb, but that doesn't seem to get along with urwid, pdb doesn't take any input once it hits a breakpoint.
A couple of practices down the line... Debugging urwid is strange and not really well possible in the classical sense, most of the time after rendering the canvas you can't really check things anymore.
What helped me:
Routing errors into a file. If you get exceptions and want to understand what, where and how, nice implementation is given here: https://stackoverflow.com/a/12877023/5058041
Really try to understand what your modules are and how you want to achieve things. Reading the documentation for the n+1-time is a good idea.
Look at the implementation of the widgets you use. Often they have some more information.
I know that doesn't really count as debugging, but it helped me a lot in finding errors or strange behavior.
One thing I've found myself doing is to add a text widget just to display debugging messages.
I haven't built many complicated apps (a solitaire game was the biggest app i wrote with it), so this approach was good enough.
In some specific cases, you might still be able to get away using PUDB -- but since it's also using Urwid, it will steal the output from the app. In practice, after you go from your app to pudb (maybe from a pudb.set_trace() breakpoint added to your code), then you won't be able to get back to your app.
For more complex applications it might be interesting to build a "debug mode", or maybe you could try using remote pudb? Haven't tried that yet, but it looks useful. =)
just in case anyone's searching for a better answer, I can report that VSCode's Python debugger debugpy is excellent for debugging urwid applications (and for debugging Python generally.) Your debugger is entirely separate from the console and doesn't interfere with drawing.

python editor/IDE that shows available functions and more importantly their documentation

f = open(filename, 'r')
strings = f.read().lower()
I want a python editor/ide that works like visual studio. In the above after typing 'f.' it shows me the list of available functions and their documentation(DO NOT WAIT FOR ctrl-space). Just like visual express C#. Also preferably it shows autocomplete lists of all variables as well. Is there such an editor?
I have gone through several suggestions - eclipse , vim , emacs , pyscripter, komodo etc etc. Tired of trying. finally asking.
Help me out.
I have checked similar questions, none answered my query.
Try to take a look at PyCharm. It not open source but it is quite cheap and powerful IDE:
http://www.jetbrains.com/pycharm/
http://www.jetbrains.com/pycharm/features/index.html
Code completion for keywords, classes,
variables, etc. — Ctrl+Space. Editor
suggestions are context-aware and
suggest most appropriate options.
Quick definition / documentation view
— see the object definition or
documentation in-place without losing
your context
You can try Netbeans. It is free. Some of its features -
It shows a list of functions and their documentations as well as variables but on Ctrl+Space. (I don't know why you don't want to hit Ctrl+Space, otherwise every time you start writing something, you will be disturbed by a popup.)
It also underlines unused variables, plus the other usual things like syntax highlighting, matching closing brackets, etc.
You can easily change the name of variables within a function/class using the refractor.
You can find usages of a particular names within your project
You can view all your classes, their methods and attributes, functions and global variables at a glance using the navigator.
It has a project manager
You can debug your project.
(whatever else you can possibly think of.)
It has lots of other features... I can't name them all here.
It is the best opensource IDE !
I can confirm that wingide code completion works like that. I tried the example you have here and it worked
I use Pydev, after Vim it speeds a lot! You can quickly navigate your project tree, in tabs you open necessary files, also inline watching of class/method definition, you can even 'jump' to that file. Also you can mark project as 'Django project', after setting python paths it really helps make less mistakes and code quickly. Also I've very much benefited multi-file search/replace. Recommend it! :)
Note: If you use Linux, replase OpenJRE with binary from Oracle's site. Otherwise there'll be craches.

NPAPI for Python - Chrome Extension

I am trying to develop a chrome extension in which i have coded all my
logic in 'python' . Now on browser action i want to pass parameters
and execute that .py file and return results to popup which will open
on browser action. To call a .py file from JavaScript i know i will
need to code a NPAPI plugin. But am confused between which approach i
should take. I have come across few options and am trying to choose
the easiest way to do it ..
Pyjamas Python Javascript Compiler : is a Python-to-Javascript
compiler which works as a language translator but on FAQ's of there
site last question suggest it will not run on Chrome. ( http://pyjs.org/)
FireBreath : FireBreath is a framework that allows easy creation of
powerful browser plugins. ( http://www.firebreath.org )
pyplugin - Python NPAPI plugin for XULRunner : It allows you to
build cross-platform graphical user interfaces using XUL and Python.
( http://pyplugin.com )
Plz Guide me to easiest way which will allow me to pass parameters and
execute that .py file and receive returned results from .py.
Thanx
Well, Pyjamas Python Javascript Compiler will not be complete -- not all python features are available in javascript, so it's impossible to convert all python to javascript. This may or may not do what you want, but I don't think it happens "on the fly", I think you have to write things on the desktop and run it through the "compiler" to get javascript out the other side.
FireBreath is the most awesomely amazing thing to ever hit the Internet -- I should know since I wrote it -- and it will absolutely allow you to do what you want, but you'll have to know how to tie into Python with C++ in order to do what you want. That said, you could probably use boost.python, which is included in the subset of boost that comes with FireBreath, but I've never used it so I don't know. You can pretty much do anything you want with an NPAPI plugin but you'll want to be real careful of security concerns.
A quick glance at pyplugin makes it look like pyplugin is basically what you'd be writing in FireBreath, but just a raw npapi plugin. If this will do what you want, it's probably the easiest way to go. It's designed to be used with XUL, which may be a problem since Chrome doesn't support XUL. You might also be able to modify it (since it's GPL) to do what you want. Of course, if you weren't planning to release your source, that could also be a problem.
The quickest way to solve your problem? Well, you'll have to decide; it'll take some more research, but I hope this is enough to at least get you started. Good luck!

Does Django need an IDE? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
My company is evaluating the possibility of developing a specialized IDE for Django.
So we would like to ask Django users:
Do you feel the need for a specialized IDE for Django?
Would you be willing to pay for it, or would you only consider free a open-source product?
What Django-specific features are you missing currently in your development tools?
I would pay a reasonable amount for a Django-tailored IDE or plug-in. I don't know what I mean by reasonable, but maye it helps to know that I would not pay more than $75, and I would only pay the $75 if the tool was really awesome.
Now, Django specific features:
Seamless integration with Google Apps
(get me the urchin, the license for
Google Maps, and put it in my
templates)
Full support for the templating engine (details in the other answers you have received)
Lorem ipsum generation (Django has it, just make it simpler)
Prepackaged modules for common tasks (e.g. give me a full login page with template an all)
Link within the code for Django documentation and examples (e.g. Django snippets)
One-click for multi-browser comparison
Full CSS support
An object explorer (along the lines of the Django-admin, but off-line)
A color palette with cool combinations (say, blue-based, orange-based)
Wizard for uploading the local project to Webfaction or similar hosting solution
If I can think of anything else I will edit the answer.
Good luck in designing your product!
I am using Komodo Edit and it's very good. There is a lot of good open-sources product so i don't think that I would buy a commercial product.
Maybe a very good and easy-to-use debugger would make me change my mind.
I hope it helps.
You'll likely want an IDE that will provide you with the ability to do source-level debugging of your accompanying Python code. Without it, your productivity will really be below what it could be.
I use Wing IDE, and I find it to be worth every penny.
I use NotePad++, and have yet to need a fully-fledged IDE specifically for Django (though I do wish NotePad++ would stop periodically crashing).
I wouldn't, unless it was really really good (and I have no idea what features it'd need to make me enthusiastic enough to pay for it).
Maybe a neater way to tie together code for a specific app within a project (models, views and template code). NotePad++'s File->Open dialog is the Windows one, which picks up the directory from the currently open file. It'd be nice if it allowed me to switch quickly between related files.
This question comes up a lot in various forms. I suspect it's because there just isn't a Python IDE which is universally accepted to be awesome.
If I could have:
some of the features of PyDev, like like real code completion, module navigation, live syntax checking and pylint
a fantastic (and fast) text editor (like eric4's scintilla-based editor)
support for django templates (maybe with gui support for wx or glade or whatever),
awesome debugging (like C# on Visual Studio)
a reasonable footprint (i.e., not Eclipse/Aptana or NetBeans)
cross platform (Mac OS X, Linux, and Windows)
sane version control support
auto doctests and unit tests
Then I'd buy it.
All of the python IDEs come close, but all miss the mark by a bit.
(Better yet, it would be open source and I'd download it and donate / contribute to it).
It's great that your company wants to contribute to the community, but I have to say that I don't see what a 'Django IDE' would achieve. There are already plugins for all the main editors and IDEs to support Django - from Vim to TextMate to NetBeans - and these provide syntax highlighting, indentation, shortcuts and snippets for both Python source and Django templates. These can always do with more work, of course, so perhaps your efforts would be best focused on improving one of these.
There are some Django aware IDEs already. PyCharm is excelent for Django development. It even allows to debug Django Templates visually.
graphic models builder to models.py :), I mean this but vice-versa.
yes I will donate.
I would definitely pay or donate for a pure Django IDE, even tho there are already some existing plugins, I feel something is always "floating".

What are some useful TextMate features? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I noticed that many people here use TextMate for coding on OS X. I've recently started using it, and although I like its minimalistic interface, it makes it harder to stumble upon cool features if you don't know what you're looking for.
So, what feature have you found most helpful for coding (mainly in Python)? Are there any third-party bundles I should know about, besides what's included?
Don't neglect the 'mate' command line tool. You can use it to pipe output into TextMate, so if you do the following...
diff file1.py file2.py | mate
...it will not only open in TextMate, but it is smart enough to know that you're looking at a diff and highlight lines on screen.
TextMate's SVN integration is great; it also seems to have bundles for some other version control systems as well.
Add GetBundle to browse the bundle repository. I found the jQuery bundle through it and it's very handy.
As others have mentioned, rolling your own bundle for frequently used snippets is very helpful. If you have some snippets that are specific to a project or framework, you might want to prefix all of them with a common letter to keep the namespace tidy.
Holding down option while dragging allows you to highlight a block of text. If you type while the highlight is active, your keystrokes appear on multiple lines.
Being able to write simple commands in any scripting language and bind them to a context-specific hotkey.
The Navigation menu commands Go to File (Command + T) and Go to Symbol (Command + Shift + T) are both extremely helpful.
Go to File, which works when you have a project open, lets you type any part of the file name to see only files that match what you've typed.
Go to Symbol has the same type-to-filter interface, but operates on what I'd call the basic block elements of your document. For example, if you're editing a class, Go to Symbol works on the method names, but in a CSS document, you'll be searching on your selectors. It's pretty awesome.
I mention some in a review on Boagworld, I find the snippets, project manager, columnar editing (hold down option while selecting stuff or push it after having selected stuff) and CSS scopes for syntax.
I like the integrated HTML/XML Tidy. Cmd-shift-H is your friend.
Also, nice integration with a variety of scp/sftp clients.
My favourite two features are auto-completion (bound to ⎋ [esc]), and column editing (bound to ⌥ [alt]) both of these things save me quite a lot of time, and are definitely 'robot ninjas'.
The book linked above is also a really useful into to the power of TextMate, although it doesn't specifically mention python.
Don't forget "Drag commands".
They give you the ability to drag, say, an image into a blog.html document and will then upload it to the proper folder and insert the markup for you.
Here is another example of how you can expand further on drag commands if you pair TM up with QuickSilver.
(Disclaimer: I wrote the blog post I linked to there. I still think it's cool though.)
It is worth noting here that there is a Windows alternative to TextMate called E Text Editor. It does pretty much everything TextMate does (apart from macros, but the author is working on this, I think), and even - shock, horror - does some things better, such as the superb bundles editor, the bundles manager, and the branching undo history. Update: and now there's Snippet Pipes.
So, not exactly a useful feature of TextMate as such, but very useful to know if you're a fan of TextMate and you have to use Windows for whatever reason.
The ease of snippet creation.
It's trivial to create new snippets that can accomplish a lot using replacements, tabbing order, and regex substitutions. Quickly assigning these to the tab key for specific languages makes me more productive. And makes me worry about code bloat. :-)
For me the best features are:
Projects - I know every IDE under
the sun has this but TextMate makes
this useful for all sorts of editing
and text processing tasks, and
moreover makes navigating around
these projects easy without ever
lifting your hands from the
keyboard. This is huge for Rails or
Grails projects or large programming
projects with many modules.
The excellent syntax highlighting
and 'snippets' for myriad languages
and tools
The excellent scripting language
support (Being able to evaluate
chunks of Ruby and the like with a
single key chord)
The built in Blogging bundle is
superb. I now use TextMate
exclusively for all my blog posts.
Columnar editing
The ability to use just about any
language or tool to extend TextMate,
Ruby, Perl, shell, name your poison.
An excellent mix of great Aqua GUI
support and excellent command line
support through the
mate and
commands, for
instance making it easy and pleasant
to use TextMate as your default
editor for your SCM.
Using snippets to expand into large, repetitive blocks of code and then using the tab key to move through and only edit the pieces I need to without having to use the mouse or arrow keys.
It's nice and lightweight and has all of the macros built-in for Ruby and let's you run Ruby code, or any other code for that matter just with a keystroke.
Check out ProjectPlus, it gives some useful options for the sidebar, it has SCM status badges for svn and git (though I find the git thing a bit buggy).
I like the fact that it can change the sidebar to an embedded panel on left or right (as opposed to the drawer that's default).
If, like me, you're borderline OCD when it comes to making code look neat, then Option+Cmd+] to line up all the assignments around the current line is awesome!
The mate command line tool is great, you can open an individual file or my favourite use of it is to open a directory of files as a project (e.g. mate .)
Checkout Zen Coding bundle . It gives you an awesome productivity boost to developing both HTML and CSS.

Categories