Skip to content

Commit 4e2b285

Browse files
authored
Merge pull request #970 from I2PC/release-3.24.12
Fixing branch for plugin, adapting parse, updating tagName
2 parents b3b0cb2 + d7be5dd commit 4e2b285

File tree

5 files changed

+24
-14
lines changed

5 files changed

+24
-14
lines changed

CHANGELOG.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Release 3.24.12.0 - Poseidon
1+
## Release 3.24.12.0 - Poseidon
22
### Xmipp Programs
33
- New programs
44
- tomo_average_subtomos: This method carries out a subtomogram averaging. It means, given a set of subtomogram the program will estimate the average map
@@ -33,7 +33,7 @@
3333
- Fix for rare axis orderings in MRC/MAP files
3434
- Local average label added (used to measure the intensity of the particles in the original micrographs)
3535

36-
## Release 3.24.06 - Oceanus
36+
## Release 3.24.06 - Oceanus
3737
### Xmipp Programs
3838
- New programs
3939
- xtomo tigre reconstruction: This program provides a variety of algorithms to reconstruct tomogram from a set of tilt series
@@ -72,7 +72,7 @@
7272
- Adding fixed extension to tomo
7373

7474

75-
## Release 3.23.11 - Nereus
75+
## Release 3.23.11 - Nereus
7676
### Xmipp Programs
7777

7878
- New programs
@@ -151,7 +151,7 @@
151151

152152

153153

154-
## Release 3.23.03 - Kratos
154+
## Release 3.23.03 - Kratos
155155
### Xmipp Programs
156156

157157
- New programs: tomo_confidence_map, tomo_extract_particlestacks, tomo_extract_subtomograms, tomo_tiltseries_dose_filter, psd_estimatator

installer/constants/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
# Other variables
7474
TAB_SIZE = 4
7575
SECTION_MESSAGE_LEN = 60
76-
TAG_BRANCH_NAME = 'HEAD'
76+
TAG_BRANCH_NAME = 'v3.24.12.0-Poseidon'
7777

7878
# File names
7979
CONFIG_FILE = 'xmipp.conf'

installer/constants/parser.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@
9999
PARAM_SHORT = 'short'
100100
PARAM_JOBS = 'jobs'
101101
PARAM_BRANCH = 'branch'
102+
PARAM_PRODUCTION = 'production'
102103
PARAM_MODELS_DIRECTORY = 'models-directory'
103104
PARAM_TEST_NAME = 'test-name'
104105
PARAM_SHOW_TESTS = 'show-tests'
@@ -126,6 +127,10 @@
126127
LONG_VERSION: "--branch",
127128
DESCRIPTION: "Branch for the source repositories."
128129
},
130+
PARAM_PRODUCTION: {
131+
LONG_VERSION: "--production",
132+
DESCRIPTION: "Flag to identify a production compilation (avoid the download of the plugin)."
133+
},
129134
PARAM_MODELS_DIRECTORY: {
130135
SHORT_VERSION: "-d",
131136
LONG_VERSION: "--directory",
@@ -178,7 +183,7 @@
178183
MODE_ARGS = {
179184
MODE_VERSION: [PARAM_SHORT],
180185
MODE_COMPILE_AND_INSTALL: [PARAM_JOBS, PARAM_BRANCH, PARAM_KEEP_OUTPUT],
181-
MODE_ALL: [PARAM_JOBS, PARAM_BRANCH, PARAM_KEEP_OUTPUT],
186+
MODE_ALL: [PARAM_JOBS, PARAM_BRANCH, PARAM_KEEP_OUTPUT, PARAM_PRODUCTION],
182187
MODE_CONFIG_BUILD: [PARAM_KEEP_OUTPUT],
183188
MODE_CONFIG: [PARAM_OVERWRITE],
184189
MODE_GET_MODELS: [PARAM_MODELS_DIRECTORY],
@@ -207,6 +212,7 @@
207212
'./xmipp',
208213
f'./xmipp {MODE_ALL}',
209214
f'./xmipp {PARAMS[PARAM_JOBS][SHORT_VERSION]} 20',
215+
f'./xmipp {PARAMS[PARAM_PRODUCTION][LONG_VERSION]}',
210216
f'./xmipp {PARAMS[PARAM_BRANCH][SHORT_VERSION]} devel',
211217
f'./xmipp {MODE_ALL} {PARAMS[PARAM_JOBS][SHORT_VERSION]} 20 '
212218
f'{PARAMS[PARAM_BRANCH][SHORT_VERSION]} devel'

installer/main.py

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@
3535
from .constants import (REPOSITORIES, XMIPP_SOURCES, SOURCES_PATH, MASTER_BRANCHNAME,
3636
SOURCE_CLONE_ERROR, TAG_BRANCH_NAME, INTERRUPTED_ERROR, VERSION_FILE, RELEASE_DATE,
3737
XMIPP_VERSIONS, XMIPP, VERSION_KEY, SECTION_MESSAGE_LEN, VERNAME_KEY, MODE_GET_SOURCES,
38-
MODE_CONFIG_BUILD, CONFIG_FILE)
38+
MODE_CONFIG_BUILD, CONFIG_FILE, XMIPP_PLUGIN)
3939
from .api import sendApiPOST, getOSReleaseName
4040
from .cmake import parseCmakeVersions
4141
from .config import getConfigDate
4242

4343
####################### COMMAND FUNCTIONS #######################
44-
def getSources(branch: str=None):
44+
def getSources(branch: str=None, production: bool=False):
4545
"""
4646
### This function fetches the sources needed for Xmipp to compile.
4747
@@ -51,10 +51,13 @@ def getSources(branch: str=None):
5151
# Clone or download internal sources
5252
logger(getSectionMessage("Getting Xmipp sources"), forceConsoleOutput=True)
5353
for source in XMIPP_SOURCES:
54-
logger(f"Cloning {source}...", forceConsoleOutput=True)
55-
retCode, output = __cloneSourceRepo(REPOSITORIES[source][0], path=SOURCES_PATH, branch=branch)
56-
message = output if retCode else ''
57-
handleRetCode(retCode, predefinedErrorCode=SOURCE_CLONE_ERROR, message=message, sendAPI=False)
54+
if source == XMIPP_PLUGIN and production:
55+
pass
56+
else:
57+
logger(f"Cloning {source}...", forceConsoleOutput=True)
58+
retCode, output = __cloneSourceRepo(REPOSITORIES[source][0], path=SOURCES_PATH, branch=branch)
59+
message = output if retCode else ''
60+
handleRetCode(retCode, predefinedErrorCode=SOURCE_CLONE_ERROR, message=message, sendAPI=False)
5861

5962
def exitXmipp(retCode: int=0):
6063
"""

xmipp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ from installer.constants import (MODE_ALL, MODE_COMPILE_AND_INSTALL, MODE_CONFIG
3434
CMAKE_CONFIGURE_ERROR, CMAKE_COMPILE_ERROR, CMAKE_INSTALL_ERROR, PARAM_LOGIN, PARAM_SHORT,
3535
PARAM_JOBS, PARAM_BRANCH, PARAM_GIT_COMMAND, PARAM_TEST_PRO, PARAM_TEST_PRO, PARAM_TEST_FUNC, PARAM_MODEL_PATH,
3636
PARAM_MODELS_DIRECTORY, PARAM_KEEP_OUTPUT, PARAM_SHOW_TESTS, PARAM_TEST_NAME, PARAM_UPDATE,
37-
PARAM_OVERWRITE, BUILD_PATH, INSTALL_PATH, BUILD_TYPE, SOURCES_PATH, XMIPP_SOURCES, XMIPP,
37+
PARAM_OVERWRITE, BUILD_PATH, INSTALL_PATH, BUILD_TYPE, SOURCES_PATH, XMIPP_SOURCES, XMIPP, PARAM_PRODUCTION,
3838
LOG_FILE, CMAKE_ERROR, MODE_GET_SOURCES, VERSION_FILE, PARAMS, LONG_VERSION, SHORT_VERSION, SEND_INSTALLATION_STATISTICS)
3939
from installer.utils import runStreamingJob, runJob
4040
from installer.parser import ModeHelpFormatter, GeneralHelpFormatter, ErrorHandlerArgumentParser, getParamNames
@@ -221,7 +221,7 @@ def modeGetSources(args: argparse.Namespace):
221221
- args (Namespace): Command line arguments parsed by argparse library.
222222
"""
223223
# Clone sources from specified branch
224-
getSources(branch=args.branch)
224+
getSources(branch=args.branch, production=args.production)
225225

226226
def modeGit(args: argparse.Namespace):
227227
"""
@@ -372,6 +372,7 @@ if __name__ == "__main__":
372372
allSubparser = subparsers.add_parser(MODE_ALL, formatter_class=ModeHelpFormatter)
373373
allSubparser.add_argument(*getParamNames(PARAM_JOBS), type=int, default=JOBS)
374374
allSubparser.add_argument(*getParamNames(PARAM_BRANCH))
375+
allSubparser.add_argument(*getParamNames(PARAM_PRODUCTION), type=bool, default=False)
375376
allSubparser.add_argument(*getParamNames(PARAM_KEEP_OUTPUT), action='store_true')
376377

377378
# Arguments for mode 'cleanAll'

0 commit comments

Comments
 (0)