I am trying to create a new MVC application with Oracle DB as backend with DB Option 4(Others).
julia> Genie.newapp_mvc("WatchTonight")
But, getting the following error:
┌ Error: Pkg.Types.PkgError("The following package names could not be resolved:\n * SearchLightOracle (not found in project, manifest or registry)\n")
I tried to install package SearchLightOracle.
But, package not found:
(WatchTonight) pkg> add SearchLightOracle
ERROR: The following package names could not be resolved:
* SearchLightOracle (not found in project, manifest or registry)
Please guide me in creating Genie web app with Oracle DB as backend.
full logs:
[root#srvr0 ~]# julia
_
_ _ _(_)_ | Documentation: https://docs.julialang.org
(_) | (_) (_) |
_ _ _| |_ __ _ | Type "?" for help, "]?" for Pkg help.
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 1.6.4 (2021-11-19)
_/ |\__'_|_|_|\__'_| | Official https://julialang.org/ release
|__/ |
julia> using Genie
julia> Genie.newapp_mvc("WatchTonight")
Updating registry at `~/.julia/registries/General`
Resolving package versions...
No Changes to `~/.julia/environments/v1.6/Project.toml`
No Changes to `~/.julia/environments/v1.6/Manifest.toml`
Please choose the DB backend you want to use:
1. SQLite
2. MySQL
3. PostgreSQL
4. Other
Input 1, 2, 3 or 4 and press ENTER to confirm
4
Please input DB adapter (ex: Oracle, ODBC, JDBC, etc)
Oracle
Activating environment at `~/Project.toml`
┌ Error: Pkg.Types.PkgError("The following package names could not be resolved:\n * SearchLightOracle (not found in project, manifest or registry)\n")
└ # Genie.Generator ~/.julia/packages/Genie/fMBsZ/src/Generator.jl:503
[ Info: Done! New app created at /root/WatchTonight
[ Info: Changing active directory to /root/WatchTonight
/tmp/jl_Z2oGzp/WatchTonight/Project.toml
[ Info: Project.toml has been generated
[ Info: Installing app dependencies
Activating environment at `~/WatchTonight/Project.toml`
Resolving package versions...
Installed Crayons ────────── v4.1.0
Installed LoweredCodeUtils ─ v2.2.0
Installed JuliaInterpreter ─ v0.9.0
Installed Revise ─────────── v3.3.1
Updating `~/WatchTonight/Project.toml`
[c43c736e] + Genie v4.7.1
[6d011eab] + Inflector v1.0.1
[e6f89c97] + LoggingExtras v0.4.7
[739be429] + MbedTLS v1.0.3
[ade2ca70] + Dates
[56ddb016] + Logging
Updating `~/WatchTonight/Manifest.toml`
[c7e460c6] + ArgParse v1.1.4
[00ebfdb7] + CSTParser v3.3.0
[da1fd8a2] + CodeTracking v1.0.6
[a80b9123] + CommonMark v0.8.5
[34da2185] + Compat v3.41.0
[a8cc5b0e] + Crayons v4.1.0
[864edb3b] + DataStructures v0.18.11
[8f5d6c58] + EzXML v1.1.0
[48062228] + FilePathsBase v0.9.17
[c43c736e] + Genie v4.7.1
[cd3eb016] + HTTP v0.9.17
[77172c1b] + HttpCommon v0.5.0
[6d011eab] + Inflector v1.0.1
[83e8ac13] + IniFile v0.5.0
[692b3bcd] + JLLWrappers v1.3.0
[682c06a0] + JSON v0.21.2
[0f8b85d8] + JSON3 v1.9.2
[98e50ef6] + JuliaFormatter v0.20.5
[aa1ae85d] + JuliaInterpreter v0.9.0
[e6f89c97] + LoggingExtras v0.4.7
[6f1432cf] + LoweredCodeUtils v2.2.0
[739be429] + MbedTLS v1.0.3
[39ec1447] + Millboard v0.2.5
[49dea1ee] + Nettle v0.5.1
[4d1e1d77] + Nullables v1.0.0
[bac558e1] + OrderedCollections v1.4.1
[69de0a69] + Parsers v2.1.3
[21216c6a] + Preferences v1.2.3
[92933f4c] + ProgressMeter v1.7.1
[189a3867] + Reexport v1.2.2
[ae029012] + Requires v1.2.0
[295af30f] + Revise v3.3.1
[6c6a2e73] + Scratch v1.1.0
[69024149] + StringEncodings v0.3.5
[856f2bd8] + StructTypes v1.8.1
[b718987f] + TextWrap v1.0.1
[0796e94c] + Tokenize v0.5.21
[30578b45] + URIParser v0.4.1
[5c2747f8] + URIs v1.3.0
[856ac37a] + UrlDownload v1.0.0
[a637dc6b] + VersionCheck v0.2.0
[ddb6d928] + YAML v0.4.7
[94ce4f54] + Libiconv_jll v1.16.1+1
[4c82536e] + Nettle_jll v3.7.2+0
[02c8fc9c] + XML2_jll v2.9.12+0
[0dad84c5] + ArgTools
[56f22d72] + Artifacts
[2a0f44e3] + Base64
[ade2ca70] + Dates
[8bb1440f] + DelimitedFiles
[8ba89e20] + Distributed
[f43a241f] + Downloads
[7b1f6079] + FileWatching
[b77e0a4c] + InteractiveUtils
[b27032c2] + LibCURL
[76f85450] + LibGit2
[8f399da3] + Libdl
[37e2e46d] + LinearAlgebra
[56ddb016] + Logging
[d6f4376e] + Markdown
[a63ad114] + Mmap
[ca575930] + NetworkOptions
[44cfe95a] + Pkg
[de0858da] + Printf
[3fa0cd96] + REPL
[9a3f8284] + Random
[ea8e919c] + SHA
[9e88b42a] + Serialization
[1a1011a3] + SharedArrays
[6462fe0b] + Sockets
[2f01184e] + SparseArrays
[10745b16] + Statistics
[fa267f1f] + TOML
[a4e569a6] + Tar
[8dfed614] + Test
[cf7118a7] + UUIDs
[4ec0a83e] + Unicode
[781609d7] + GMP_jll
[deac9b47] + LibCURL_jll
[29816b5a] + LibSSH2_jll
[c8ffd9c3] + MbedTLS_jll
[14a3606d] + MozillaCACerts_jll
[83775a58] + Zlib_jll
[8e850ede] + nghttp2_jll
[3f19e933] + p7zip_jll
Precompiling project...
✓ JuliaInterpreter
✓ Crayons
✓ CommonMark
✓ LoweredCodeUtils
✓ JuliaFormatter
✓ Revise
✓ Genie
9 dependencies successfully precompiled in 120 seconds (41 already precompiled)
7 dependencies precompiled but different versions are currently loaded. Restart julia to access the new versions
Resolving package versions...
Updating `~/WatchTonight/Project.toml`
[340e8cb6] + SearchLight v2.0.1
Updating `~/WatchTonight/Manifest.toml`
[9a962f9c] + DataAPI v1.9.0
[a93c6f00] + DataFrames v1.3.1
[e2d170a0] + DataValueInterfaces v1.0.0
[59287772] + Formatting v0.4.2
[41ab1584] + InvertedIndices v1.1.0
[82899510] + IteratorInterfaceExtensions v1.0.0
[e1d29d7a] + Missings v1.0.2
[2dfb63ee] + PooledArrays v1.4.0
[08abe8d2] + PrettyTables v1.3.1
[340e8cb6] + SearchLight v2.0.1
[a2af1166] + SortingAlgorithms v1.0.1
[3783bdb8] + TableTraits v1.0.1
[bd369af6] + Tables v1.6.1
[9fa8497b] + Future
Precompiling project...
✓ LoweredCodeUtils
✓ JuliaFormatter
✓ Revise
✓ Genie
6 dependencies successfully precompiled in 105 seconds (57 already precompiled)
4 dependencies precompiled but different versions are currently loaded. Restart julia to access the new versions
Please choose the DB backend you want to use:
1. SQLite
2. MySQL
3. PostgreSQL
4. Other
Input 1, 2, 3 or 4 and press ENTER to confirm
4
Please input DB adapter (ex: Oracle, ODBC, JDBC, etc)
Oracle
Activating environment at `~/WatchTonight/Project.toml`
┌ Error: Pkg.Types.PkgError("The following package names could not be resolved:\n * SearchLightOracle (not found in project, manifest or registry)\n")
└ # Genie.Generator ~/.julia/packages/Genie/fMBsZ/src/Generator.jl:503
[ Info: Installing dependencies for unit tests
Activating new environment at `~/WatchTonight/test/Project.toml`
Resolving package versions...
Updating `~/WatchTonight/test/Project.toml`
[8dfed614] + Test
Updating `~/WatchTonight/test/Manifest.toml`
[2a0f44e3] + Base64
[b77e0a4c] + InteractiveUtils
[56ddb016] + Logging
[d6f4376e] + Markdown
[9a3f8284] + Random
[9e88b42a] + Serialization
[8dfed614] + Test
Activating environment at `~/WatchTonight/Project.toml`
[ Info: Starting your brand new Genie app - hang tight!
[ Info: Precompiling WatchTonight [93f46181-df21-4b6e-b7cd-33e5e979776f]
_____ _
| __|___ ___|_|___
| | | -_| | | -_|
|_____|___|_|_|_|___|
| Web: https://genieframework.com
| GitHub: https://github.com/genieframework/Genie.jl
| Docs: https://genieframework.github.io/Genie.jl/dev
| Gitter: https://gitter.im/essenciary/Genie.jl
| Twitter: https://twitter.com/GenieMVC
Active env: DEV
Ready!
┌ Info: 2022-01-06 10:38:26
└ Web Server starting at http://127.0.0.1:8000
julia>
The reason you cannot add the project is that it is not a registered package. To add a non-registered package, you need to do:
] add https://github.com/FrankUrbach/SearchLightOracle.jl.git
However, I will note that https://github.com/FrankUrbach/SearchLightOracle.jl does not look like it is being actively maintained. I opened an issue here: https://github.com/FrankUrbach/SearchLightOracle.jl/issues/6 for Frank to comment on the state of the project.
You might be able to build off of the existing project by reading the docs: https://github.com/FrankUrbach/SearchLightOracle.jl/blob/master/docs/src/index.md as it appears some functions are working.
Related
Building Yew App on Windows
I'm building a yew app alongside a rocket backend on Windows following
this tutorial
(although the tutorial is for a Linux environment). I'm trying to build the yew app
using wasm-pack. I'm not using the Linux subsystem to build the app, though
I do have it installed.
Code / Configuration
The repository.
I have already installed the wasm toolchain and cargo make:
rustup target add wasm32-unknown-unknown
The following is my toolchain list:
stable-x86_64-pc-windows-gnu
stable-x86_64-pc-windows-msvc
nightly-x86_64-pc-windows-msvc (default)
1.30.0-x86_64-pc-windows-msvc
Here is my folder structure:
Project root
├───backend <-- rocket backend
| ├───Cargo.toml
│ └───src
│ ├───bin
│ └───db
├───frontend <-- yew frontend
│ ├───pkg
│ ├───src
| ├───Cargo.toml
| └───Makefile.toml
├───src
├───Cargo.toml
└───Makefile.toml
This is rootdir\Cargo.toml:
[package]
name = "sentinel"
version = "0.1.0"
authors = ["zachdelano <email>"]
edition = "2018"
[workspace]
members = ["backend", "frontend"]
This is rootdir\Makefile.toml:
[env]
CARGO_MAKE_EXTEND_WORKSPACE_MAKEFILE = "true"
[tasks.default]
clear = true
dependencies = ["build"]
This is rootdir\frontend\Cargo.toml:
[dependencies]
sentinel = { path = ".." }
yew = "0.17.3"
wasm-pack = "0.9.1"
wasm-bindgen = "0.2.68"
web-sys = "0.3.45"
[lib]
crate-type = ["cdylib", "rlib"]
This is rootdir\frontend\Makefile.toml:
[tasks.default]
dependencies = ["create_wasm"]
[tasks.create_wasm]
command = "wasm-pack"
args = ["build", "--target", "web", "--out-name", "package", "--dev"]
dependencies = ["build"]
Expected result
I expect the app to finish building with no errors when I run
cargo make. The Yew tutorial
seems to indicate nothing else is needed.
Actual output
I get a host of errors when running cargo make (from the root directory) like the following:
error[E0433]: failed to resolve: could not find `unix` in `os`
--> C:\Users\Zach\.cargo\registry\src\github.com-1ecc6299db9ec823\dirs-1.0.5\src\lin.rs:41:18
|
41 | use std::os::unix::ffi::OsStringExt;
| ^^^^ could not find `unix` in `os`
See the entire list of errors.
Is this a toolchain sort of thing? How can I fix this?
Running rustup update
I get the following output
from running rustup update.
Now when I run cargo make from the root directory, I get different errors:
error[E0432]: unresolved import `crate::sys`
--> C:\Users\Zach\.cargo\registry\src\github.com-1ecc6299db9ec823\socket2-0.3.15\src\socket.rs:23:5
|
23 | use crate::sys;
| ^^^^^^^^^^ no `sys` in the root
See the full list of errors.
Some of the code changed in the repository.
The issue ended up being that I was trying to install wasm-pack and web-sys. I don't know why that was an issue but when I commented them out and ran cargo make, everything built just fine. I also deleted target and reran cargo make just to make sure.
[package]
name = "frontend"
version = "0.1.0"
authors = ["zachdelano <email>"]
edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
sentinel = { path = ".." }
yew = "0.17.3"
wasm-bindgen = "0.2.68"
# wasm-pack = "0.9.1"
# web-sys = "0.3.45"
[lib]
crate-type = ["cdylib", "rlib"]
Title says it all.
Is it possible to reverse-engineer pom.xml dependencies given a lib folder full of jars?
i.e. Discover the publicly available Maven artifacts given a jar name and/or SHA1 checksum.
Here's a naive attempt which didn't work very well, because the search often returns too many matches:
#!/usr/bin/python
# Mavenize a lib folder, converting jars into dependencies
import os
import sys
import urllib2
import json
for file in os.listdir(sys.argv[1]):
url = "http://search.maven.org/solrsearch/select?rows=1&wt=json&q=" + file
response = urllib2.urlopen(url)
jsonStr = response.read()
jsonObj = json.loads(jsonStr)
if(jsonObj["response"]["numFound"] > 0):
print "<dependency><!-- for " + file + "-->"
print " <groupId>" + jsonObj["response"]["docs"][0]["g"] + "</groupId>"
print " <artifactId>" + jsonObj["response"]["docs"][0]["a"] + "</artifactId>"
print " <version>" + jsonObj["response"]["docs"][0]["latestVersion"] + "</version>"
print "</dependency>"
If those jar files produced by maven then yes it is possible. In other case it is not possible without extra step like trying to find group id and version from mvnrepository etc.
I downloaded the fhir server from http://www.healthintersections.com.au/FhirServer/.
When I run the server with the following command "fhirserver –debug" I get following error:
2015-11-27--------------------------------
12:41:17 FHIR Service 1.0.2 (DSTU2). Using ini file c:\Program Files\FHIRServer\fhirserver.ini with stack dumps on
12:41:17 Using FHIR Specification at C:\Program Files\FHIRServer\spec
12:41:17 Database mssql://xx.xx.xx.xx/fhir
12:41:17 Load DB Terminologies
12:41:17 - done
12:41:17 Load Loinc from C:\ProgramData\FHIRServer\loinc.cache
12:41:17 - done
12:41:17 Load User Sub-system
12:41:17 Load & Cache Store:
12:41:19 Load Validation Pack from C:\Program Files\FHIRServer\spec\validation-min.xml.zip
12:41:24 EAccessViolation: Access violation at address 00000000010895D3 in module 'FHIRServer.exe'. Read of address 0000000000000038
(0000000000C885D3){FHIRServer.exe} [00000000010895D3] UcumServices.TUcumServices.SetCommonUnits + $13
(0000000000040DEB){FHIRServer.exe} [0000000000441DEB] System.SysUtils.GetExceptionObject + $EB
(00000000002032C7){FHIRServer.exe} [00000000006042C7] JclHookExcept.DoExceptFilter + $E7
(0000000000203595){FHIRServer.exe} [0000000000604595] JclHookExcept.HookedExceptObjProc + $15
(000000000000F429){FHIRServer.exe} [0000000000410429] System.#DelphiExceptionHandler + $289
(000000000002805D){ntdll.dll } [000000007785905D] Unknown function at RtlDecodePointer + $AD
(0000000000017C0F){ntdll.dll } [0000000077848C0F] Unknown function at RtlUnwindEx + $BBF
(000000000004C948){ntdll.dll } [000000007787D948] KiUserExceptionDispatcher + $2E
(0000000000C885D3){FHIRServer.exe} [00000000010895D3] UcumServices.TUcumServices.SetCommonUnits + $13
(0000000000CB1B3B){FHIRServer.exe} [00000000010B2B3B] TerminologyServerStore.TTerminologyServerStore.SeeSpecificationResource + $15B
(0000000000E27058){FHIRServer.exe} [0000000001228058] ServerValidator.TFHIRServerValidatorContext.SeeResource + $58
(0000000000ADF007){FHIRServer.exe} [0000000000EE0007] FHIRProfileUtilities.TValidatorServiceProvider.Load + $67
(0000000000ADE650){FHIRServer.exe} [0000000000EDF650] FHIRProfileUtilities.TValidatorServiceProvider.LoadFromDefinitions + $2C0
(0000000000EED84B){FHIRServer.exe} [00000000012EE84B] FHIRDataStore.TFHIRDataStore.Create + $14BB
(0000000000F1E89C){FHIRServer.exe} [000000000131F89C] FHIRRestServer.TFhirWebServer.Create + $9FC
(0000000000F47699){FHIRServer.exe} [0000000001348699] FHIRServerApplicationCore.TFHIRService.InitialiseRestServer + $49
(0000000000F45B01){FHIRServer.exe} [0000000001346B01] FHIRServerApplicationCore.TFHIRService.CanStart + $81
(000000000025B32E){FHIRServer.exe} [000000000065C32E] SystemService.TSystemService.InternalExecute + $6E
(000000000025AFFF){FHIRServer.exe} [000000000065BFFF] SystemService.TSystemService.DebugExecute + $4F
(000000000025BCD5){FHIRServer.exe} [000000000065CCD5] SystemService.TSystemService.Execute + $1F5
(0000000000F45131){FHIRServer.exe} [0000000001346131] FHIRServerApplicationCore.ExecuteFhirServer + $B31
(0000000000F63F55){FHIRServer.exe} [0000000001364F55] FHIRServerDev.FHIRServerDev + $75
(0000000000014A4D){kernel32.dll} [0000000077725A4D] BaseThreadInitThunk + $D
(000000000002A831){ntdll.dll } [000000007785B831] RtlUserThreadStart + $21
12:41:24 Exception in Service Execution:
Access violation at address 00000000010895D3 in module 'FHIRServer.exe'. Read of address 0000000000000038
[EAccessViolation]
Ucum is not configured in the ini fil at c:\Program Files\FHIRServer\fhirserver.ini.
[ucum]
source=C:\work\fhirserver\Exec\ucum-essence.xml
where ucum-essence.xml is from http://unitsofmeasure.org
And so, I'm using sublime text 3 and I don't know on how to install the plugin Sublime Text plugin for Laravel 4 Artisan. It says in Installation tab that Use Package Controller or create a the directory Laravel 4 Artisan in your Sublime Text Packages directory with source code, and you're ready to go. So what to do now? I don't get it. Please help.
First If you don't have Package Control Install it ctrl+` and paste this:
For SUBLIME 3
import urllib.request,os,hashlib; h = 'eb2297e1a458f27d836c04bb0cbaf282' + 'd0e7a3098092775ccb37ca9d6b2e4b7d'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path(); urllib.request.install_opener( urllib.request.build_opener( urllib.request.ProxyHandler()) ); by = urllib.request.urlopen( 'http://packagecontrol.io/' + pf.replace(' ', '%20')).read(); dh = hashlib.sha256(by).hexdigest(); print('Error validating download (got %s instead of %s), please try manual install' % (dh, h)) if dh != h else open(os.path.join( ipp, pf), 'wb' ).write(by)
After that you can use Package control with:
⇧ + ⌘ + P and write install and select Package control.
It opens other field to write, in this write Laravel and choose Laravel 4 Artisan and wait to finish the installation.
So when you finish the process you can use that plugin to create controllers and models.
I'm getting an error that doesn't really make much sense. This is the part of my Cakefile that does the coffee compilation:
buildsrc: ->
stitch = require 'stitch'
fs = require 'fs'
# Create stitch package
pkg = stitch.createPackage
paths: [__dirname + '/src']
dependencies: [
__dirname + '/vendor/jquery-1.7.1.min.js'
__dirname + '/vendor/jquery-ui-1.8.18.min.js'
__dirname + '/vendor/jquery.cookie.js'
__dirname + '/vendor/jquery.iframe-transport.js'
__dirname + '/vendor/jquery.fileupload.js'
]
# Compile the package
pkg.compile (err, src)->
if err
console.warn 'Coffee compile failed:'
console.warn err.toString()
else
# Save the source code
fs.writeFile BUILD_JS_PATH, src, (err)->
if err then throw err
console.log 'Compiled src to ' + BUILD_JS_PATH
And the output from running that (shortened path):
Coffee compile failed:
Error: C:\Users\Codemonkey\...\project\src\foo.coffee isn't in the require path
This worked wonderfully on Linux with the same code and the same node-, stitch- and coffee-script versions. I can see that the error is thrown in stitch.coffee:177, but I can't figure out what it means, if it's my fault or how to fix it.
Thanks for your help!
Yeah it was a directory separator issue with Windows - I found an un-pulled pull-request that fixes the issue - https://github.com/sstephenson/stitch/pull/34