I have installed agda using cabal. I have created a file name Trial.agda in the directory /media/arkaghosh/Important5/programs/Agda with the following content inside it
module Trial where
open import Data.Nat
But when I try to compile it using
agda -c Trial.agda
I get the following error
Failed to find source of module Data.Nat in any of the following
locations:
/media/arkaghosh/Important5/programs/Agda/Data/Nat.agda
/media/arkaghosh/Important5/programs/Agda/Data/Nat.lagda
/home/arkaghosh/.cabal/share/x86_64-linux-ghc-7.10.3/Agda-2.6.0.1/lib/prim/Data/Nat.agda
/home/arkaghosh/.cabal/share/x86_64-linux-ghc-7.10.3/Agda-2.6.0.1/lib/prim/Data/Nat.lagda
when scope checking the declaration
open import Data.Nat
I have seen this question which is similar to mine
Agda: Can't find std-lib when installing with Stack
. But I am unable use the answer to solve my problem.
Related
I tried "stack install megaparsec", adding megaparsec and parsec as a dependency in the project.yaml file and running stack build, i tried stack build on all levels of the project folder. Also what's weird is that I can load the module which contains the imports which are marked as problems by VSCode and show the error message and I can also run the functions in said module which make us of the imported stuff but I can't compile the file.
ghci version is 9.0.1
stack version is 2.7.3
cabal-version: 1.12
Error message from terminal
module Parsing where
import Control.Monad (void)
import Data.Void
import Syntax
import Data.Text (Text)
vvvvv these 3 are marked as problems and are the reason I can't compile the file.
import Text.Megaparsec
import Text.Megaparsec.Char
import qualified Text.Megaparsec.Char.Lexer as L
.cabal file
library
exposed-modules:
Example
Lib
Parsing
Print
Semantics
Syntax
other-modules:
Paths_parser
hs-source-dirs:
src
build-depends:
base >=4.7 && <5
, containers
, megaparsec
, parsec
, text
default-language: Haskell2010
executable parser-exe
main-is: Main.hs
other-modules:
Paths_parser
hs-source-dirs:
app
ghc-options: -threaded -rtsopts -with-rtsopts=-N
build-depends:
base >=4.7 && <5
, parser
default-language: Haskell2010
test-suite parser-test
type: exitcode-stdio-1.0
main-is: Spec.hs
other-modules:
Paths_parser
hs-source-dirs:
test
ghc-options: -threaded -rtsopts -with-rtsopts=-N
build-depends:
base >=4.7 && <5
, parser
default-language: Haskell2010
I am trying to run Python Code on Spyder for scientific computing. I use geometric information from shape files using geopandas. Installing geopandas was already difficult but I finally managed. However now I have another issue, that a module called 'pyproj._network' is not found.
I checked and the module is there and was also added to the path using the PYTHONPATH manager of Spyder.
Now I dont know anymore- any help very much appreciated!
Thanks!
`ModuleNotFoundError: No module named 'pyproj._network'
Entering post mortem debugging...
c:\users\stefano-work\miniconda3\lib\site-packages\pyproj\network.py(10)()
8 import certifi
9
---> 10 from pyproj._network import ( # noqa: F401
11 _set_ca_bundle_path,
12 is_network_enabled,
`
I'm trying to use this library https://github.com/dom96/nim-opencv a wrapper for OpenCV.
After running nimble install opencv
I can see the package in ~/.nimble/pkgs/opencv-0.1.0/
But when attempting to use I get a compile error
Error: cannot open 'opencv/highgui'
import opencv/highgui
const fileName = "g.jpg"
let img_colr = loadImage(fileName, 1)
echo img_colr.width
echo img_colr.height
Not sure what the problem is something to do with Nim import paths?...
Are you compiling with nimble or nim? If the former then make sure you've got requires "opencv" in your .nimble file.
Where need I to set the path to the protoc to get import standards Protocol Buffers (protobuf), like empty.proto and timestamp.proto in Windows and Dart?
When the protoc is ran:
protoc --dart_out=grpc:lib/src/protos/generated -Iprotos
protos/organization.proto
--plugin=protoc-gen-dart=D:\Users\Samuel\AppData\Roaming\Pub\Cache\bin\protoc-gen-dart.bat
The following error is presented:
google/protobuf/empty.proto: File not found. organization.proto:
Import "google/protobuf/empty.proto" was not found or had errors.
organization.proto:14:27: "google.protobuf.Empty" is not defined.
In IntelliJ Settings on Protobuf Support plugin the path is define where standard protos (*.proto) are:
Additionally this path is define in IntelliJ on Project Structure \ Global Libraries:
The code organization.proto that import google/protobuf/empty.proto to use Empty class :
syntax = "proto3";
package auge.protobuf;
import "google/protobuf/empty.proto";
service OrganizationService {
rpc GetOrganizations (google.protobuf.Empty) returns (OrganizationsResponse) {}
}
IntelliJ analyzer recognizes the import "google/protobuf/empty.proto" and Empty class on IDEA, but protoc can not find.
The environment is:
SO: Windows 7 x64
protoc: libprotoc 3.6.1
Dart: 2.2.0-edge
Say you have /some/path/to/google/protobuf/empty.proto, you need to pass --proto_path=/some/path/to/ so protoc can locate it.
use two dot before protobuf folder path
<Protobuf Include="..\Proto\protobuf.proto" ProtoRoot="Proto" />
I've follow the instructions for dart libsass at:
https://github.com/oddrationale/dart_libsass
The compile step completes correctly. However - when i try and execute sassd.dart i get the following:
dart bin/sassd.dart ~/projects/web_apps_dart/lib/client/components/picker/picker.scss ~/Desktop/test.css
Cannot find extension library'package:libsass/libsass.dart': error: line 10 pos 1: library handler failed
import 'dart-ext:libsass/src/sass_extension';
^
Cannot find initialization function in extension'package:libsass/libsass.dart': error: line 10 pos 1: library handler failed
import 'dart-ext:sass_extension';
^
sass_extension.cc exists at ~/lib/src/sass_extension.cc
Question: How do we correctly import the sass_extions.cc file in recent builds of Dart?
I'm the author/maintainer of dart_libsass.
I got your bug report on GitHub and resolved the issue there. The issue was with the build script not the sass_extension.cc file itself. If you have any other issues, let's continue the discussion on the GitHub issues page. Thanks!