Python development environments like Smalltalk [closed] - python

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I like programming in the Python language to solve daily problems in system administration contexts, and I am happy with that.
I am learning Pharo Smalltalk and am fascinated by the different approach of this language in object programming.
I like very much the idea of the Smalltalk virtual machine and the system image concept which holds the environment all in one file.
Does anything similar exist in Python?

If you have enough time :) you could of course use Glamour and Petitparser to build a Python development environment in Pharo.

AFAIK, no. There isn't anything like a Smalltalk image for Python.

Actually there is nothing like smalltalk in any other kind of language. The only thing ever to get close was and still is Delphi and its open source brother Free Pascal + Lazarus but still because it tried to keep ties with C/C++ its very different as a language and environment. I love python as a language and because is extremely popular, easy, simple etc. But as soon as you leave language and libraries territory you are alone. And that pretty much convinced me that the smalltalk environment is what I wanted the most.
The only thing approaching the elegance , ease of use and power of smalltalk environment is emacs. I won't mention vim here not because is an inferior editor and certainly not because is any less extendable.Vim is awesome. But emacs like smalltalk IDE are built on top of their own languages. For smalltalk IDE its smalltalk for emacs its elisp which accounts for more than 90% of its code based , compared to VIM that depends 50% on C source code.
What emacs lack in GUIs , it gains in documentation. Emacs also has a simple architecture , everything is not an object like smalltalk but is a function and elisp even has lisp macros for you to create your own syntax. For me emacs is another great , amazing environment to work into. Emacs has pymacs which allows you to script emacs with python and gain full access to all emacs libraries but elisp is not only faster but way more elegant than python as a programming language.

Let's take BlueBook and write SmallPython ourself ?
http://www.mirandabanda.org/bluebook/
http://stephane.ducasse.free.fr/FreeBooks/BlueBook/Bluebook.pdf

Related

How to quit Jupyter and become a better programmer? [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
I am a self-taught programmer coming from a scientific (non-programming) background. I discovered Jupyter early after I started using Python. And although I greatly enjoy using it (Jupyter), I feel that it somewhat hindered my ability to think ahead and write code that will be easy to maintain and interact with in the future.
I inevitably end up with these endless notebooks that are impossible to navigate and mostly consist of redundant code. I then tuck away some of the functions into text files. Make a copy of the notebook, delete a bunch of cells, and start over. Until the notebook becomes unmanageable again, then semi-refactor, make a copy, prune cells, and so on.
I feel that at this point I should learn some basic software design principles and practices (like version control and code organization). Is there a course or a lecture series you can recommend that might help me with that? I feel that any advice from you will be helpful. Thanks!
This will help in learning version control from official Git Documentation
This will also help in Software development philosophies from wikipedia
Try sublime text editor. It is not an IDE but it is really good for coding and has a bunch of useful coding plugins. It is not free but has an unlimited free trial, in which you get all the features, and an occasional popup asking you to buy it. If you download it, you should also use some plugins to help you code python
I personally use these plugins:
Origami, Terminus, Kite & Anaconda
I f you don't like sublime or using a plain text editor, check out visual studio code, idle or thonny.
They are full IDEs (not code editors), and will thus have more features.
IDLE & thonny are beginner's IDEs and Visual Studio Code is a lot more powerful & complex
Now you have your Jupyter notebook replacement on to the version control
Instead of using git, use github. It is built on top of git, and is a lot easier.
If you don't already have a github account then create one. Now you have a version control system going. I am not going to go any deeper because i am not very good at github version control so check out this site

Use of the Python Language [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 11 years ago.
I have been studying Python at work for a week now and it seems very interesting, I started using it in order to create Extra Search functions for Splunk.
My Question is, what else can you do with it?, is it only a Script Language?, if so what type of scripts can I create and use?
To what extent should I learn Python in order to begin writing usable scripts?
I can write a Shell Korn script to Query a MySql Database, Can I do the same with Python?
You can pretty much do anything with Python that you can do with ksh, only easier (shells have a lot of stuff built in but many scripts will "reach out" to helpers like grep, sed awk, and so forth, to do grunt work).
Python also comes with an insanely large library (just like Java and C#) and plenty of add-on modules, both of which also include database stuff.
You don't have to learn Python to be able to script successfully, there's a large array of solutions for this. But Python is a useful weapon to have in your arsenal.
Bottom, it's quite able to handle a huge number of tasks, including the specific one you mentioned.
Aloha!
The obnoxious answer is that Python like other languages are turing complete and you can write program in it. But that probably doesn't answer your question. ;-)
First however, a tip: Stop think in terms of scripting vs real programming languages. Python, just like Java, Perl, Ruby, LISP, Scala, Lua, Cloujure are just as much real programming languages as C, C++, Fortran etc. The main difference is what they are running on. C for example can run on "bare metal", that is basically be translated to sequences of instructions that can be executed by the native/real CPU. Python, Java etc relies on a virtual machine to execute their instructions. The VM is then run by the real CPU.
The VM costs some performance, but add things like portability, dynamic behaviour (introspection, duck typing etc) that make the language and systems written in it very efficent in ways it is harder to do (but not impossible - remember Turing completeness) in for example C.
With that in min (Python is a real programming language) you might not be surprised to learn that Python can be and is used for things like:
Network servers and network applications. Look at the great Twisted networking framework and look and beautiful applications like Trac.
Large scale, professional distributed version control. Mercurial (Hg) is written entirely in Python and is able to handle huge, active projects with developers on a global level.
Compilers, languages and virtual machines. There is actually a virtual machine able to run Python written in Python(!). The machine called Pypy use some of the dynamic functionality of the language to enhance the performance.
Pypy is really a groovy concept - having the machine you are running your code in a language that can be modified at runtime - basically rebuilding the "hardware" from your application to enhance the machine to at the whim of the application. (And yes, I'm aware that all LISP guys yawn at this point - nothing new but still very, very groovy)
There you have it, some IMHO good, everything but simplistic, non-professional applications. Now start reading up on Python.org about the advanced features of the language and amazing functionality readily available in the standard lib. Your programming life will thank you for it.
Good luck!
To answer your questions in order:
Everything.
No.
Any.
As much as possible.
Yes.
Start here

Scripting Languages [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 9 years ago.
Improve this question
I am looking for a good scripting language to link to my program.
I am looking for 2 important attributes:
Scripting language should be hard linked into the executable (not requiring 3rd party
installations). This is important to me to simplify distribution.
Scripting should allow some run-time debugging option (When running a script inside my program I would like to easily run it inside a debugger while it is running in the context of my program)
Can python,lua or some other language supply me with this?
Both Lua and Python can provide the features you mention, so choosing one of them will depend on other criteria.
Lua is a lighter weight solution, it will have a much smaller disk footprint and likely a smaller memory overhead than Python too. For some uses it may be faster. Python has a much richer standard library, more mature third party libraries and a more expressive language.
Both have been embedded into major applications. Python can be found in Blender, OpenOffice and Civilization 4. Lua can be found in World of Warcraft and Adobe Lightroom. I'd recommend looking at a few tutorials for each and the facilities available to embed them in your application and just choose the one that fits your brain best.
Lua is designed for this:
static linking? check!
debugging? check!
Typically, Lua is the better choice for embedding into another project. Python is better as a standalone platform because the library support is so much broader. See Lua Versus Python for more details.
Personally, I use both very frequently depending on the job at hand. I always use Lua for embedding into C/C++ applications or scripting functionality that is imported from C/C++ shared libraries (i.e. a DLL). Python is always my first choice for standalone tasks that do not require low-level C/C++ code.
I'd put my two cents in for python. I don't know a lot of the details, but the computer graphics suite blender does a wonderful job of implementing python scripting.
As far as I can tell in blender 2.5 the interpreter is run from inside the executable,
import sys
sys.executable
shows /blender/blender.exe
and there is good debugging support, it even has a full interactive interpreter inside.
For more info check out: http://www.blender.org/
I really like Lua for embedding, but just as another alternative, JavaScript is easily embeddable in C, C++ (SpiderMonkey and V8) and Java (Rhino) programs.
In addition to Tcl, Lua, and Javascript (all already mentioned), Guile is another language designed explicitly for this.
I'll add Tcl to the mix. It's designed to be easily embedded into other programs.

Looking for a Python IDE with good support for libraries (Twisted) [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
I'm looking for a Python IDE that can help me easily locate and manage and use the libraries on my system (Ubuntu). Specifically Twisted.
Code completion is important including the symbols I import.
(I've so far had a look at PyDev as well as OpenKomodo, but while both offer code completion for default Python concepts, I wasn't able to get either to import Twisted into my project and was thus getting reference errors.)
Usual disclaimer: I don't like EMACS or vi, please, nothing regarding those.
Using Wing IDE with Twisted discusses how to debug twisted using their IDE - although unfortunately WingWare is not free.
Are you sure you have given PyDev a fair look? It seems to be the most popular Python IDE, and I have always had good experiences with it in the past.
I've just downloaded the preview of netbeans and it seems to have done quite well so far.
It has detected inherited methods & properties. I haven't had to add a single library reference in my project, so this seems to be the most fluid so far.
eclipse + pydev seems to work well for me.
Just remember to right-click on the project and select Properties and make sure that your libraries are on the path. Sometimes this doesn't happen for easy_installed libraries.
Check out JetBrains PyCharm. It features:
Code completion of any imported library
Good support for unit testing
Refactoring
Debugging
Version control integration
It's built on the same platform as IntelliJ IDEA which is a generally considered one of the best Java IDEs. There's a community edition which is free and open-source.
Like Eclipse is primarily a Java IDE written in Java, you could try Eric which is a Python IDE written in Python. I have had some issues with it in the past but I really enjoy the ability to stop your code at a breakpoint and have access to the python console to manipulate your data or even to inject new functions. PyDev could really use a console like that.
for a small proyects Scribes. Otherwise Eclipse+pydev.

UNIX shell written in a reasonable language? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
Has anyone ever heard of a UNIX shell written in a reasonable language, like Python?
Eshell is a Bash-like shell in Emacs Lisp.
IPython can be used as a system shell, though the syntax is a bit weird (supporting all of Python plus basic sh constructs).
fish has a core written in C, but much of its functionality is implemented in itself. Unlike many rare shells, it can be used as your login shell.
Hotwire deserves another mention. Its basic design appears to be "PowerShell in Python," but it also does some clever things with UI. The last release was in 2008.
Zoidberg is written in Perl and uses Perl syntax. A nice-looking project, shame it seems to have stalled.
Scsh would be a pain to use as a login shell (an example command from the docs: (run/strings (find "." -name *.c -print))), but it looks like a good "Perl in Scheme."
iPython (Python) and Rush (Ruby) are shells that are designed for more advanced languages. There's also Hotwire, which is sort of a weird integrated shell/terminal emulator.
From all appearances, Python IS a shell. It runs with #! and it can run interactively. Between the os and shutil packages you have all of the features of standard Unix shells.
Since you can do anything in Python with simple, powerful scripts, you don't really need to spend any time messing with the other shells.
Well, there's emacs, which is arguably a shell written in lisp :)
Seriously though, are you looking for a reimplementation of an existing shell design in a different language such as Python? Or are you looking for a new implementation of a shell language that looks similar to your language of choice?
There is xon now:
http://xon.sh/
http://xon.sh/tutorial.html#running-commands
PyCon video - https://www.youtube.com/watch?v=uaje5I22kgE
Tclsh is pretty nice (assuming you like Tcl, of course).
Try rash. It's a shell language written in Racket. It has a nice interactive-friendly syntax. You can embed Rash inside any normal Racket file as well as embedding normal Racket inside Rash. It's extensible and you can define new pipeline operators. It's still alpha quality at the moment, but it's pretty cool. Full disclosure: I wrote it.

Categories

Resources