Welcome!
This is the community forum for my apps Pythonista and Editorial.
For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.
IDE GUI Python 3.5.1 for Mac OS X 10.11
-
-
Pycharm requires java... Atom looks interesting @Webmaster4o I installed the scripts package to run things, and using the same exact file in the same location as elsewhere using atom I get an import error... No module named "requests" ... strange.
I personally use Sublime Text 3 .... can even set up a custom build system to quickly build an iOS app from Xcode command line tools and launch into simulator without even going into xCode.
-
@Tizzy Script behaves kind of funny as far as which python install it uses (system or local). You can fix this by adding a
#!/usr/local/bin/python
to the beginning of the script. (on mac, idk about windows, the path might be different.) The other way to fix this is to start atom from the command-line by typing "atom" -
@Webmaster4o thanks. starting it from the command line seems to be the simplest workaround.
-
@Tizzy This was actually the 5th issue on the package, after release: https://github.com/rgbkrk/atom-script/issues/5
-
@Tizzy PyCharm "requires" Java, but it comes with a JRE built-in as a framework. Besides, it's not like Java is such a bad thing that it justifies not using an IDE that requires it.
When I'm not working on any huge projects, I use TextWrangler (the free version of BBEdit) as my general-purpose text editor. It works quite well for me. I did install TextMate, but it doesn't have any huge features that TextWrangler doesn't, so I won't be switching anytime soon. Though the whole bundle system seems a lot more powerful and accessible than TextWrangler's language module support. (TextMate also installs a QuickLook handler that does syntax highlighting in the spacebar previews for files. Which is neat, but it also cuts off files after some number of characters, which is extremely frustrating because I then have to actually open the file.)
Atom... urgh... JavaScript... like seriously whose idea was it to use that broken language anywhere outside a web browser... (I think I'm now contradicting what I said before about PyCharm and Java. Oops.)
-
@dgelessus Atom is written in CoffeeScript (which compiles to JS). This improves the language syntax considerably. The whole thing is built on top of Node.js and the Electron framework, which, to my understanding, adds a lot of functionality to JS and makes stuff more stable. Atom is not something that could ever run in a web browser. It's much more powerful than that.
-
@Webmaster4o Yes, I'm aware of that, but it still compiles to and is based on JavaScript. And JavaScript has some very... interesting behavior at the language level. (If you don't know what I'm talking about, there's a certain talk by Gary Bernhardt that you need to watch.)
The main reason why JavaScript is so popular is because it was introduced as a website scripting language and there was no choice on what language you could use. But I simply don't understand why people continued to use a language with such broken behavior for new software where there are better and more established alternatives available. From what I can tell, JavaScript doesn't offer much more than Lua (which is very similar to JavaScript with regards to being lightweight, embeddable and using prototype-based objects/tables) where adding two empty tables does not equal
NaN
, but actually produces an error and stops the program from running. -
@Webmaster4o a more resilient Python "shebang" line for Macs and other unix/linux boxes would be:
#!/usr/bin/env python
That formulation will use
env
find your system's default Python regardless of linux distro or exact path. For instance I use homebrew tobrew install python3 python pypy3 pypy
on my Mac and then I can switch between four different Python implementations just by changing the final word of my shebang line.brew cask install anaconda
is however probably the coolest Python thing to do on the Mac these daze. -
@ccc Just FYI, that shebang will also work just fine on Windows. In fact the Windows version of Python is very liberal regarding shebangs. Because they are not a feature of Windows, Python comes with a "Python Launcher" (
py.exe
) which is assigned as the default program for.py
files. When youstart
a Python script, the Python launcher checks for a shebang and then basically looks for the wordpython
optionally followed by a version number to figure out which Python version should be used. That's why some Windows people write#!python
at the top of their scripts - it works for them. On Unixes it doesn't, because the shebang needs to be an absolute path.Long story short, use
#!/usr/bin/env python
and you'll be fine. -
If I'm not too late to the game, I have been using Interactive Editor for Python as my main "IDE" for coding Python on my Mac (it works on all platforms). It works very similarly to Pythonista: editor; file browser; interactive console; and other really nice tools. I particularly like the workspace tool, which showed you all of your currently instanciated stuff.
-
@dgelessus I think the reason why JavaScript is still used over Lua is that you can't really build web applications easily with Lua. You can do plenty of back-end stuff with Lua, but the front-end is all JavaScript. If you know what the peculiarities of a language are, it's not hard to work around.