Skip to content
This repository was archived by the owner on Jan 9, 2020. It is now read-only.

Improve Solution Automation#254

Merged
jrleeman merged 4 commits intoUnidata:masterfrom
jrleeman:Improve_Solution_Checks
Nov 15, 2017
Merged

Improve Solution Automation#254
jrleeman merged 4 commits intoUnidata:masterfrom
jrleeman:Improve_Solution_Checks

Conversation

@jrleeman
Copy link
Copy Markdown
Contributor

@jrleeman jrleeman commented Nov 14, 2017

This should check for empty solution files and if any solution cells have any content other than the load magic (indicating that we accidentally left the solution filled in). Should fail at first blush as we have an empty solution and filled in solutions.

Will close #250 #252 #253

@jrleeman jrleeman force-pushed the Improve_Solution_Checks branch from 1fd6b80 to a985b5b Compare November 14, 2017 20:23
@jrleeman jrleeman closed this Nov 14, 2017
@jrleeman jrleeman reopened this Nov 14, 2017
with open(str(path), encoding='utf8') as f:
return header + f.read()
solution = f.read()
if solution == '':
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if not solution:

"""Find and non load magic or blank lines in a solution cell."""
for line in cell_text.split('\n'):
m = re.match('#\s?%load.*', line)
if not m and line != '':
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if not m and line:

@jrleeman jrleeman force-pushed the Improve_Solution_Checks branch from d4b8064 to ef3d01e Compare November 14, 2017 22:45
@jrleeman jrleeman force-pushed the Improve_Solution_Checks branch from ef3d01e to 6f1ff28 Compare November 15, 2017 14:56
@jrleeman jrleeman merged commit 93f18ec into Unidata:master Nov 15, 2017
@jrleeman jrleeman deleted the Improve_Solution_Checks branch November 15, 2017 19:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add content for skewT solution

2 participants