Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5_fork
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Eteri
erp5_fork
Commits
be31425e
Commit
be31425e
authored
Dec 09, 2015
by
Vincent Pelletier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ERP5Type: Allow access to decimal module.
parent
04f86d23
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
+10
-0
product/ERP5Type/patches/Restricted.py
product/ERP5Type/patches/Restricted.py
+10
-0
No files found.
product/ERP5Type/patches/Restricted.py
View file @
be31425e
...
@@ -235,3 +235,13 @@ def guarded_import(mname, globals=None, locals=None, fromlist=None,
...
@@ -235,3 +235,13 @@ def guarded_import(mname, globals=None, locals=None, fromlist=None,
safe_builtins
[
'__import__'
]
=
guarded_import
safe_builtins
[
'__import__'
]
=
guarded_import
ModuleSecurityInfo
(
'transaction'
).
declarePublic
(
'doom'
)
ModuleSecurityInfo
(
'transaction'
).
declarePublic
(
'doom'
)
import
decimal
allow_module
(
'decimal'
)
ContainerAssertions
[
decimal
.
Decimal
]
=
1
ContainerAssertions
[
decimal
.
Context
]
=
1
for
member_id
in
dir
(
decimal
):
member
=
getattr
(
decimal
,
member_id
)
if
isinstance
(
member
,
type
)
and
issubclass
(
member
,
decimal
.
DecimalException
):
ContainerAssertions
[
member
]
=
1
del
member_id
,
member
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment