Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RotMatrix brocken with latest StaticArray #49

Closed
mauro3 opened this issue Nov 13, 2017 · 4 comments · Fixed by #50
Closed

RotMatrix brocken with latest StaticArray #49

mauro3 opened this issue Nov 13, 2017 · 4 comments · Fixed by #50

Comments

@mauro3
Copy link

mauro3 commented Nov 13, 2017

With StaticArrays.jl v0.6.5 this error occurs:

   _       _ _(_)_     |  A fresh approach to technical computing
  (_)     | (_) (_)    |  Documentation: https://docs.julialang.org
   _ _   _| |_  __ _   |  Type "?help" for help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 0.6.1 (2017-10-24 22:15 UTC)
 _/ |\__'_|_|_|\__'_|  |  
|__/                   |  x86_64-pc-linux-gnu

julia> using Rotations                                                                                                                                                   
                                                                                                                                                                        
julia> RotMatrix(-4.5)                                                                                                                                                   
ERROR: MethodError: Rotations.RotMatrix{2,Float64,4}(::StaticArrays.SArray{Tuple{2,2},Float64,2,4}) is ambiguous. Candidates:                                            
  (::Type{Rotations.RotMatrix{N,T,L}})(x::AbstractArray) where {N, T, L} in Rotations at /home/mauro/.julia/v0.6/Rotations/src/core_types.jl:78
  (::Type{SA})(a::StaticArrays.StaticArray) where SA<:StaticArrays.StaticArray in StaticArrays at /home/mauro/.julia/v0.6/StaticArrays/src/convert.jl:4
Possible fix, define
  (::Type{Rotations.RotMatrix{N,T,L}})(::StaticArrays.StaticArray)                                                                                                       
Stacktrace:                                                                                                                                                              
 [1] Rotations.RotMatrix(::Float64) at /home/mauro/.julia/v0.6/Rotations/src/core_types.jl:98                                                                            

Caused by commit JuliaArrays/StaticArrays.jl@025a991

mauro3 referenced this issue in JuliaArrays/StaticArrays.jl Nov 13, 2017
@Evizero
Copy link
Contributor

Evizero commented Nov 13, 2017

Also observing this error in Evizero/Augmentor.jl#15 and JuliaImages/ImageTransformations.jl#43

@tkoolen
Copy link
Contributor

tkoolen commented Nov 13, 2017

Also:

  MethodError: Rotations.RotMatrix{3,Float64,9}(::Rotations.Quat{Float64}) is ambiguous. Candidates:
    (::Type{Rotations.RotMatrix{N,T,L}})(x::AbstractArray) where {N, T, L} in Rotations at /home/travis/.julia/v0.6/Rotations/src/core_types.jl:78
    (::Type{SA})(a::StaticArrays.StaticArray) where SA<:StaticArrays.StaticArray in StaticArrays at /home/travis/.julia/v0.6/StaticArrays/src/convert.jl:4
  Possible fix, define
    (::Type{Rotations.RotMatrix{N,T,L}})(::StaticArrays.StaticArray)
  Stacktrace:
   [1] rand(::Type{Rotations.RotMatrix{3,Float64,9}}) at /home/travis/.julia/v0.6/Rotations/src/core_types.jl:44
<rest of stacktrace omitted>

@c42f
Copy link
Member

c42f commented Nov 18, 2017

Ugh, sorry guys, I was too hasty with the last release I think.

I think we need some minimal type in the style of the Rotations arrays so that we can capture these kind of problems in the future with the tests (it's not the first time we've broken Rotations with a StaticArrays release :-( )

@tkoolen
Copy link
Contributor

tkoolen commented Nov 19, 2017

See JuliaLang/METADATA.jl#12081.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants