Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 1 year ago.
This post was edited and submitted for review 1 year ago and failed to reopen the post:
Original close reason(s) were not resolved
Improve this question
I would like to get more experience with the different elements that running and writing python involves. I used Pycharm to start writing code.
Pycharm is great at simplifying the whole process, which includes obscuring even the simplest parts.
I'd like to move my projects to a more hands-on editor.
I really like syntax highlighting and completion so an editor with those attributes is preferred.
You can try to use Atom or VSCode. More information about atom can be found here: https://atom.io/
About VSCode try this link:
https://code.visualstudio.com/
When it comes to moving projects to another text editor, PyCharm creates certain files in order to store the scripts, and you can find those files like this:
as you can see, this is the left side window in pycharm, and next to the title there is a path. That path is where the file is located.
You can drag and drop the scripts to the icon of the new text editor in order to open them from there.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 days ago.
This post was edited and submitted for review 3 days ago and failed to reopen the post:
Original close reason(s) were not resolved
Improve this question
The problem
Not knowing how to manage the code changes required when you move a script from your development area to your production/operational area
Background
I am just an amateur programmer but I have written many programs in PowerShell, and lately in Python.
When the software works I create a 'operational' directory and put the files in there, but later I see the need to improve the code. So I copy the files to a 'development' directory and make the changes there - cos I don't want to bugger up the working operational code.
When I have made and tested the changes I move the code from the development to the operational environment. I am sure that many do the same.
My problem
My problem is that the code needs extensive changes to make the move. For instance changing internal file paths from the development to operational. Hashing some Write statements that I have used for bug fixing, etc.
Usually, I don't find all the changes and some development bits find their way into the operational code which is not good for the user. For instance Write("David you've made a bit if a mess of this code").
The request
What do people do in similar circumstances? So I am not looking for complex software more suited to team development; something that an individual can use.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 months ago.
Improve this question
When I open and excel file, the excel show me a message.
"Do you want to open this excel file anyway?" Yes, No, Cancel
I want to open it by python and automatically click Yes by python too, afterr that I will start to edit the excel by python program. I don't know what to do with pushing the yes button! I am totally beginner in python. I would be grateful if anyone can help me.
The Python module pandas can help you. If you change the file extension to .xlsx as pyzer mentioned, you can access your data with pandas as explained in this tutorial.
For a few general resources on learning Python, I recommend the official documentation and The Hitchiker's Guide to Python.
Best of luck!
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
I often debug Python using a Sublime Python repl extension, and the processes often stack up without closing. Is there something I can append to the end of my code to automatically end the repl process? I can right click it to 'kill repl,' but am looking for an automatic way.
I have tried using exit() and sys.exit() but they do not terminate the processes. Frankly I'm not remotely aware of how REPL or terminals in general work under the hood.
I'm not too familiar with sublime text, but from brief searches online on the most prominent REPL (https://packagecontrol.io/packages/SublimeREPL) it looks like the REPL is part of the sublime process which might be why exit() and sys.exit() aren't working. It looks like you can just close the window tab and that ends the process but i'm not 100% sure.
Although it might not be a solution to your specific issue (I can't comment on SO yet), if you are looking for an interactive local REPL for debugging and testing a good option might be ptpython. It has autocomplete and you can use exit() since it's actually a separate python process, but it does require a separate terminal (unless there's a sublime integration).
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 7 years ago.
Improve this question
i need to know what i should put in a new python project directories,
such as /core, /lib... and what they must contain & what are the other important things todo
i have browsed some articles about python project structure but got nothing useful. http://docs.python-guide.org/en/latest/writing/structure/
/core/ -> what should contain as an example?
....
need some help with that, and thanks in advance
This is advice for someone who is starting completely afresh, as I imagine you do based on your question.
There are generally no core or lib directories in a python project. Start your project in one file. Run it with python. Once your file gets too big, start separating things into other files, and after that into modules (subdirectories with __init__.py files).
Somewhere during that process, read the link you have also included several times, try and understand it, because that contains very good advice on what you need to know about structure.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 7 years ago.
Improve this question
I have an issue, I am working on a jython project while editing it with Notepad++. I'm having an issue where I save the file, open it in normal notepad.exe and the file comes out completely different to how i edited it on Notepad++. It seems to be that wherever I pressed Enter for a new line, notepad++ formatted it to have a few spaces and the whole 150+ line code is word wrapped around five lines of carriage returns.
Any idea how I can fix this? I figure it's in settings but I don't know how to google for it and don't want to try every option until it works as notepad++ is quite feature rich!
Found out myself! Edit > EOL conversion > Windows Format Thanks ME! No, wait, credit goes to: this guy.