Swift is very new for me. I have a swift project that builds fine in xcode and all the unit tests pass.
However when I run pod lib lint I get a no such module MyModule error.
Testing with xcodebuild.
-> my-swift-project (0.4.2)
- WARN | source: Git SSH URLs will NOT work for people behind firewalls configured to only allow HTTP, therefore HTTPS is preferred.
- ERROR | [iOS] xcodebuild: Returned an unsuccessful exit code.
- ERROR | [iOS] xcodebuild: my-swift-project/Echo/Delegates/MyModule/MyModule.swift:7:8: error: no such module 'MyModule'
The file in question has an import module declaration at the top of the file
import MyModule
Would anyone know why this would be happening and why the project builds in xcode fine but not when I get to this stage?
build settings > Framework Search Paths
Set framework search path to $(SRCROOT) and recursive.
Related
I have installed Robocorp Code as well as Robot Framework Language Server and have configured them. However, I am still having errors when trying to run the tests via the code lens options.
Repo - A webapi repo with a specific folder containing all tests. Lets call it regression.
RF - 4.1.3
Python - 3.8
This is what happens when I click on Run on the code lens for any of the tests -
`PS C:\git\xxxx\regression> C:; cd 'C:\git\xxxx\regression'; &
'C:\Users\xxxx\AppData\Local\Temp\rf-ls-run\run_env_00_smh5defr.bat'
'-u'
'c:\Users\xxxx.vscode\extensions\robocorp.robotframework-lsp-0.47.2\src\robotframework_debug_adapter\run_robot__main__.py'
'--port' '54331' '--no-debug' '--argumentfile'
'C:\git\xxxx\regression\args-local.txt' '--pythonpath'
'c:\git\xxxx\regression\common\lib' '--variable'
'EXECDIR:C:/git/xxxx/regression'
'--prerunmodifier=robotframework_debug_adapter.prerun_modifiers.FilteringTestsSuiteVisitor'
'c:\git\xxxx\regression\api\api_Test.robot'
[ ERROR ] Parsing'--pythonpath' failed: File or directory to execute does not exist.
However, the test starts if I remove the argumentfile parameter but it, of course, fails because its missing arguments from the file.
Do note that the folder specified in pythopath exists and has some python libraries needed for the tests.
While trying to troubleshoot another issue with my project, I must've broken something along the way, but I have no idea how to fix this.
These are my import statements for the project:
pragma solidity >=0.6.6;
import "#openzeppelin/contracts/token/ERC721/ERC721.sol";
import "#chainlink/contracts/src/v0.6/VRFConsumerBase.sol";
And this is my brownie-config.yaml
depencencies:
- OpenZeppelin/openzeppelin-contracts#3.4.0
- smartcontractkit/chainlink-brownie-contracts#1.0.2
compiler:
solc:
remappings:
- '#openzeppelin=OpenZeppelin/openzeppelin-contracts#3.4.0'
- '#chainlink=smartcontractkit/chainlink-brownie-contracts#1.0.2'
But despite all this working until yesterday, trying to compile only gives me these errors:
PS C:\Users\XXX\Desktop\Project> brownie compile
INFO: Could not find files for the given pattern(s).
Brownie v1.16.4 - Python development framework for Ethereum
New compatible solc version available: 0.6.6
Compiling contracts...
Solc version: 0.6.6
Optimizer: Enabled Runs: 200
EVM Version: Istanbul
CompilerError: solc returned the following errors:
contracts/AdvancedCollectible.sol:3:1: ParserError: Source "OpenZeppelin/openzeppelin-contracts#3.4.0/contracts/token/ERC721/ERC721.sol" not found: File not found.
import "#openzeppelin/contracts/token/ERC721/ERC721.sol";
^-------------------------------------------------------^
contracts/AdvancedCollectible.sol:4:1: ParserError: Source "smartcontractkit/chainlink-brownie-contracts#1.0.2/contracts/src/v0.6/VRFConsumerBase.sol" not found: File not found.
import "#chainlink/contracts/src/v0.6/VRFConsumerBase.sol";
^---------------------------------------------------------^
How do I solve this?
I've seen some answers to similar issues referencing node.js or local copies of the stuff I'm trying to import, but isn't this command supposed to pull stuff off github?
Why is it failing to do so out of nowhere?
Install Openzeppelin at the root of your folder by using npm
npm i #openzeppelin/contracts
same thing for Chainlink
This is because the solidity extension is looking in the wrong directory.
Below step fixed the issue for me -
Change the settings in Solidity extension in VSCode.
The default settings include: "solidity.packageDefaultDependenciesContractsDirectory": "contracts" Users need to change the setting from contracts to an empty string. "solidity.packageDefaultDependenciesContractsDirectory": ""
Source - https://github.com/juanfranblanco/vscode-solidity/issues/178
I'm a newbie in Istio and I’m trying to build the Istio source locally in mac but somehow when I run "make build" I get the following errors.
...
Downloading envoy: https://storage.googleapis.com/istio-build/proxy/envoy-alpha-74393cf764c167b545f32eb895314e624186e5b6.tar.gz to
real 0m5.288s
user 0m0.707s
sys 0m0.685s
cp: cannot create regular file '': No such file or directory
Unexpected failure
make[1]: *** [Makefile.core.mk:230: /work/out/darwin_amd64/istio_is_init] Error 1
...
These are the following env variables that I have set.
export HUB="docker.io/shriramsharma"
export TAG="shriramsharma"
export GOOS=darwin
export USE_LOCAL_PROXY=1
export BUILD_WITH_CONTAINER=1
Is there something I’m missing? any help would be appreciated
Version: I ran make build on the master branch of the source. I did not checkout any release version tag.
Docs: I followed the steps in the docs here. https://github.com/istio/istio/wiki/Preparing-for-Development-Mac
I have a workspace with multiple targets and mixed development with SWIFT and Objective-C. After installing CocoaLumberjack with CocoaPods:
pod 'CocoaLumberjack/Swift'
I can use it my project without any problems. All my targets get compiled except Test target. When I run tests I get "build failed" error within the bridging header file
<CocoaLumberjack/CocoaLumberjack.h> file not found
at:
#import <CocoaLumberjack/CocoaLumberjack.h>
Do you have any ideas how to fix the issue? Thanks!
I'm having an issue with CocoaPods and it finding interface files in my project. The root of the problem is:
- ERROR | [xcodebuild] ios-etsy-sdk/ios-etsy-sdk/SOSEtsyShopResult.h:22:32: error: cannot find interface declaration for 'SOSEtsyResult', superclass of 'SOSEtsyShopResult'
- NOTE | [xcodebuild] ios-etsy-sdk/ios-etsy-sdk/SOSEtsyShopResult.h:22:12: warning: class 'SOSEtsyShopResult' defined without specifying a base class [-Wobjc-root-class]
- NOTE | [xcodebuild] ios-etsy-sdk/ios-etsy-sdk/SOSEtsyShopResult.h:22:29: note: add a super class to fix this problem
The full output from running the CocoaPods linter is available at https://gist.github.com/seanoshea/5631517. When I look at the /tmp/CocoaPods/Lint directory on my machine, SOSEtsyResult is available.
https://github.com/seanoshea/ios-etsy-sdk/blob/master/ios-etsy-sdk/SOSEtsyShopResult.h is the .h file in question and it inherits from https://github.com/seanoshea/ios-etsy-sdk/blob/master/ios-etsy-sdk/SOSEtsyResult.h, so I'm not sure why the compilation fails when I run the linter.
Any ideas on this?
Sean
This is most likely because you're expecting cocoapods to pull in the PCH file and to turn that into the PCH file for all of the libraries. Which it does not do ( ideally we don't want to pollute user pchs )
Nothing says a real answer like a pull request though.