Commit Graph

39 Commits

Author SHA1 Message Date
luz.paz
5b74dc8b0d Fix typos in src/Base 2019-08-17 15:32:49 +02:00
Zheng, Lei
59417068f5 Base: improve exception
For better FC and Python exception mapping.
2019-08-17 14:52:08 +02:00
wmayer
81ae5688d4 replace raw string with normal C string to fix build failure 2019-05-23 23:28:33 +02:00
ezzieyguywuf
81bae31085 Added python virtual environment initialization, if present. 2019-05-22 13:53:47 +02:00
wmayer
8d5d25da2e fix crash when checking an empty error message of an exception 2019-04-01 11:22:55 +02:00
luz.paz
6e64b4f75d Misc. typos 2018-05-19 12:06:34 -04:00
wmayer
7ed84a6590 workaround for bug in VS 2013 that occurs at Python init time 2018-04-15 19:05:06 +02:00
Unknown
a8ecffb652 Misc. typo fixes
Various workbenches
2017-12-23 14:30:30 +01:00
wmayer
770c9ce095 fix various coverity issues 2017-09-15 11:48:38 +02:00
wmayer
9513792292 py3: support of Python 3.4 2017-06-06 23:49:42 +02:00
wmayer
8ce343291b py3: fox compiler warnings
issue 0000995
2017-06-04 00:17:57 +02:00
Yorik van Havre
7114667d64 py3: Base: files A-I ported to python3
issue 0000995
2017-05-17 16:39:28 +02:00
wmayer
7d47a723fb Fix various issues:
+ fix dangling pointers when fetching Python error text
+ initialize members in overloaded constructors of Exception class
+ implement assignment operator in sub-class
+ move to PyCXX API to simplify handling with reference counting and reading values from the dict
2017-05-15 18:49:09 +02:00
Abdullah Tahiri
b410f8857c Enable exceptions to save/restore information in a python dictionary and enable throwing exception from dictionary information 2017-05-13 15:27:57 +02:00
Abdullah Tahiri
db8511883c Enable PyException to reconstruct the original exception 2017-05-13 15:27:57 +02:00
wmayer
1673ab801e use specialized exception classes 2017-04-28 18:49:11 +02:00
wmayer
464a8f3860 Coverity issues:
129643
129654
129689
129714
2016-08-16 14:05:52 +02:00
wmayer
c81aca0902 + unify method names 2016-05-18 23:43:58 +02:00
DeepSOIC
7f5197695d Attacher: add general purpose editor UI (python)
Added as PartGui.AttachmentEditor, and Part_EditAttachment gui command
2016-05-18 23:05:51 +02:00
Ian Rees
bc71c6e64b More fixes around Python exit codes 2016-03-27 13:01:04 +13:00
wmayer
7df94ca9af + fix crash when raising SystemExitException if not called inside Python function 2016-03-21 18:50:57 +01:00
Bruce Lacey
9816e48b07 Propagate sys.exit(code) up the call stack to the shell
SystemExitException is instantiated and thrown by Base::Interpreter
whenever the python interpreter executes a sys.exit(<exitCode>) call.
However, in the current implementation, the SystemExitException
effectively swallows the <exitCode> hence under this change,
SystemExitException has been extended to save the <exitCode> passed to
the sys.exit() call when it is instantiated and provides a new
getExitCode() accessor method to retrieve the <exitCode> in a
try/catch block.  MainGui.cpp was change to pass the corresponding
<exitCode> to the system exit() call so it is accessible in the shell.
2016-03-21 18:28:29 +01:00
wmayer
e9e9a38865 + improve exception handling in initialization scripts 2015-12-29 23:42:29 +01:00
wmayer
07ba938ff6 + issue: #0002350, handle Python's SystemExit exceptions and do not exit application when running from macro dialog or Python editor 2015-12-27 23:00:59 +01:00
Mateusz Skowroński
43a4a5938c Fix files encoding. Go from ISO8859-1 to UTF-8. 2015-09-21 19:50:49 -03:00
Eivind Kvedalen
75dab66916 Added InterpreterSingleton::getValue(...) function. 2015-02-13 21:53:57 +01:00
wmayer
053f76086b + fix one more missing va_end 2015-01-06 12:06:12 +01:00
wmayer
a96f390097 + fix build problems with Python & MacOSX 2014-10-13 22:02:57 +02:00
wmayer
7f874b9767 + cppcheck fixes 2013-09-20 21:00:45 +02:00
wmayer
a5d9d6312d Fix Python exception handling 2013-07-19 12:27:44 +02:00
wmayer
946bd02df4 Improve reporting of Python exceptions 2013-05-04 14:23:53 +02:00
wmayer
95de7d19cf Replace Python std output only for GUI application and not for CLI 2012-10-01 16:38:43 +02:00
wmayer
dfcee2e41e 0000831: python print causes File descriptor error on windows 2012-09-12 10:34:14 +02:00
wmayer
857454aad5 0000777: Shared libraries call exit 2012-07-05 15:24:28 +02:00
wmayer
1f690c0c81 Fix bug with identifying SWIG version 2012-03-14 08:52:42 +01:00
unknown
0e7df97961 Fix bug with identifying SWIG version 2012-02-29 21:52:49 +01:00
wmayer
048528b886 + handle Python's SystemExit exception when running script or macro
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5398 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2012-01-11 18:39:27 +00:00
wmayer
1884ee3881 0000528: Need a way to reset the Python instance
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5250 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-12-10 13:42:32 +00:00
wmayer
120ca87015 + unify DLL export defines to namespace names
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5000 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-10-10 13:44:52 +00:00