-
-
Notifications
You must be signed in to change notification settings - Fork 71
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
Cannot access internal class "ThisAssembly" here #55
Comments
Having same issue. It used to work before, no idea what caused it to break. |
If you could figure out what version it broke on, maybe we can track what's different? |
It probably broke on some version of Rider, not GitInfo. I'm using the nightly build. I'll try to experiment with some GitInfo versions. |
It seems (not sure) to happen when I have multiple projects using GitInfo in the one solution and one project referencing the other. |
My project setup is something like:
|
Another scenario were I've hit this issue ... I have a production code assembly and a matching unit tests code assembly. I use the attribute Note: It is possible that if your not using Resharper or you do not have 'treat warnings as errors' etc, you may not see this error. |
I'm working on some components in Windows VM and I have the same problem so this is not platform specific issue. I still think it's really issue in Resharper/Rider rather than in this project, |
@RobSmyth that's sort of expected. You should remove GitInfo from test projects, there's no need for it there. |
Hi, thanks. Yes that is a work around I've gone with. But to pick you up on:
... true to say that the vast majority of times there is much less need and it could be removed from the test code assembly. Almost always an acceptable limitations (and one that is OK with me). But, if your shipping the test assembly then that is not true. Thanks, Rob |
Yes, it's still true. Just give the test assembly |
Ah! Now that is useful as I think it is good for the test assembly (unit tests) to use the production assembly's assembly info. Nice, I think I'll use that. To take that a step further ... how about I have one version assembly in the solution and all others get their version from that? Will that cause unnecessary extra recompiles? Thanks. |
Sure thing. Check out https://github.com/MobileEssentials/Merq/blob/master/src/GlobalAssemblyInfo.cs and how it's used in the various projects. Basically everything imports https://github.com/MobileEssentials/Merq/blob/master/src/Merq.targets |
I guess this can be closed @RobSmyth? Not sure there's much GitInfo can do? |
I agree |
Just to give heads up for people interested, I reached out to JetBrains and they confirmed and reproduced the problem. Now all we have to do is wait. |
works ok in rider 2018.2.3 |
Hi,
Resharper raises errors "Cannot access internal class 'ThisAssembly' here" for each reference to ThisAssembly in the AssemblyInfoExt.cs file. The project does compile and run so it evidently does work.
I toss up as to if this is a Resharper issue or something GitInfo can fix. Anybody else seeing this?
The text was updated successfully, but these errors were encountered: