Skip to content

Commit 5ea2534

Browse files
committed
Merge remote-tracking branch 'remotes/origin/main'
2 parents b7029dd + 0ef0bfd commit 5ea2534

File tree

2 files changed

+27
-21
lines changed

2 files changed

+27
-21
lines changed

GSASII/GSASIIpath.py

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2031,10 +2031,11 @@ def openInNewTerm(project=None,g2script=None,pythonapp=sys.executable):
20312031

20322032
if __name__ == '__main__':
20332033
'''What follows is called to update (or downdate) GSAS-II in a
2034-
separate process.
2034+
separate process. This is also called for background tasks such as
2035+
performing a "git fetch" task or getting current tag information from
2036+
github.
20352037
'''
20362038
# check what type of update is being called for
2037-
import git
20382039
gitUpdate = False
20392040
preupdateType = None
20402041
updateType = None
@@ -2096,6 +2097,11 @@ def openInNewTerm(project=None,g2script=None,pythonapp=sys.executable):
20962097
print('invalid form for --git-regress')
20972098
help = True
20982099
break
2100+
try:
2101+
import git
2102+
except:
2103+
print('Import of git failed for --git-regress')
2104+
sys.exit()
20992105
gitversion = argsplit[1]
21002106
# make sure the version or tag supplied is valid and convert to
21012107
# a full sha hash
@@ -2242,23 +2248,23 @@ def openInNewTerm(project=None,g2script=None,pythonapp=sys.executable):
22422248
fp.close()
22432249
sys.exit()
22442250

2251+
try:
2252+
import git
2253+
except:
2254+
print(f'Import of git failed. {updateType} update mode {preupdateType}')
2255+
sys.exit()
2256+
22452257
if gitUpdate:
22462258
import time
22472259
time.sleep(1) # delay to give the main process a chance to exit
22482260
# so we don't change code for a running process
22492261
# windows does not like that
2250-
try:
2251-
import git
2252-
except:
2253-
print('git import failed')
2254-
sys.exit()
2255-
try:
2256-
g2repo = openGitRepo(path2GSAS2)
2257-
except Exception as msg:
2258-
print(f'Update failed with message {msg}\n')
2259-
sys.exit()
2260-
print('git repo opened')
2261-
2262+
try:
2263+
g2repo = openGitRepo(path2GSAS2)
2264+
except Exception as msg:
2265+
print(f'Update failed with message {msg}\n')
2266+
sys.exit()
2267+
print('git repo opened')
22622268
if preupdateType == 'reset':
22632269
# --git-reset (preupdateType = 'reset')
22642270
print('Restoring locally-updated GSAS-II files to original status')

GSASII/git_verinfo.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# -*- coding: utf-8 -*-
22
# git_verinfo.py - GSAS-II version info from git
3-
# Do not edit, generated by 'GSASII/install/incr-version.py' script
4-
# Created 2025-06-22 13:56:06.036268-05:00
3+
# Do not edit, generated by 'install/incr-version.py' script
4+
# Created 2025-06-25 08:39:57.064953-05:00
55

6-
git_version = '17c29ab4017926c607850a1989e82337049e1534'
7-
git_tags = ['5814']
8-
git_prevtaggedversion = 'c37c8ba4cdc73a97e0a8ccf9d9f3c95758502e5b'
9-
git_prevtags = ['5813']
10-
git_versiontag = 'v5.4.7'
6+
git_version = 'b91e5e3deb601e475ec53be39b25a82ad3491386'
7+
git_tags = ['5815']
8+
git_prevtaggedversion = '17c29ab4017926c607850a1989e82337049e1534'
9+
git_prevtags = ['5814']
10+
git_versiontag = 'v5.4.8'

0 commit comments

Comments
 (0)