Does SublimeText 3 / GoSublime have some type of caching of Go import packages? If so, how do I clear it on demand?
I ask because while writing a custom package that is under Github source control, it works until I refactor a func or struct. Then, back at my main app (of where I import this package) it lights up like a Christmas tree when I start using the new methods.
GoSublime (or GoLint?) does not pick up the refactored func changes, and everything shows as an error. But yet, I can go to a prompt and run go build and go test just fine - the Go tool works fine.
The only thing I have been able to nail down is after about 24 hours it seems to work?
OSX 10.9
SublimeText 3
GoSublime
sublimelint **<- DO I NEED THIS? SAYS IT IS FOR HIGHLIGHTING**
SublimeLinter
SublimeLinter-contrib-GoLint
SublimeLinter-contril-GoType
(and a few other packages)
I'm a SublimeText novice; but, I believe I have everything linked up and the required packages installed. Sublime's console shows no errors in the Linters (says it find gotype and golint).
SublimeLinter: gotype activated: /Users/user1/go/bin/gotype
SublimeLinter: golint activated: /Users/user1/go/bin/golint
Things work beautifully within the package itself. It's not only my remote app. In my package, I have an "/examples" directory of tests that doesn't even pick up the changes in the root package. But again, the actual Go tool does and builds and runs all tests using the new refactored code.
It is GoSublime/GoLint that is caching the import's schema/package details. How do I clear that?
Thanks!
Coming back to answer myself this after 5 months of no answers...
#dave-cheney himself replied to a Google Groups message I posted on this subject:
https://groups.google.com/forum/#!topic/golang-nuts/N3xB6PGs3wo
Resolution:
That code, even one-off tooling for other projects, must live in your $GOPATH/src. I have changed all projects to be in the $GOPATH/src/privatedomain/etc, and updated build scripts to just deploy the executable to those other repos (and commit them). Learn to work with the tools, not fight it. :)
You need to run go install [package] on those locally developed packages for their changes to show up immediately in your current Sublime project. There is still a long day-long delay that happens though if you don't run go install that the changes are picked up in other tools/packages within Sublime. "go install" works to get around this every time so no big deal (*see next bullet point).
In Sublime, I often run go install [package] and then close/re-open the current file I am working on to pick up the changes.
Note that you don't have to be online for the go install [package] - if the package is local that is (e.g. in development). So, this was the answer to my environment since I do a lot of development offline (commuting).
Related
I have just installed python3.8 and sublime text editor. I am attempting to run the python build on sublime text but I am met with "Python was not found but can be installed" error.
Both python and sublime are installed on E:\
When opening cmd prompt I can change dir and am able to run py from there without an issue.
I'm assuming that my sublime is not pointing to the correct dir but don't know how to resolve this issue.
This isn't a Sublime issue, it's a Windows 10 issue. My Windows 10 boxes don't have this feature so I'm not sure how widely spread it is, but you may want to check out this (seemingly unrelated) question "Permission Denied" trying to run Python on Windows 10.
The general gist from this post is that these new stub redirectors are supposed to direct you into installing some missing applications from the Windows App store and that user-installed versions are supposed to take priority, but depending on how the PATH is modified the system might find the stub versions before your user installed versions.
The currently accepted answer mentions:
The second part of correcting it is to type "manage app execution aliases" into the Windows search prompt and disable the store versions of Python altogether.
It's possible that you'll only need to do the second part, but on my system I made both changes and everything is back to normal now.
In the comments, there are comments from Zooba which further indicate that this is the way to go:
(Microsoft employee and CPython core developer here) You definitely only need to do the second part. There have been a couple of bugs related to upgrading apps resetting aliases which will be fixed in the next stable update, so it should be a one-time fix by then. While you're getting Insiders updates you may need to do it a couple more times.
... And launching the Store is a new feature to help people install Python - if you've added it to PATH using the regular installer it should take precedence over the new redirector, but if not you've discovered above how to disable it.
i had the same problem, so i went to the microsoft store (windos 10) and simply installed "python 3.9" and problem was gone!
sorry for bad english btw
While working with some projects checked out from Git, we get errors with modifying the project settings in MyEclipse. I am trying to modify the deployment values in my workspace and it is not letting me (screenshot below).
There isn't a lot of information to go on, here (e.g. what is the version of MyEclipse, what type of project is this, what properties page are you switching from, the OS and version, whether this has worked before, the error log - but please don't paste that in here - and so on).
However, here are some actions that might help resolve it:
Firstly, try a fresh empty workspace then import the project from the old workspace, or better still import again from Git. This would help clean up possibly corrupted settings in the workspace.
Another thing to try is to launch MyEclipse with the -clean option (just add that option to the top of your myeclipse.ini file, found in the installation folder).
#Howlger is right, though, this is a commercial product and we may be better able to help if you raised the issue in the MyEclipse support forums.
I want to make some little changes in OpenBTS code and use it. Currently I am following this process
Make some changes in code. ( Can't do testing of these changes at runtime)
Build the packages
Install the packages
Setup or Run OpenBTS
Test the behavior of OpenBTS to see that those changes are reflected or not.
If not working, goto step 1
This a quite hectic process, is there any smarter way to do it. Like OpenBTS is directly run from code, rather than packages installed on Ubuntu. If I make change in code, and they are directly reflected in my setup. How i can setup this dev environment.
This answer is a bit late, I have just started to work on this my self. I don't bother installing the packages each time. My cycle is more like this:
Build the packages
Setup/run the database scripts (init the databases)
Install the packages that I don't need to re-build
Run each package manually (from the open BTS folders), e.g. run ../Transceiver, ../sipauthserver, ../OpenBTS, ../OpenBTSCLI ...etc...
Then when I want to make a code change - I do:
Stop everything
Code change
Re-build (e.g. just openBTS)
Re-run everything as before.
I also scripted the startup / stop sequences to make this faster (open/run each app in new terminals)
this is EXTREMELY frustrating to anyone who just wants to pull down your code and check it out and get it to simple build successfully.
Here's the scoop.
So I open the ServiceStack.Examples-master\src\AppHarbor.sln after pulling it from github and cloning it to my local drive.
I have had nothing but trouble from the get go. I have had to fix this solution and project reference as well as assembly references.
there's nothing more irritating to a developer no matter if it's an internal solution or set of .NET projects or external, that bomb during initial build. This stuff should be building period.
Also when I can't even download an examples solution and get it to build it makes people wonder how well this open source API really is, can I truly even rely on it? This reflects on you Service Stack.
here's is what I did, nothing out of the norm here:
1) Cloned ServiceStack.Examples to my local c:\www\Sandbox folder where I keep stuff I'm playing around with
2) Just looking at the folder structure from the start, it makes no sense in terms of being discoverable and more importantly organized. For example why is there yet another ServiceStack.Examples inside src and then outside of that a ton of other example folders of other example apps in the root of \src also??? So you have stuff in src\ and in src\ServiceStack.Examples, this is hell confusing and disorganized.
ServiceStack.Examples\src\ServiceStack.Examples
3) Opened C:\www\Sandbox\ServiceStack.Examples\src\AppHarbor.sln
4) Tried to build all, and the first major problem is the MovieRest project doesn't load. I get an error while opening the .sln that it failed to load it:
ok fine, this is still ridiculous, nobody who downloads a solution should need to worry about fixin this but of course I did, so I readded it because in actuality this .csproj was moved into the src\ServiceStack.MovieRest\Web\ folder and looks to me like nobody even reopened the solution to fix it??
5) So then I go to try and build the solution again, notice all the missing binary references in MovieRest. So ultimately I figured ok, looks like pretty much every other project is getting their references from their associated packages folder however for some Reason MovieRest and the Nortwind projects don't have anything in their packages folder. so I end up manuall opening up the MovieRest VS 2012 solution and building it, and I guess Nuget must run or something during that build? Because now walla, I see the missing assemblies pop into ServiceStack.Examples\src\ServiceStack.MovieRest\packages finally.
6) Ok, so I rebuild again, and now it's complaining about missing sqllite assemblies and also a sqllite3.exe. So now I have to hunt around again to find them for the x84 and x64 and copy those missing assmblies back into ServiceStack.Examples\src\ServiceStack.MovieRest\Web\sqlite and I also noticed that MoviewRest project was referencing sqllite3.dll in the root of the project which was also missing...this is such a mess.
7) I notice that the Northwind project doesn't build either
I don't know what is going on here, I mean is the build really that messed up? Has to be.
Who is gonna fix this on the ServiceStack end? how the heck do I get this to finally build and how has this not been reported?
UPDATED 9/23
Here are the errors I get after pulling down the "fixed" solution. I did a Shift + Ctrl + B on it (Build All). Let me know if I am just missing something here but it's not building yet at least on my side:
UPDATE 10/1
Ok again lets talk about this.
I pulled this zip down: https://github.com/ServiceStack/ServiceStack/archive/v3-snapshot.zip from this page: https://github.com/ServiceStack/ServiceStack/releases
Opened the solution src\ServiceStack.sln (VS 2012 version)
First I get this SQL Express Error after opening it for the first time:
Now I try to build all on the solution and I get this build error:
So tell me what I could possibly doing wrong? This is a "Release" right? It should build right? It's not rocket science so how can people say this is a "dev consumer" issue? All I want is a stable release build. Simple.
I've just upgraded ServiceStack.Examples to VS 2013/IIS Express and updated it to the latest version of ServiceStack v3.9.63 that was just deployed. It should all build now, also some examples requires redis to be running on localhost.
I'm finding the BB/Eclipse environment incredibly unstable and wanted to know if I'm doing something fundamentally wrong here?
I build my project and it produces about 40 or so COD files... usually. Sometimes if I clean and run some COD files are missing and it fails to run (or worse it runs the old version somehow). I kid you not, I'm spending about an hour each time I want to run/test my setup which is an order of magnitude slower than the other platforms I work with. It eventually works by hitting the clean/debug/clean/debug/etc... and doing nothing else except these clean/debug/repeat steps.
If I make incremental changes to my src it's fairly reliable at picking them up but when I add a new resource via windows explorer and say 'refresh' on that directory in eclipse it's when all the problems start.
Any pointers from experienced Eclipse/BB users would be much appreciated (especially how to narrow down why sometimes it works and sometimes it doesn't).
Thanks,
Stuart
I believe I've narrowed down the issues. Firstly I use DropBox on the src but this has the inadvertent feature of backing up build files and can't find a way of disabling this.
If the files are locked by Dropbox it unsurprisingly fails, the catch is it doesn't say 'couldn't write to file as it's locked' or anything helpful like that... just fails. Obviously when I go to inspect it Dropbox has done it's stuff so the perfect crime!
My learnings:
disable Dropbox on COD producing builds.
When changing SDK version I found I have to
change the SDK via the build config settings,
clean,
exit eclipse,
delete the build directory with windows explorer,
Restart eclipse and hit refresh/clean.
That seems to build fairly reliably now. Without restarting Eclipse I get all sorts of wierd errors of files going to wrong locations and dirty data being picked up. The main one is any //#ifdef's are not picked up by the preprocessor correctly so get 1001 errors.