Skip to content

Commit

Permalink
Upgraded to julia v1.5 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
hdrake committed Sep 15, 2020
1 parent ff9d64d commit 7978203
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ os:
- osx

julia:
- 1.4
- 1.5

env:
global:
Expand All @@ -17,7 +17,7 @@ notifications:
jobs:
include:
- stage: "Documentation"
julia: 1.4
julia: 1.5
os: linux
script:
- julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd()));
Expand Down
12 changes: 6 additions & 6 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "ClimateMARGO"
uuid = "d3f62095-a717-45bf-aadc-ac9dfc258fa6"
version = "0.1.1"
version = "0.1.2"

[deps]
Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa"
Expand All @@ -14,14 +14,14 @@ Revise = "295af30f-e4ad-537b-8983-00126c2a3abe"

[compat]
Combinatorics = "1.0.2"
IJulia = "1.21.2"
Ipopt = "0.6.2"
IJulia = "1.21.3"
Ipopt = "0.6.3"
JSON2 = "0.3.2"
JuMP = "0.21.3"
JuMP = "0.21.4"
PyCall = "1.91.4"
PyPlot = "2.9.0"
Revise = "2.7.3"
julia = "^1.3"
Revise = "2.7.6"
julia = "^1.5"

[extras]
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
Expand Down
4 changes: 2 additions & 2 deletions src/ClimateMARGO.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module ClimateMARGO

if VERSION < v"1.3"
@error "ClimateMARGO requires Julia v1.3 or newer."
if VERSION < v"1.5"
@error "ClimateMARGO requires Julia v1.5 or newer."
end

include("Models/Models.jl")
Expand Down
4 changes: 2 additions & 2 deletions src/Optimization/deterministic_optimization.jl
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ function optimize_controls!(
)

for (key, control) in control_vars
if control_inits[key] != nothing
if control_inits[key] !== nothing
fix(control_vars[key][1], control_inits[key]; force = true)
Nstart = 2
else
Expand All @@ -196,7 +196,7 @@ function optimize_controls!(
fix(control_vars[key][idx], controls[key][idx]; force = true)
else
if tarr[idx] < start_deployment[key]
if control_inits[key] != nothing
if control_inits[key] !== nothing
fix(control_vars[key][idx], control_inits[key]; force = true)
else
fix(control_vars[key][idx], 0.; force = true)
Expand Down

2 comments on commit 7978203

@hdrake
Copy link
Collaborator Author

@hdrake hdrake commented on 7978203 Sep 15, 2020

Choose a reason for hiding this comment

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

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

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

Registration pull request created: JuliaRegistries/General/21447

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.1.2 -m "<description of version>" 7978203c85204946367c3a8d70ef31d9f573d54e
git push origin v0.1.2

Please sign in to comment.