Skip to content

Commit 29e7048

Browse files
authored
Merge pull request #64 from unstoppabledomains/johnny/ensRemoval
remove ens support
2 parents 7688034 + 258ca05 commit 29e7048

File tree

14 files changed

+18
-1016
lines changed

14 files changed

+18
-1016
lines changed

CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Resolution-swift CHANGELOG
22

3+
## 4.0.0
4+
5+
### Breaking changes
6+
- ENS support has been removed.
7+
- Library configurations has been changed and all ens mentions have been removed.
8+
39
## 3.0.0
410

511
### Breaking changes

README.md

+4-27
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Resolution is a library for interacting with blockchain domain names. It can be
77

88
Resolution is primarily built and maintained by [Unstoppable Domains](https://unstoppabledomains.com/).
99

10-
Resoultion supports decentralized domains across three main zones:
10+
Resoultion supports decentralized domains across two main zones:
1111

1212
- Crypto Name Service (uns)
1313
- `.crypto`
@@ -21,25 +21,20 @@ Resoultion supports decentralized domains across three main zones:
2121
- `.dao`
2222
- Zilliqa Name Service (zns)
2323
- `.zil`
24-
- Ethereum Name Service (ENS)
25-
- `.eth`
26-
- `.kred`
27-
- `.xyz`
28-
- `.luxe`
2924

3025
# Installation into the project
3126

3227
## Cocoa Pods
3328

3429
```ruby
35-
pod 'UnstoppableDomainsResolution', '~> 3.0.0'
30+
pod 'UnstoppableDomainsResolution', '~> 4.0.0'
3631
```
3732

3833
## Swift Package Manager
3934

4035
```swift
4136
package.dependencies.append(
42-
.package(url: "https://github.com/unstoppabledomains/resolution-swift", from: "3.0.0")
37+
.package(url: "https://github.com/unstoppabledomains/resolution-swift", from: "4.0.0")
4338
)
4439
```
4540

@@ -149,12 +144,10 @@ Version 0.3.0 introduced the `Configurations` struct that is used for configurin
149144
Library can offer three naming services at the moment:
150145

151146
* `uns` resolves `.crypto` , `.coin`, `.wallet`, `.bitcoin`, `.blockchain`, `.x`, `.888`, `.nft`, `.dao` domains,
152-
* `ens` resolves `.eth`, `.kred`, `.xyz`, `.luxe` domains
153147
* `zns` resolves `.zil` domains
154148

155149
By default, each of them is using the mainnet network via infura provider.
156-
Unstoppable domains are using the infura key with no restriction for UNS.
157-
Unstoppable domains recommends setting up your own provider for ENS, as we don't guarantee ENS Infura key availability.
150+
Unstoppable domains are using the infura key with no restriction for UNS.
158151

159152
You can update each naming service separately
160153

@@ -168,9 +161,6 @@ let resolution = try Resolution(configs: Configurations(
168161
providerUrl: "https://polygon-mainnet.infura.io/v3/3c25f57353234b1b853e9861050f4817",
169162
network: "polygon-mainnet")
170163
),
171-
ens: NamingServiceConfig = NamingServiceConfig(
172-
providerUrl: "https://mainnet.infura.io/v3/d423cf2499584d7fbe171e33b42cfbee",
173-
network: "mainnet"),
174164
zns: NamingServiceConfig = NamingServiceConfig(
175165
providerUrl: "https://api.zilliqa.com",
176166
network: "mainnet")
@@ -188,19 +178,6 @@ resolution.addr(domain: "udtestdev-creek.crypto", ticker: "eth") { (result) in
188178
XCTFail("Expected Eth Address, but got \(error)")
189179
}
190180
}
191-
192-
// naming services that hasn't been touched by Configrations struct are using default settings
193-
// the following will look up monkybrain.eth on the mainnet via infura provider
194-
195-
resolution.addr(domain: "monkybrain.eth", ticker: "eth") { (result) in
196-
switch result {
197-
case .success(let returnValue):
198-
ethENSAddress = returnValue
199-
domainEthReceived.fulfill()
200-
case .failure(let error):
201-
XCTFail("Expected Eth Address, but got \(error)")
202-
}
203-
}
204181
```
205182

206183
## Batch requesting of owners

Resolution.xcodeproj/project.pbxproj

-34
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
3EB45BCC26E9684B00D25F10 /* resolver-keys.json in Resources */ = {isa = PBXBuildFile; fileRef = 3EB45BCB26E9684B00D25F10 /* resolver-keys.json */; };
3131
3EB45BD726E96FC500D25F10 /* UNSLayer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3EB45BD626E96FC500D25F10 /* UNSLayer.swift */; };
3232
3EB45BDD26EAB26100D25F10 /* AsyncResolver.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3EB45BDC26EAB26100D25F10 /* AsyncResolver.swift */; };
33-
3EC9E0482697F2E0001521B4 /* ensResolver.json in Resources */ = {isa = PBXBuildFile; fileRef = 8449EDFB2513BA3D00DABB57 /* ensResolver.json */; };
3433
3ECD84AE25A6AEE1001772DD /* UsdtVersion.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3ECD84AD25A6AEE1001772DD /* UsdtVersion.swift */; };
3534
3EE4DA0D24E367720097540B /* Resolution.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3EE4DA0324E367720097540B /* Resolution.framework */; };
3635
3EE4DA1224E367720097540B /* ResolutionTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3EE4DA1124E367720097540B /* ResolutionTests.swift */; };
@@ -40,13 +39,10 @@
4039
3EE8A94526FD46A7005FD616 /* unsRegistry.json in Resources */ = {isa = PBXBuildFile; fileRef = 3E2AC93D24E4FC9F008EBC39 /* unsRegistry.json */; };
4140
3EE8A95C26FD47A8005FD616 /* unsProxyReader.json in Resources */ = {isa = PBXBuildFile; fileRef = 30A69244251385A70079EC69 /* unsProxyReader.json */; };
4241
8402F708250935FE0007F01D /* ContractZNS.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8402F707250935FD0007F01D /* ContractZNS.swift */; };
43-
8449EDFA25139F2500DABB57 /* ensRegistry.json in Resources */ = {isa = PBXBuildFile; fileRef = 8449EDF925139F2500DABB57 /* ensRegistry.json */; };
44-
845B401D251389A4006AB08E /* ENS.swift in Sources */ = {isa = PBXBuildFile; fileRef = 845B401C251389A4006AB08E /* ENS.swift */; };
4542
848E21092507890A008707D2 /* ZNS.swift in Sources */ = {isa = PBXBuildFile; fileRef = 848E21082507890A008707D2 /* ZNS.swift */; };
4643
848E210C25079D61008707D2 /* Types.swift in Sources */ = {isa = PBXBuildFile; fileRef = 848E210B25079D61008707D2 /* Types.swift */; };
4744
B650B487269F23460054727E /* EthereumAddress.swift in Sources */ = {isa = PBXBuildFile; fileRef = B650B486269F23460054727E /* EthereumAddress.swift */; };
4845
B6B202C8260226B700A72AF2 /* BigInt in Frameworks */ = {isa = PBXBuildFile; productRef = B6B202C7260226B700A72AF2 /* BigInt */; };
49-
B6E79938260223CE00F65894 /* Base58.swift in Sources */ = {isa = PBXBuildFile; fileRef = B6E79936260223CE00F65894 /* Base58.swift */; };
5046
B6F2075425DBD89800140CE3 /* ABIEncoder.swift in Sources */ = {isa = PBXBuildFile; fileRef = B6F2074C25DBD89800140CE3 /* ABIEncoder.swift */; };
5147
B6F2075525DBD89800140CE3 /* ABIDecoder.swift in Sources */ = {isa = PBXBuildFile; fileRef = B6F2074D25DBD89800140CE3 /* ABIDecoder.swift */; };
5248
B6F2075625DBD89800140CE3 /* ABIElements.swift in Sources */ = {isa = PBXBuildFile; fileRef = B6F2074E25DBD89800140CE3 /* ABIElements.swift */; };
@@ -109,16 +105,11 @@
109105
3EE8A94126FD44C3005FD616 /* UnsLayerL2Tests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UnsLayerL2Tests.swift; sourceTree = "<group>"; };
110106
8402F707250935FD0007F01D /* ContractZNS.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ContractZNS.swift; sourceTree = "<group>"; };
111107
8425AED824FFBADF00BBCBBA /* README.md */ = {isa = PBXFileReference; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = "<group>"; };
112-
8449EDF925139F2500DABB57 /* ensRegistry.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = ensRegistry.json; sourceTree = "<group>"; };
113-
8449EDFB2513BA3D00DABB57 /* ensResolver.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = ensResolver.json; sourceTree = "<group>"; };
114-
845B401C251389A4006AB08E /* ENS.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ENS.swift; sourceTree = "<group>"; };
115108
848E21082507890A008707D2 /* ZNS.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ZNS.swift; sourceTree = "<group>"; };
116109
848E210B25079D61008707D2 /* Types.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Types.swift; sourceTree = "<group>"; };
117110
849E07CC24F946CA00A793D3 /* LinuxMain.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LinuxMain.swift; sourceTree = "<group>"; };
118111
849E07D124F9499900A793D3 /* XCTestManifests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = XCTestManifests.swift; sourceTree = "<group>"; };
119112
B650B486269F23460054727E /* EthereumAddress.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = EthereumAddress.swift; sourceTree = "<group>"; };
120-
B6E79935260223CE00F65894 /* README.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = "<group>"; };
121-
B6E79936260223CE00F65894 /* Base58.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Base58.swift; sourceTree = "<group>"; };
122113
B6F2074C25DBD89800140CE3 /* ABIEncoder.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ABIEncoder.swift; sourceTree = "<group>"; };
123114
B6F2074D25DBD89800140CE3 /* ABIDecoder.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ABIDecoder.swift; sourceTree = "<group>"; };
124115
B6F2074E25DBD89800140CE3 /* ABIElements.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ABIElements.swift; sourceTree = "<group>"; };
@@ -156,7 +147,6 @@
156147
isa = PBXGroup;
157148
children = (
158149
3E2AC92124E4FA3E008EBC39 /* UNS */,
159-
8449EDF825139F2500DABB57 /* ENS */,
160150
);
161151
path = Resources;
162152
sourceTree = "<group>";
@@ -175,7 +165,6 @@
175165
isa = PBXGroup;
176166
children = (
177167
3EAFA40324EE32B2008791E9 /* CommonNamingService.swift */,
178-
845B401C251389A4006AB08E /* ENS.swift */,
179168
3E2AC91B24E4FA28008EBC39 /* UNS.swift */,
180169
3EB45BD626E96FC500D25F10 /* UNSLayer.swift */,
181170
848E21082507890A008707D2 /* ZNS.swift */,
@@ -279,15 +268,6 @@
279268
path = Sources;
280269
sourceTree = "<group>";
281270
};
282-
8449EDF825139F2500DABB57 /* ENS */ = {
283-
isa = PBXGroup;
284-
children = (
285-
8449EDF925139F2500DABB57 /* ensRegistry.json */,
286-
8449EDFB2513BA3D00DABB57 /* ensResolver.json */,
287-
);
288-
path = ENS;
289-
sourceTree = "<group>";
290-
};
291271
848E210A25079D43008707D2 /* Helpers */ = {
292272
isa = PBXGroup;
293273
children = (
@@ -331,21 +311,11 @@
331311
B6E79933260223CE00F65894 /* Support */ = {
332312
isa = PBXGroup;
333313
children = (
334-
B6E79934260223CE00F65894 /* Base58Swift */,
335314
B650B485269F23460054727E /* EthereumAddress */,
336315
);
337316
path = Support;
338317
sourceTree = "<group>";
339318
};
340-
B6E79934260223CE00F65894 /* Base58Swift */ = {
341-
isa = PBXGroup;
342-
children = (
343-
B6E79936260223CE00F65894 /* Base58.swift */,
344-
B6E79935260223CE00F65894 /* README.md */,
345-
);
346-
path = Base58Swift;
347-
sourceTree = "<group>";
348-
};
349319
B6F2074B25DBD89800140CE3 /* EthereumABI */ = {
350320
isa = PBXGroup;
351321
children = (
@@ -473,14 +443,12 @@
473443
isa = PBXResourcesBuildPhase;
474444
buildActionMask = 2147483647;
475445
files = (
476-
3EC9E0482697F2E0001521B4 /* ensResolver.json in Resources */,
477446
3E889D1E268D51CF000C5330 /* cnsRegistry.json in Resources */,
478447
3E889D12268B1BBB000C5330 /* uns-config.json in Resources */,
479448
30A69245251385A70079EC69 /* unsProxyReader.json in Resources */,
480449
3E2AC93E24E4FC9F008EBC39 /* unsResolver.json in Resources */,
481450
3EB45BCC26E9684B00D25F10 /* resolver-keys.json in Resources */,
482451
3E2AC93F24E4FC9F008EBC39 /* unsRegistry.json in Resources */,
483-
8449EDFA25139F2500DABB57 /* ensRegistry.json in Resources */,
484452
);
485453
runOnlyForDeploymentPostprocessing = 0;
486454
};
@@ -542,7 +510,6 @@
542510
files = (
543511
3ECD84AE25A6AEE1001772DD /* UsdtVersion.swift in Sources */,
544512
3E2AC91C24E4FA28008EBC39 /* UNS.swift in Sources */,
545-
845B401D251389A4006AB08E /* ENS.swift in Sources */,
546513
3EB45BD726E96FC500D25F10 /* UNSLayer.swift in Sources */,
547514
3E33F99925DCFAB400627C71 /* Configurations.swift in Sources */,
548515
B6F2075825DBD89800140CE3 /* ABIParameterTypes.swift in Sources */,
@@ -553,7 +520,6 @@
553520
3EB45BDD26EAB26100D25F10 /* AsyncResolver.swift in Sources */,
554521
B6F2075525DBD89800140CE3 /* ABIDecoder.swift in Sources */,
555522
848E21092507890A008707D2 /* ZNS.swift in Sources */,
556-
B6E79938260223CE00F65894 /* Base58.swift in Sources */,
557523
B650B487269F23460054727E /* EthereumAddress.swift in Sources */,
558524
3E65912824E381E900D7EC35 /* Errors.swift in Sources */,
559525
3E889CC8268AF94E000C5330 /* TokenUriMetadata.swift in Sources */,

Sources/UnstoppableDomainsResolution/Configurations.swift

-5
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ public struct UnsLocations {
4646
public struct Configurations {
4747
let uns: UnsLocations
4848
let zns: NamingServiceConfig
49-
let ens: NamingServiceConfig
5049

5150
public init(
5251
uns: UnsLocations = UnsLocations(
@@ -57,15 +56,11 @@ public struct Configurations {
5756
providerUrl: "https://polygon-mainnet.infura.io/v3/3c25f57353234b1b853e9861050f4817",
5857
network: "polygon-mainnet")
5958
),
60-
ens: NamingServiceConfig = NamingServiceConfig(
61-
providerUrl: "https://mainnet.infura.io/v3/d423cf2499584d7fbe171e33b42cfbee",
62-
network: "mainnet"),
6359
zns: NamingServiceConfig = NamingServiceConfig(
6460
providerUrl: "https://api.zilliqa.com",
6561
network: "mainnet")
6662
) {
6763
self.uns = uns
68-
self.ens = ens
6964
self.zns = zns
7065
}
7166
}

Sources/UnstoppableDomainsResolution/Helpers/Types.swift

-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ internal typealias AsyncConsumer<T> = (T?, Error?)
2121

2222
public enum NamingServiceName: String {
2323
case uns
24-
case ens
2524
case zns
2625
}
2726

0 commit comments

Comments
 (0)