Skip to content

Commit

Permalink
fixing petram() start up withou TwoPiRoot enviroment
Browse files Browse the repository at this point in the history
  • Loading branch information
sshiraiwa committed Jan 19, 2024
1 parent de8cb4c commit d3bee23
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 8 additions & 0 deletions petram/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,11 +146,19 @@ def get_evn_twopiroot():

def check_cluster_access():
petram = get_evn_twopiroot()

if petram is None:
from ifigure.ifigure_config import rcdir as petram

return os.path.exists(os.path.join(petram, "etc", "cluster_access"))


def check_addon_access():
petram = get_evn_twopiroot()

if petram is None:
from ifigure.ifigure_config import rcdir as petram

if os.path.exists(os.path.join(petram, "etc", "addon_access")):
return "any"
return "none"
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
setup(
name='PetraM_Base',

version='2.1.26',
version='2.1.27',

description='PetraM base package',
long_description=long_description,
Expand Down

0 comments on commit d3bee23

Please sign in to comment.