IngvarX/Camelot

installation: "Access to the path '/usr/share/Camelot/Camelot.db' is denied."

Opened this issue · 6 comments

Linux Mint 20.0
running .DEB with GDebi Package Installer
https://termbin.com/xqbg
Note: file mentioned did not appear to have been created.
GDebi prompted for sudo password, and then ran, but failed with below
-----------------------begin CamelotLog-20201219.txt------------------------
2020-12-19 13:56:05.912 -05:00 [Fatal] Unhandled application error: System.UnauthorizedAccessException: Access to the path '/usr/share/Camelot/Camelot.db' is denied.
---> System.IO.IOException: Permission denied
--- End of inner exception stack trace ---
at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirectory, Func2 errorRewriter) at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String path, OpenFlags flags, Int32 mode) at System.IO.FileStream.OpenHandle(FileMode mode, FileShare share, FileOptions options) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options) at LiteDB.Engine.FileStreamFactory.GetStream(Boolean canWrite, Boolean sequencial) at LiteDB.Engine.StreamPool.<>c__DisplayClass3_0.<.ctor>b__0() at System.Lazy1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor) at System.Lazy1.CreateValue()
at System.Lazy1.get_Value() at LiteDB.Engine.StreamPool.get_Writer() at LiteDB.Engine.DiskService..ctor(EngineSettings settings, Int32[] memorySegmentSizes) at LiteDB.Engine.LiteEngine..ctor(EngineSettings settings) at LiteDB.SharedEngine.OpenDatabase() at LiteDB.SharedEngine.Query(String collection, Query query) at LiteDB.LiteQueryable1.ToDocuments()+MoveNext()
at System.Linq.Enumerable.SelectEnumerableIterator2.MoveNext() at System.Linq.Enumerable.TryGetFirst[TSource](IEnumerable1 source, Boolean& found)
at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable1 source) at LiteDB.LiteCollection1.FindById(BsonValue id)
at Camelot.DataAccess.LiteDb.Repository1.GetById(String id) in /home/ingvar/Code/Camelot/src/Camelot.DataAccess.LiteDb/Repository.cs:line 15 at Camelot.Services.LocalizationService.GetSavedLanguage() in /home/ingvar/Code/Camelot/src/Camelot.Services/LocalizationService.cs:line 23 at Camelot.App.LoadLanguage() in /home/ingvar/Code/Camelot/src/Camelot/App.xaml.cs:line 43 at Camelot.App.Initialize() in /home/ingvar/Code/Camelot/src/Camelot/App.xaml.cs:line 20 at Avalonia.Controls.AppBuilderBase1.Setup()
at Avalonia.Controls.AppBuilderBase`1.SetupWithLifetime(IApplicationLifetime lifetime)
at Avalonia.ClassicDesktopStyleApplicationLifetimeExtensions.StartWithClassicDesktopLifetime[T](T builder, String[] args, ShutdownMode shutdownMode)
at Camelot.Program.Main(String[] args) in /home/ingvar/Code/Camelot/src/Camelot/Program.cs:line 32
----------end CamelotLog-20201219.txt--------------

Hello, looks like there is no access to /usr/share/Camelot/. Should work with sudo (or you can temporarily add access to this directory). Note that Debian package is experimental, I gonna fix this issue in next (0.2.1) version

OK, Thx!

Please try this one:
camelot_0.2.0.deb.zip

Please try this one:
camelot_0.2.0.deb.zip

OK, downloading now. (D/L is slow today). While that's going, I recall noticing that GDebi did not display any errors in red like it usually does. The install just appeared to do nothing. (In fact, it was mostly installed, just possibly incomplete.) Anyway, usually when GDebi is done, it enabled an Uninstall button, which it did not do. And apt did not find it to uninstall, so I manually removed the Camelot folder under /usr/share.
My thought is that the install is not returning some code or result that GDebi looks for. Don't know if you have any ideas, but thought I'd share that.
Still downloading, will update you when I've tried again.

OK, success.
running... (type 'camelot' from CLI)

Glad it helped! I pushed fix to master branch and will include it in next release.

My thought is that the install is not returning some code or result that GDebi looks for. Don't know if you have any ideas, but thought I'd share that.

I don't know how GDebi works but package still could have some uninstallation issues I think. Packaging dotnet apps is not that easy 😄 I will investigate that